Jump to content

links in query results


korbenmxli

Recommended Posts

new to PHP but make advances.... i display my table in a grid and all work fine... i have a field with  url adress or links to other pages in my site..... its possbible to display that field in my grid but like real hyperlinks?? i mean do click on it and go to the page?? i mean... like any other link ... let say ....

 

subject                description                                  more info

-----------------|---------------------------------------------|-------------------

WORD              calendar templates bla bla              templates here  <-- this field must be a link

 

tnx

Link to comment
https://forums.phpfreaks.com/topic/196209-links-in-query-results/
Share on other sites

Are you actually displaying your table data to the public in an un-edited way like that? If so that is quite bad practice; especially if you have an incrementing unique index on the table (i.e. and ID field). Anyway.

 

You can display the field contents as real hyperlinks if they are stored as real hyperlinks in the database. So that field would contain for example:

 

<a href="/page/some-template" title="See Template">templates here</a>

 

That way when you show the table contents, the data will be interpreted as HTML and a hyperlink will be shown.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.