Link to home
Start Free TrialLog in
Avatar of RadioGeorge
RadioGeorgeFlag for United States of America

asked on

What's the deal with browsers that fail to open current web pages?

The basic setup: you go to a page on my website to listen to what is essentially a playlist of songs that changes every Sunday night when a new playlist is automatically uploaded, replacing the one that has been there since last week.

A listener goes to the site this morning to hear this week's new songs. He hits the play button on the player. And he hears the SAME playlist as last week.

He writes to me to notify me that the playlist is still up from last week.

I wonder how this can be , since a custom-built chron job has been changing the list without fail every Sunday night for 4 years now, and I uploaded this week's music yesterday afternoon. So I go to that webpage, start the player...and LAST WEEK'S SONGS START PLAYING! I double-check the cPanel and confirm that  (1) I did, in fact, upload the new songs to the holding folder and (2) the chron job ran flawlessly as it always does and transferred the files to the "live" folder, overwriting the ones that were there (same names).

So I reload the webpage and try it again. Same thing--last week's songs. I repeat that one more time. Same thing. Like a fool, I try it one more time...AND THAT TIME, the correct playlist starts playing!

I checked with a friend across town who is familiar with my site and he reported that using the same browser as I use, Chrome, he got a "page taking too long to load" timeout twice, and then after another 3 attempts, BINGO, things were fine for him, as well.

I'm no techie but I AM pretty P.O.'d about this. Experts, what the H is going on here and is there anything I can do so that people don't think there's still "old stuff" up when there is simply not?
Avatar of Dave Baldwin
Dave Baldwin
Flag of United States of America image

Files get cached in the browser's cache and until you are able to refresh them from the server, you will still be using the old version.  If it were my site, I would be using a server-side program (in PHP for me) that would deliver the correct playlist from your database.  I would also add cache limiting headers to the data so it would not cache each version.
Avatar of RadioGeorge

ASKER

Well, I appreciate your speedy reply, Dave, but as I said, I'm not a techie, so I don't have a clue as to what you said. And I'm not blaming you. It just seems that it's getting to the point where the least little thing seems to require the services of an advanced specialist to handle. And that's expensive as well as frustrating.
Yes.  Technical problems require technical solutions.  This is a problem that most web developers are familiar with.  In order to speed up web pages, browsers keep a copy of each file that is downloaded.  Then they will use that instead a new copy from the server if they have no reason to think it has changed.  However, files that change daily or frequently require special coding to make sure the new version gets used instead of the last version.  It does require some coding so you may have to hire someone to take care of the problem.
DB,
What you say regarding frequency of changes makes some sense, except that this is the first time in 3 years that this has happened. The files are changed weekly. The old ones are deleted and new ones are uploaded. Does the fact that the files are using the exact same names every week come into play here?

To me, his seems unlikely, because I have THREE other such operations that gave gone on just as long and have never had this problem with any of them.
ASKER CERTIFIED SOLUTION
Avatar of Dave Baldwin
Dave Baldwin
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
OK, so if I'm understanding you correctly, then if the web page changes, the visitor's browser WILL in fact "see" that there's been a change, load the new page, and that's the end of the problem?

Because if that's so, wouldn't a possible solution be to add a bunch of meaningless code that the browser would see (such as randomly generated numbers and characters in the same color as the page background or one or two comment tags that change from week to week) that the visitor would never see?

Or is that just too simple in today's world of computing?
Remember that the main web page is Also cached.  What I would do is write a server side page that load the correct data everytime and put anti-caching code in it so that it never gets cached.  You can't do that with just HTML.  I would use PHP.
Dave gets all the points not just for being the only expert who chose to respond, but for the details of what and why as well. Thanks, Dave.
You're welcome, RadioGeorge!