• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Getting url variables without a browser
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Getting url variables without a browser


  • Subject: Re: Getting url variables without a browser
  • From: Lee Noble <email@hidden>
  • Date: Thu, 3 Feb 2005 15:02:40 +0000


On Feb 3, 2005, at 14:48, Emmanuel wrote:

At 9:41 AM +0000 2/3/05, Lee Noble wrote:
	tell application "System Events"
		set theOldClipboard to the clipboard
		tell process "Firefox"
			tell window 1
				-- select the address bar
				keystroke "l" using command down
				-- copy url to the clipboard
				keystroke "c" using command down
				delay 3
			end tell

I don't like having to use all that flaky UIScript so if there is a way to avoid it can someone let me know.

I'm not replying to the whole question but, regarding that part above I would use Safari, and write something like:


tell app "Safari" to set theURL to URL of document 1

Is Safari an option for you?

This being said, you may have to call a bit of javascript to make sure the URL is completely loaded, otherwise I'm not sure what Safari will return to you.

Emmanuel

No, sorry. Safari is not an option. As I said the people who made the site I am accessing are VERY Windows oriented and in Safari when submitting the form the popup window does not appear, even if you disable popup blocking. Firefox is the first browser I tried which allowed me to successfully download the file but its AppleScript support is pretty bad which is why I'm having to use UIScripting.
I don't think logging in with Safari and then switching to Firefox will work will it. Do you think the session will be retained between browsers?
I'll maybe give it a go when I get a chance. Unless someone saves me the time and says that would be ridiculous, don't even try it.


Lee

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Getting url variables without a browser (From: Lee Noble <email@hidden>)
 >Re: Getting url variables without a browser (From: Emmanuel <email@hidden>)

  • Prev by Date: Re: Scripting Excel 2004 macros
  • Next by Date: Re: Scripting Excel 2004 macros
  • Previous by thread: Re: Getting url variables without a browser
  • Next by thread: Remote Apple Events
  • Index(es):
    • Date
    • Thread