Reply to Newbie: Help Please!

Your name:

Reply:


Posted by LawrenceTLamb on 08/05/06 13:25

Hi everyone!

Am developing my first dynamic web-site using php and my sql.

Still at the beginning but am going a bit mad as one does after sevral
hours of searching for answeres on google and can't find exactly what
you are looking for...

Hope you can help!

I have an index.php page which calls an include to retrieve some basic
data from a mysql table.

I have had no problem retrieving the text data from the database and
displaying it. (Page set up with html tables)

I store my images in an /images subdirectory. a.jpg, b.jpg etc.

I have a row in the mysql database table called image_ref where the
file name is stored.

However, when I try to call the image from the directory via the ref in
database I get a broken image.

Code I have been trying to use is:

Print "<td rowspan=\"4\"><img
src=\"images/\"".$info['image_ref']."></td>";

This is giving the following result in the source code:

<img src="images/"cp_sagres.jpg>

i.e. an extra " - so the src cannot be read correctly and the image not
displayed.

I have spent hours trying to change the escapes etc to no avail. Looked
in books for examples...none.

All advice (including directions to suitable tutorials) would be
appreciated and grovelled.


Chris

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация