secretsquirrel
Programmer
hi,
i've got a mysql table containing a set of text articles and the title of the article.
i've written some code which generates an html table containing a list of the titles, and i need these titles to link the article it relates to.
i'm thinking i can do this by setting each link to point to the same page (eg. 'showArticle.php'), but passing a variable to that page so it knows which article to retrieve and display.
i managed to get as far as <a href="">$title</a> but wasn't sure where to go from there!
can anyone suggest how i could achieve this? presumably i would need to pass 'showArticle.php' the article ID from the table, but i'm not sure how to.
i can post some code if it'll be helpful.
thanks in advance,
ss...
i've got a mysql table containing a set of text articles and the title of the article.
i've written some code which generates an html table containing a list of the titles, and i need these titles to link the article it relates to.
i'm thinking i can do this by setting each link to point to the same page (eg. 'showArticle.php'), but passing a variable to that page so it knows which article to retrieve and display.
i managed to get as far as <a href="">$title</a> but wasn't sure where to go from there!
can anyone suggest how i could achieve this? presumably i would need to pass 'showArticle.php' the article ID from the table, but i'm not sure how to.
i can post some code if it'll be helpful.
thanks in advance,
ss...