Jump to content

HTML tags in a PHP variable


denoteone

Recommended Posts

if I have a variable like so

 

$pagetitle = "Thank You page"

$mylink = "<a href='mysite.com?title=$pagetitle'>click hereM</a>";

echo $mylink;

would that show a click here link that goes to    mysite.com?title=Thank You Page

 

also if I insert $mylink into a database will that work so I can later retrieve the link from the database?

Link to comment
https://forums.phpfreaks.com/topic/153181-html-tags-in-a-php-variable/
Share on other sites

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.