Forum Moderators: coopster
echo ("<a href=\"gamingrelated2.php?tid=" . $fid['$tid'] . "\">" . $fid['subject'] . "<A>");
Im sure it can load the data from mysql its just its not loading the integer after tid= (in the link)
[edited by: jatar_k at 3:24 am (utc) on July 28, 2007]
[edit reason] no urls thanks [/edit]
You shouldn't put variables within single quotes. Try:
echo '<a href="gamingrelated2.php?tid=' . $fid[$tid] . '">' . $fid['subject'] . '</a>';
Your second call to the array is correct to have the word "subject" in single quotes as you are referring to a defined key in the array. Having the variable in single quotes will cause PHP to accept it as literal and return nothing since there is no key in the array named "$tid".
Also, using single quotes in the echo statement removes the need to escape the double quotes.
Hope this helps,
SK