inserting <img> tag into a script]

From: Date: Wed, 06 Dec 2000 18:02:04 +0000
Subject: inserting <img> tag into a script]
Groups: php.general 
Request: Send a blank email to php-general+get-28936@lists.php.net to get a copy of this message
BrianSander wrote: > Greetings, > > Got a slight html tag problem with a php4 script. I've written a function > which forms a generic page for my web page. What I attempted to do was > insert an image into the page. The problem line is: > > print("<img src="../graphics/logo.jpg">"); > > The above line is slightly abbreviated but that line produces an error > when the script is executed. It works fine if it's not in a php script. > I've done a quick search of the help files on php.net and was unable to > find anything. > > How do you place the <img> tag into a php script? > > Thanks. Hi there, Try escaping the quotes. echo "<img src=\"../graphics/logo.jpg\">"; Regards, Jason -- Jason Murray Developer jWeb New Media Design 1 877 525 jWEB

« previous php.general (#28936) next »