Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Geek Culture / Edit a HTML webpage, but have the content auto-refresh when overwriting an old file

Author
Message
Wehtam_
User Deleted
Posted: 17th Mar 2011 23:57
Quite an unexciting title for a post really.
This is a problem which I've had to deal with now and again, and I wondered if the more web savy people among the board could lend their wisdom.

Before I begin though:

Massive thanks to mr_d who recommended me SimpleCMS by PHPjabbers. What a fantastic product! Cheers! I'm always looking for an easy solution to a problem and would be VERY interested in similar websites that offer awesome PHP/javascript snippets.

So here's the dilemma. I'm no scripter, but I can design a website in HTML and CSS no problem. Thanks to a few code snippets I've been able to create editable areas for the client and some decent web forms.
My problem arises when my client wishes an amend to be made to the HTML template i've made, i.e add a link to the menu. I've found that after uploading the newly edited file to the FTP site, and overwriting the old html file, the clients browser still grabs the old version from cache.

Aside from that horrible meta-refresh trick, is there a way that I can force the browser to see the new version (like a php site) without applying any dirty tricks ?

Any feedback would be most welcome!

Diggsey
19
Years of Service
User Offline
Joined: 24th Apr 2006
Location: On this web page.
Posted: 18th Mar 2011 00:51
You can disable caching using meta tags. There are loads of tutorials on the internet. You can also use the expires meta tag to set a certain date when a page will be invalid. You could perhaps set this to a day in advance so that the page can be cached after the first visit each day if that's what you want.

[b]

Login to post a reply

Server time is: 2025-05-23 06:43:21
Your offset time is: 2025-05-23 06:43:21