image coding

images php coding issues or problems here.

Moderators: macek, egami, gesf

New php-forum User
New php-forum User
Posts: 3
Joined: Sun May 01, 2011 8:29 am

image coding

Postby mdehghani » Sat May 07, 2011 4:06 am

hi everyone.
I have a website with such a structure that there is a folder in the root and there is a .php in the folder which wants to show an image in the same folder. so the image and the webpage are like follows.

when I link to the image in the page I use this coding and runs fine on my hard drive:


but when I upload it to my site it doesnt show up unless I use this coding:

isn't there a way I could omit the total path and merely use the first example. I use 000webhost. please help

New php-forum User
New php-forum User
Posts: 76
Joined: Sun Nov 28, 2010 6:33 pm

Re: image coding

Postby annyphp » Tue May 10, 2011 5:50 pm

search and free download PHP image gallery script from PHPKode.
Find the image script you want.
Hopefully can help you!
Kind Regards!

New php-forum User
New php-forum User
Posts: 5
Joined: Thu Apr 28, 2011 8:02 pm

Re: image coding

Postby prbhat08 » Thu May 12, 2011 12:22 am

use http path for your image

for localhost it should be like this: src='http://localhost/yourproject/imagefolder/logo.gif"

for the webupload it should be like this: src='"

or directly u can use


Return to “PHP coding => Images”

Who is online

Users browsing this forum: No registered users and 2 guests