hueymac Posted October 30, 2008 Share Posted October 30, 2008 Hi all, new to PHP and I have a question: I am using a php include tag on my index page to include an external php page that has images in a div tag in it. When I use relative links, the image does not show up. The path is correct. When I use an absoute link, it shows up no problem. Can I not use relative links on an external page with a php include? Link to comment https://forums.phpfreaks.com/topic/130755-php-includes-relative-links-wont-show-images/ Share on other sites More sharing options...
bobbinsbro Posted October 30, 2008 Share Posted October 30, 2008 i think what you need is realpath(): http://il2.php.net/manual/en/function.realpath.php Link to comment https://forums.phpfreaks.com/topic/130755-php-includes-relative-links-wont-show-images/#findComment-678620 Share on other sites More sharing options...
hueymac Posted October 30, 2008 Author Share Posted October 30, 2008 i think what you need is realpath(): http://il2.php.net/manual/en/function.realpath.php Thanks for the reply, looks a little complicated, I guess I am going to have to do some learning Link to comment https://forums.phpfreaks.com/topic/130755-php-includes-relative-links-wont-show-images/#findComment-678798 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.