PDA

View Full Version : VFS script



lio
11-07-2009, 06:10 PM
1) Script Title: VFS script

2) Script URL (on DD):
Non official on http://www.dynamicdrive.com/ !
http://home.comcast.net/~jscheuer1/side/vfs/vac_plain.htm

3) Describe problem:
I have identified a problem which happens sometimes only : under IE, most of the time when starting by "Start / Internet Explorer" with Windows XP, the slideshow does not start.
I had this problem on my website and came back to John's original script and the problem is the same.
Again, this happens only sometimes.
Could it be an IE cache problem ?

Thanks in advance ;)

jscheuer1
11-07-2009, 07:08 PM
What version of IE? I tested extensively in IE 7 while developing this script. I didn't notice what I think you are describing, though I'm not sure exactly what you are describing. Could you be more specific? Like, now I know you say it only happens sometimes, but what are the exact sequence of events I must follow to have a chance of it happening?

In any case though, the server space where I have my demo is just for personal pages as alloted by my ISP for all their basic internet access accounts. As such it isn't exactly the best environment for something like this. For example, sometimes the bandwidth can really dip. With images, even though the ones in my demo are optimized, this isn't such a good thing in general, and in specific for IE. IE has a habit of looking at images differently than other browsers, if an image cannot be opened it never considers its attempt to open it 'complete' and can therefore get stuck trying to open it. All other browsers will give up after a certain amount of time and move on.

This is not a problem in IE just for this script, or even just pages with image scripts, but even for plain pages with images.

If the problem you are having only occurs sometimes, and cannot be duplicated with any reliability by following a certain procedure, it is most likely due to bandwidth drop out and probably cannot be fixed, other than by the user hitting refresh as they would with any page where images don't appear to be loading properly.

lio
11-07-2009, 08:37 PM
John,

I have IE8. I have tryed with Firefox and the problem occurs also sometimes.
I have seen the same problem with the page loaded on my server.
To have a "good" chance to see the problem, I have put the link as default page in IE ; then in XP you start IE by start / IE.
I have just made this sequence several time :
- the fisrt sequence, I have faced the problem (slideshow does not start - and no fading effect on 1st pic) after the second time
- the second time (in between I close IE), only after 7 our 8 times

When it happens, if you refresh the page, the slideshow starts (with the fading effect) in most of the cases (I remebre I have faced cases where it does not start after the 1st refresh).

In any case, the 1st image of the slideshow appers without problem.

I hope it helps ;)

jscheuer1
11-07-2009, 09:08 PM
Oh, so you are saying that if it is like set as the home page in the browser, and you have no instance of the browser open, and you launch . . .

In that case I think a great many pages may have trouble loading properly at times, as they have to compete with the loading of the browser. This would be regardless of the browser, though some (like Firefox) would be better at it than others (like IE) because they have a more efficient javascript unit. Possibly adding more memory to your system and/or a faster CPU would solve that problem. I really don't think it is an issue with the script, other than the fact that it is a fairly code heavy script. If lighter weight code could be written to accomplish the same tasks (which I'm sure it could), that would improve things as well, but would probably still occasional misfire in those type of situations because there is only so much code that could be eliminated before you would lose functionality, and this script does a lot.

Also, you are right to a degree about the cache. If the page, script and images are cached, as would likely be the case if this were someone's home page in the browser, or if they did what you are proposing frequently without clearing their cache in between, that would help it to load more easily in most cases.

lio
11-07-2009, 09:27 PM
I don't really understand the first sentence, sorry :confused:
The fact is that the problem does nor happen so often with Firefox.
My computer is 1 year old (Quad Core Q6600,...).
But I understand that the script heavy is.
Mayne should a refresh be added to each page ?

jscheuer1
11-07-2009, 09:48 PM
What you are saying is launch the browser and the page simultaneously, right? That's all the first sentence was about. If a page is the browser's home page, it launches when the browser launches. The browser's home page is its default page.

In any case though, a refresh on page load can be done for any page, but then you see it load, then load again unless the body is set to visibility:hidden during the first load. However, the only way I know of accomplishing the reload only once would be to add a query string to the URL, so that the browser would know not to reload a second time, third time, etc., which would create an endless loop if allowed. However, once you add that query string to the URL, it is possible that someone would launch with it, thus avoiding the intended reload (either by copying it or saving it as their browser's home/default page. And, on another front, the reload would happen anytime the page was reached using the URL without the query string.

Is it really a problem when the page and its resource files are cached, which would generally be the case if this were the home/default page in the browser?

lio
11-07-2009, 10:27 PM
For sure, an automatic refresh on echa page is not an good solution.

I try to load the page with script once IE is loaded : I think I had faced the same issue somtimes, but the fact is that it doesn't appear this evening... or only in rare cases :confused:

I have also tryed x times to load IE with the page with VFS script as default page, to clear the browser history when the problem appears, and load again : after that, the slideshow starts normally (I am not sure in 100% of the cases; I should try more times).

<meta http-equiv="Cache-Control" content="no-cache" />" does not seem to be THE solution :o

jscheuer1
11-08-2009, 01:46 AM
<meta http-equiv="Cache-Control" content="no-cache" />

That's sort of going in the opposite direction. My point is that if they make it their default/home page, in like 99% of cases the page and its resource files will be cached, so no problem. It would only be in those 1% of cases where they clear their cache in between launches, that there would be a problem, and then only some of the time. And, as I say, that would be an issue with most pages on the web. So, unless I'm misunderstanding what's at stake here, I would call this a non-issue.