Morning All.. I’m sure this is easy and I’ve just got confused... What I want to do is read a string out of a MySQL database into a variable. Having got the string, I want to insert it into a HTML table as a clickable web link. ie inside a <href=$Link>. Unfortunately I grt parse errors. IM sure I just have quotes in the wrong place!! An example of the correct syntax would be very helpful!
Thanks in advance Phill
using php echo statements
// DB Connection // SELECT STATEMENT // COLLECT INFO echo "<a href=\"$link\">Name Of Link</a>";
That is what i am using on my sites
David
Thanks David.. Distinct lack of \'s in mine... works ok now!
Phill
lol
no problem
just remember that in the echo statement, before any quote (") you need to use a slash().
IMHO clearer way to echo(faster too) and you dont have to use slashes is:
echo '<a href="'.$link.'">Name Of Link</a>';
Thsnks for your suggestion ! I'll try this too.