Re: Retrieving Image Location in MySQL

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello again Sashi

The answer provided by Mushin won't work because images are not
acessible from the outside. You can't have

<img src="C:\Users\Sashikanth\Desktop\Bldgs_lots\Burruss.jpg" ...>

because that's not a valid URL...

You can have something like

<img src="Bldgs_lots/Burruss.jpg" ...>

which when interpreted by the browser will become something like

http://yoursite/Bldgs_lots/Burruss.jpg

Now, for this to happen you need to have Bldgs_lots as a subfolder or
alias for your site.

Otherwise, there is the way I mentioned in the first place, involving a
php script just to get the image, which has to be called from within
your script, passing it the info from the database

echo '<img src="picture.php?&img=' . $location . '" border="1" height="150" width="200" 
alt="' . $build . '">';

Now, I don't recommend passing local paths like this to scripts ...

Hope this helps
C ya
JP


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux