Jump to content

Can anyone help on a cache question?


santiagodelarosa

Recommended Posts

Absolute beginner to php!!

I have just converted a simple site from htm pages to php because as it grew larger the include function that php offers was the only solution to stop me going mad  ;)

I have mainly used php to include various parts of the navigation system but have noticed that each time a page is viewed the whole page loads up including the header and footer. I have saved the menu header and footer in a "template" folder.

Is there some way to cache the header/menu/footer php files so that only the text in the middle changes??

Any help would be greatly appreciated!!!! Thanks ;D
Link to comment
https://forums.phpfreaks.com/topic/27973-can-anyone-help-on-a-cache-question/
Share on other sites

Well, even though you're using the include function the page still arrives as a single file, and as far as I know there's no way around that!  The graphics are porbably being cached though.

If you want to keep the header/nav system while loading other parts of the site, I'd say the way to go is with either frames/iframes or AJAX, which are different though complementary technologies to PHP.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.