AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

FireFox Webpage Loaded

 
Reply to topic    AutoHotkey Community Forum Index -> Scripts & Functions
View previous topic :: View next topic  
Author Message
jjm
Guest





PostPosted: Fri Oct 26, 2007 6:56 pm    Post subject: FireFox Webpage Loaded Reply with quote

I'm fairly new to Autohotkey, but found that the suggested solution for determining if a webpage has loaded doesn't seem to work with Firefox. I came up with this workaround which seems to work for me (Assuming FF is your default browser):

Code:
FFLoad(site,title)
{
    run, %site%
    WinWait, %title%
    SendInput, ^u
    WinWait, Source of:
    SendInput, ^w
    return
}


Supposing we're loading cnn.com:

Code:
FFLoad("http://www.cnn.com","CNN.com - Breaking News")


Basically we run the web address, then wait for the Title to change which won't happen until it's gotten a title from the HTML source. Then we hit CTRL-U which brings up the 'View Source' window. This window's title will change to "Source of: ...", but -not until- the source file is fully downloaded. We then hit CTRL-W to close that Window and find a fully loaded page (However the images may not all have been downloaded, but this shouldn't matter for the most part if you're navigating without the mouse.)

~JJM
Back to top
tank



Joined: 21 Dec 2007
Posts: 3700
Location: Louisville KY USA

PostPosted: Mon Oct 12, 2009 5:10 pm    Post subject: Reply with quote

wow quite an interesting way of doing this thanks
_________________

We are troubled on every side‚ yet not distressed; we are perplexed‚
but not in despair; Persecuted‚ but not forsaken; cast down‚ but not destroyed;
Back to top
View user's profile Send private message
shajul



Joined: 15 Sep 2006
Posts: 564

PostPosted: Thu Oct 15, 2009 7:24 am    Post subject: One more way.. Reply with quote

One other way is to set up a greasemonkey script to add a unique word to the tilte of each website, and wait till that word is found in the page title. Greasemonkey scripts are applied only after the page is loaded. Ajax is an exception.
Back to top
View user's profile Send private message Visit poster's website Yahoo Messenger
Matiko
Guest





PostPosted: Tue Nov 16, 2010 3:04 am    Post subject: Will not work reliably Reply with quote

This will not work for slow connections, so the use makes no sense.

Firefox preloads the title so you will have a nearly empty sourcefile.

it would work if you do that in a loop and "break" if some string is detect. But ifso why not just download the webpage to check for string? i do

regards
Back to top
x79animal



Joined: 01 May 2010
Posts: 1020
Location: England

PostPosted: Tue Nov 16, 2010 3:10 am    Post subject: Reply with quote

yes this does basically nothing as the so called "Source of:" will always come up regardless of whether its loaded.
Back to top
View user's profile Send private message Send e-mail MSN Messenger
Display posts from previous:   
Reply to topic    AutoHotkey Community Forum Index -> Scripts & Functions All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group