![]() |
Results in a link question
Hello...I'm new to programming with PHP, but as I'm going through tutorials and reading books I've come across a question I have not been able to figure out.
I have a table with 2 fields....one field is just text and the other is for a URL. I want to have a link created that uses the url for the link and the text field for the text. Here is the code I have so far, but I cannot get it to work: Code:
<html> |
Looks like just the echo is wrong. It should be:
PHP Code:
Dave |
Hi Dave,
Thanks for the reply. When I updated my code and try to view it, all it shows me in the web browser is this: "$row['dsptxt'].""; } ?> |
Could you copy in the code you're using again, including a few lines before and after this particular one?
Thanks Dave |
Code:
<?php |
I forgot the quotes around the URL, try this:
PHP Code:
|
Same thing....when I replace the exact line from the code I showed you with what you gave me, the webpage only displays:
".$row['dsptxt'].""; } ?> |
Actually, I think I got it figured out. I renamed the page to .php instead of .html and removed the } before the ?> and it worked. Just have to add a loop into it so it displays all of the table records. Thanks a bunch for your help!
|
| All times are GMT +1. The time now is 03:36 PM. |
Powered by vBulletin®
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.