Jump to content

[SOLVED] very wierd echo problem


MDanz

Recommended Posts

i echo the variable $latest alone and it gives me the hyperlink that i want.. but when i  assign it to this <div>

 

echo "<div class=\"rollover\"><a href='$latest'></div>";

 

it doesn't display at all.. and i have one identical to this that works...

 

<div class=\"rolloverz\"><a href='info.php?id=$id'></div>

 

i have no idea why it isn't working..

 

heres the div class rollover.. nothing is wrong with this though...

 

<style type="text/css">
.rollover a {
float: left;

width: 35px;
height: 17px;



background: url("http://www.fdsff.com/lastreply.jpg");
text-decoration: none;
}
.rollover a:hover {

background: url("http://www.balshs.com/lastreply2.jpg");

}

</style>

 

 

please help

Link to comment
https://forums.phpfreaks.com/topic/176290-solved-very-wierd-echo-problem/
Share on other sites

Hi MDanz,

 

echo "<div class=\"rollover\"><a href='$latest'></div>";

 

The div class here is called "rollover", but here:

 

<div class=\"rolloverz\"><a href='info.php?id=$id'></div>

 

it's called "rolloverz".

 

Also, you're not closing either link with the </a> tag.

 

Hope this helps.

yea they are two different classes..

 

this is mind boggling to me it should work..

 

when i echo the variable alone i get the link in text..

 

 

i just found out when i assign a hyperlink to it.. then it acts up...

its in TEXT type in mysql... like this

 

http://www.gfddhd.com/topic.php?id=44?page=2

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.