Jump to content

Images in php


raymondje21

Recommended Posts

Why doesn't this display the images in the table?

 

<table border=”0” cellpadding=”0” cellspacing=”0” width=”750”>
<tr>
<td align=”left” valign=”top”><img src=”images/site-template-sick-green_01” border=”0”></td>
<td align=”left” valign=”top”><img src=”images/site-template-sick-green_02” border=”0”></td>
<td align=”left” valign=”top”><img src=”images/site-template-sick-green_03” border=”0”></td>
</tr>
<tr>
<td align=left” valign=”top”><img src=”images/site-template-sick-green_04” border=”0”></td>
<td align=”left” valign=”top”>GAME GOES HERE</td>
<td align=left” valign=”top”><img src=”images/site-template-sick-green_06” border=”0”></td>
</tr>
<tr>
<td align=”left” valign=”top”><img src=”images/site-template-sick-green_21” border=”0”></td>
<td align=”left” valign=”top”><img src=”images/site-template-sick-green_22” border=”0”></td>
<td align=”left” valign=”top”><img src=”images/site-template-sick-green_23” border=”0”></td>
</tr>
</table>

Link to post
Share on other sites

Wajjooo

 

Fast response time here

 

Wel it hase to do with PHP beceuse its index.php

 

Second i learned that code form a book called

 

PHP game programming

 

What happens when you view the image by itself?

When i view them with paint and stuff its just a normal image but when look on my site it gives to no image drawing you that little box with a broken page in it

Link to post
Share on other sites

This code is pure HTML, just because it's in a PHP file, doesn't make it PHP.

 

The problem is, most likely, that you aren't putting the file extension in the reference:

<td align="left" valign="top"><img src="images/site-template-sick-green_01.jpg" border="0"></td>

 

Ken

Link to post
Share on other sites

I chande names of images to more logic names and also added .gif behind all and now this is the new error

 

 

The error i added smileys where small boxes with the broken page sign is

 

:D<\td> ;D<\td> ;D<\td>  ;D<\tr>

:D<\td> GAME GOES HERE ;D<\td> ;D<\td> <\tr>

:D<\td> ;D<\td> ;D<\td>  :D<\tr>  :D<\table>

 

The code

<html>
<body>


<table border=”0” cellpadding=”0” cellspacing=”0” width=”750”>
<tr>
<td align=”left” valign=”top”><img src=”images\left_top.gif” border=”0”><\td>
<td align=”left” valign=”top”><img src=”images\middel_top.gif” border=”0”><\td>
<td align=”left” valign=”top”><img src=”images\right_top.gif” border=”0”><\td>
<\tr>
<tr>
<td align=left” valign=”top”><img src=”images\left_center.gif” border=”0”><\td>
<td align=”left” valign=”top”>GAME GOES HERE<\td>
<td align=left” valign=”top”><img src=”images\right_center.gif” border=”0”><\td>
<\tr>
<tr>
<td align=”left” valign=”top”><img src=”images\left_down.gif” border=”0”><\td>
<td align=”left” valign=”top”><img src=”images\middel_downgif” border=”0”><\td>
<td align=”left” valign=”top”><img src=”images\right_down.gif” border=”0”><\td>
<\tr>
<\table>
</body>
</html>

Link to post
Share on other sites

Try this:

 

<td align=”left” valign=”top”><img src=”images/left_top.gif” border=”0”></td>

 

Are you sure that picture extension is .gif ???

 

Change slash \ to / for the picture path!

Link to post
Share on other sites

Ok the here is what the images are

 

-there not misspelled

-there are Graphics interchange format <--- i think thats GIF in short

-there in the same map as the index.php in a special image map <---- i also tried changing the code and image's with out the map but doesn't work

 

Maybe this help

 

Link to post
Share on other sites

Ok. Try changing the quotes (from  ”  to  ") for one row of your table data, like

 

<html>
<body>
<table border="0" cellpadding="0" cellspacing="0" width="750">
<tr>
<td align="left" valign="top"><img src="images\left_top.gif" border="0"><\td>

 

If you see the image for that table cell then the problem is probably the quotes.

Link to post
Share on other sites

Ok. Try changing the quotes (from  ”  to  ") for one row of your table data, like

 

<html>
<body>
<table border="0" cellpadding="0" cellspacing="0" width="750">
<tr>
<td align="left" valign="top"><img src="images\left_top.gif" border="0"><\td>

 

If you see the image for that table cell then the problem is probably the quotes.

 

How wouldi do that? how do you make those quotes?

Link to post
Share on other sites

Try using this and watch your switches. Replace aaa.jpg with your image filename. It should work since it works for me. You will have to modify the height and width of the image to reduce distortion.

 

<table border=”0” cellpadding=”0” cellspacing=”0” width=”750”>
<tr>
<td align="left" valign="top"><img src="images/aaa.jpg" height="183" width="235" 

border="0"></td>
<td align="left" valign="top"><img src="images/aaa.jpg" height="183" width="235" 

border="0"></td>
<td align="left" valign="top"><img src="images/aaa.jpg" height="183" width="235" 

border="0"></td>
</tr>
<tr>
<td align="left" valign="top"><img src="images/aaa.jpg" height="183" width="235" 

border="0"></td>
<td align="left" valign="top">GAME GOES HERE</td>
<td align="left" valign="top"><img src="images/aaa.jpg" height="183" width="235" 

border="0"></td>
</tr>
<tr>
<td align="left" valign="top"><img src="images/aaa.jpg" height="183" width="235" 

border="0"></td>
<td align="left" valign="top"><img src="images/aaa.jpg" height="183" width="235" 

border="0"></td>
<td align="left" valign="top"><img src="images/aaa.jpg" height="183" width="235" 

border="0"></td>
</tr>
</table>

Link to post
Share on other sites

I think the problem is because your images are different dimensions. The upper left image has a width="147" and height="183" and the upper right image has a width="142" and height="177". This is probably what is causing the spacing. Try fixing all images so the result is a square table.

Link to post
Share on other sites
  • 2 weeks later...

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.