Hi, I have a bit of a weird one... I have a site which holds sub nav pages within a simple database. On 1 of these pages I have a fancybox script that loads profiles by clicking on thumbnails located on a page called whoweare.php... these profiles are external html files and when the thumbnail is clicked it simply loads this page i.e.
Now this all works fine when the page holding the profiles are not in the database but because this page has sub navs I put all these sub navs in a database and load them through the main page i.e. whoweare.php?pg=profiles but now when you click the thumbnails they are all blank... I even just tried a simple <?php echo "hi" ?> and still blank?
Clearly you have never used "readfile", as you do not need the echo.
Also, using include could have a different effect if there are PHP tags inside. And I highly doubt it will out perform "readfile"
Apologies. I remembered not using readfile for a reason and had forgotten what it was. Upon reflection I remembered that it doesn't buffer larger files well and can cause memory issues (encountered the issue specifically when handling streaming media buffering problems).
Hi thanks for your responses but none of these worked... I even included the full URL to ensure the path is correct but the files is still blank... may be the way fancybox and the database clash... Im not sure
The profile where I am trying to load the external file is through thumbnail Erica and when you click on this it goes blank and what I want it to look at is if you click Chris profile... This works because it has the code there and not as an include
We will need more code. It looks like you might need to adjust your logic a bit.
Example:
Split the profile loading part to a separate php (or section at least)
Adjust the URLs you were using before that pointed to html files and worked to instead point to the php file that loads appropriately.
Does that helps to clarify? I'm afraid we won't be able to help much more than that without seeing more code...
Bookmarks