• 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: Parsing Link Information
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Parsing Link Information


  • Subject: Re: Parsing Link Information
  • From: julifos <email@hidden>
  • Date: Thu, 02 Jan 2003 21:26:45 +0000

> I have set up a system of launching files from Explorer. (Beyond the file
> types that are already registered, and beyond applications.)
>
> One of my methods (which I quite like) was to create a pseudo-protocol and
> register it in Internet control panel (I'm using OS9.1.2), associated with
> my Script Appliation, and then have the script launch and handle the link
> information, sort of like the Finder.
>
> The method works fine for direct script calls (if the script app doesn't
> need input), but I am having trouble passing link data to the script, as a
> parameter or property or event or whatever.
>
> I can not find a direct reference to what information (property?) is passed
> along with the "open" that is sent to the script app.

You'd receive an "open" event with parameters only if you set up your
internet preferences with a "post-process download with app x" (being "x"
your droplet).

on open reference_to_file
--...
end open

> For instance, in my psueduo-protocol (which works when NOT passing data, but
> fails when passing data), I want to be able to access the X/Y/Z in the
> following:
>
> gary://X/Y/Z
>
> Although I can't see the events being fired off by IE, I can imagine that
> the protocol triggers some event and then passes along the X/Y/Z.
>
> Does anyone know how to reference what is passed along?
>
> For instance, if you were to click a URL <ftp://some.server/path/>
> I can see that my FTP client (as registered in Helper Apps) gets invoked and
> then must get the "some.server/path/" information in some form.
>
> If the helper app is an applescript application, in what form is that
> information being passed?

All protocol helpers may receive a standard apple event

<<event GURLGURL>> string

So, if this stuff did not changed in os x, you should handle this event
within your droplet, which will compile as standard additions' command "open
location":

on open location (the_url)
-- the_url should be "gary://X/Y/Z"
end open location

Also, "the_url" is url-encoded, so "gary://hello dolly/" will turn into
"gary://hello dolly/"...

... Let me know if this already works! ;-)

JJ
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

  • Prev by Date: Changing owner Name
  • Next by Date: Re: FM Omitted property
  • Previous by thread: Re: Parsing Link Information
  • Next by thread: turning tiff into jpeg
  • Index(es):
    • Date
    • Thread