• 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
Getting URL information from Explorer using JavaScript
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Getting URL information from Explorer using JavaScript


  • Subject: Getting URL information from Explorer using JavaScript
  • From: macgix <email@hidden>
  • Date: Wed, 3 Oct 2001 22:39:18 +0200

Another way to do this with IE (4.5 or 5.x) is:

-- ------

tell application "Internet Explorer"
set the_url to do script "javascript:window.location;"
end tell

-- "the_url" contains the current frontmost URL as string

-- ------

Don't know, if this is the correct syntax because i am sitting in front of
my PB190 running 7.6.1 and cannot look up my sources in the company by now
and it's right late in the eve here. ;)

But this is the way my "Picture Grabber" catches the URL from Explorer.

Kind Regards,

Thomas

>From: Daniel Blanken <email@hidden>
>
>For IE try this:
>
>=============
>tell application "Internet Explorer"
> --get information for frontmost window (i.e. the window with index -1)
> set the_info to (GetWindowInfo -1)
> --the result is a list in format {[URL of the window],[Title of the
>window]}
> set the_URL to (item 1 of the_info) as string
>end tell
>--return the URL of frontmost window as string
>return the_URL
>==============
>
>The current version of Netscape isn't installed on my machine, so I cannot
>give you a solution here, sorry.
>
>Greetings!
>Daniel Blanken
>



---------------------------------------
macgix Thomas Johannes Matthias K|hner

Developer, Supervisor, Manager
email@hidden
www.macgix.com / www.macgix.de


  • Prev by Date: Re: What about facespan
  • Next by Date: Re: Applescript Studio Announced Today
  • Previous by thread: Re: Getting info out of Mail messages
  • Next by thread: Re: Applescript Studio Announced Today
  • Index(es):
    • Date
    • Thread