Hi,
Hoping this is posted in the right place. I'm getting a bit stuck . . . I want to display a PHP echo in a HTML link, for example:
http://www.test.co.uk/$name
I want the $name to display as echo. I'm currently using:
<a href="http://www.test.co.uk/<?php echo $name['name']; ?>" target='_blank' >Click Me</a>
This along with the request code kind of works but only displays / links the first letter and not the full echo.
Can someone please advise the best way to echo in a HTML link?
Hope this makes sense and thank you for your time.
echo in HTML link
Moderator: General Moderators
Re: echo in HTML link
Based on that you are getting only the first letter, I would guess that $name is not actually an array, but a string, so probably just do echo $name;
-Greg
-Greg