This topic is locked

Title on mouse over

1/13/2009 11:58:22 AM
PHPRunner General questions
M
mmponline author

I use this code to put a title on a picture hyperlink on mouse over.

echo "<a title=Introduction href=\"Student_Introduction_list.php?mastertable=".$_SESSION[$strTableName."_mastertable"]."&masterkey1=".$_SESSION[$strTableName."_masterkey1"]."\"><IMG src=\"images/intro.jpg\"border=0></a>";


It works fine accept when there are spaces in the title. Eg.

echo "<a title=Back to Introduction href=\"Student_Introduction_list.php?mastertable=".$_SESSION[$strTableName."_mastertable"]."&masterkey1=".$_SESSION[$strTableName."_masterkey1"]."\"><IMG src=\"images/intro.jpg\"border=0></a>";


It then only shows the first word. Eg. Back
Is there ways to prevent this. I tried underslash, but then it shows the underslash as well.

Sergey Kornilov admin 1/13/2009

Use single quotes to wrap the title.

echo "<a title='Back to Introduction' ...
M
mmponline author 1/17/2009

Works perfect! Thanks a lot...