Page 1 of 1

PHP open link, super problem

Posted: Wed Jan 07, 2009 2:19 am
by Alienware

Code: Select all

$name = "<a onMouseOver=\"return overlib('Playername: ".$user."', CENTER);\"
 onMouseOut=\"nd();\" href=\"profile.php?player=".$user."\" style=\"\">".$play."</a>";
echo $name." ~ ";
Ok so thats the problem link/code...

Im wanting to open this link in a frame called "main"

i knwo about the principles of target="main" but when i try and put it into the code, the page doesnt load in the main frame, whats mor, the page that this code is on comes up with an error.

Any ideas?

Re: PHP open link, super problem

Posted: Wed Jan 07, 2009 9:31 pm
by yacahuma
may I suggest next time writing like this. Not everything has to be php. Actually I find it easier to touch the html as little as possible.
Transforming html into php is not always a good idea. In you example it makes even less sense since you are just echoing it.

Code: Select all

 
<a onMouseOver="return overlib('Playername: <?=$user?>', CENTER);" onMouseOut="nd();" href="profile.php?player=<?=$user?>">Link</a>