Displaying <img> tag within <td> tag in echo statement

Hi,

Am trying to display an tag within a

tag in a echo statement, however get a parse error. Am not sure how to layout the tag.

[php]echo "

“.$row[“itemPrice”].” “.$row[“totalPrice”].” ‘Edit’ "; [/php]

Tried the below statement in an individual echo statement without the

tags which works fine,

[php]echo ‘Edit’; [/php]

which works fine. Also tried escaping double quotes in the parameters when enclosing in double quotes. This also works fine.

How do i get the 1st statement working.

You can’t use like quotes inside each other. Change your td code to
[php]echo “

$row[itemPrice] $row[totalPrice] ”;[/php]

You had some single quotes in there too that were out of place.

thanks that worked.

Sponsor our Newsletter | Privacy Policy | Terms of Service