Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SELECT field as a hyperlink? Anybody?

Status
Not open for further replies.

FireDolphin

Programmer
May 27, 2003
1
GB
Urghhh! Help!

I'm going around in circles here. I need to simply query a MySQL db using PHP and return one of the fields as a hyperlink.I've tried various things inc:

select '<a href=&quot;' + fieldname + '&quot;>Click Here!</a>' from table

and

SELECT (CONCAT('<a href=&quot; as hyperlink1 FROM table

These return just the text:
<a href=&quot;
with the source looking like this:

& lt;a href=& quot; quot;& gt;2& lt;/a& gt;

(I've had to put spaces afters the &s else this posting routine changes it!)

How can I stop the php being parsed to html as exact characters (< instead of & lt; etc) ???

Somebody please save me from caffeine overdose!

J
 
WRONG FORUM.

Your posting will be answered better in the PHP forum.


Bye

Qatqat

I have been happy throughout my life in thinking that samba was I kind of dance; now I live with Linux and all I do is working.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top