Jump to content

Php image within table


ondi

Recommended Posts

I know my code works as it displays the correct image. However, when i put the code inside a table cell the picture wont show. Can anyone see where I'm going wrong?

 

Here's my code:

 

<TABLE 
  WIDTH="520"
  ALIGN=center
  BORDER=0
  CELLSPACING=0
  CELLPADDING=0>
<tr VALIGN=left  ALIGN=center>
<td>
<?php
$image_url = "images/" . $playerdata['id'] . ".jpg";
?>
</td></tr></table>

Link to comment
https://forums.phpfreaks.com/topic/137505-php-image-within-table/
Share on other sites

lol kat I came here and I was like.. he prolly generated a php image than probably tried to put the PHP code inside the TABLE lol.. but idk

 

but for any affect, you can't generate an image with any stray data, or it ruins the image.. just fyi

Hi Kat, i now get this error:

Parse error: syntax error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in /home/fhlinux222/w/walthamforest-fc.co.uk/user/htdocs/stats/newplayer.php on line 115

 

My image isn't standard for every page, it's relative to the playerid.

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.