sudeep cv sudeep cv - 1 year ago 72
PHP Question

Display image using absolute path

I am using uploadify to upload img to server at the time of upload i saved absolute path to the data base its like:


now i want to display the same in browser the following method does not work

<div id="photos">
<h3>Photo title</h3>
<P class="like"><a href="#">Like</a> </P>
<p class="date">date </p>
<p class="pclear" />
<div id="image">
<img src="<?php echo $result_set['path']; ?>" />

// this doesn't work . when I edit the path manually to uploads/logo2.jpg work perfectly

about image goes here

how can I resolve this problem?

Answer Source

You need to use an url, not a path.



is a physical path, the address on that server where the image is found. You need to use an url available for your visitors. I guess that you have a name mapped to that server (something like localhost or

From the structure I guess that your url would be something like

where is the base url you are using to get to that application

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download