how to set url type in launchservices.plist

  • Hi to all,

    My application needs to be launched via safari (something like aim:
    or mailto:).
    I found the file launchservices.plist where I think the system stores
    all these infos.
    Can I add a simple NSDictionary inside that file in this way?

    <key>LSHandlers</key>
    <array>

      <dict>
      <key>LSHandlerRoleAll</key>
      <string>com.apple.ichat</string>
      <key>LSHandlerURLScheme</key>
      <string>aim</string>
      </dict>
    </array>

    Or are there any other places where I have to make this change?
    Thank you all

    Yorh

    ps: I cannot find any documentation about this file anyone has a link?
  • This should be all you need to launch your app in this method.
    However, if you also want to find out the URL you are being asked to
    open, you need some additional code.

    Let me know if this is the case and I can dig out an example.

    Mike.

    On 5 Oct 2006, at 14:17, Yorh wrote:

    > Hi to all,
    >
    > My application needs to be launched via safari (something like aim:
    > or mailto:).
    > I found the file launchservices.plist where I think the system
    > stores all these infos.
    > Can I add a simple NSDictionary inside that file in this way?
    >
    > <key>LSHandlers</key>
    > <array>
    >
    > <dict>
    > <key>LSHandlerRoleAll</key>
    > <string>com.apple.ichat</string>
    > <key>LSHandlerURLScheme</key>
    > <string>aim</string>
    > </dict>
    > </array>
    >
    > Or are there any other places where I have to make this change?
    > Thank you all
    >
    > Yorh
    >
    > ps: I cannot find any documentation about this file anyone has a link?
    >
    > _______________________________________________
    > Do not post admin requests to the list. They will be ignored.
    > Cocoa-dev mailing list      (<Cocoa-dev...>)
    > Help/Unsubscribe/Update your Subscription:
    > http://lists.apple.com/mailman/options/cocoa-dev/mike.abdullah%
    > 40gmail.com
    >
    > This email sent to <mike.abdullah...>
  • Hi and thks for support,

    My only needs is to open my app via safari (or other browsers) link
    like mailto: that open mail or aim: that open Adium or ichat.

    thank you
    Yorh

    On 05/ott/06, at 17:44, Mike Abdullah wrote:

    > This should be all you need to launch your app in this method.
    > However, if you also want to find out the URL you are being asked
    > to open, you need some additional code.
    >
    > Let me know if this is the case and I can dig out an example.
    >
    > Mike.
    >
    > On 5 Oct 2006, at 14:17, Yorh wrote:
    >
    >> Hi to all,
    >>
    >> My application needs to be launched via safari (something like
    >> aim: or mailto:).
    >> I found the file launchservices.plist where I think the system
    >> stores all these infos.
    >> Can I add a simple NSDictionary inside that file in this way?
    >>
    >> <key>LSHandlers</key>
    >> <array>
    >>
    >> <dict>
    >> <key>LSHandlerRoleAll</key>
    >> <string>com.apple.ichat</string>
    >> <key>LSHandlerURLScheme</key>
    >> <string>aim</string>
    >> </dict>
    >> </array>
    >>
    >> Or are there any other places where I have to make this change?
    >> Thank you all
    >>
    >> Yorh
    >>
    >> ps: I cannot find any documentation about this file anyone has a
    >> link?
    >>
    >> _______________________________________________
    >> Do not post admin requests to the list. They will be ignored.
    >> Cocoa-dev mailing list      (<Cocoa-dev...>)
    >> Help/Unsubscribe/Update your Subscription:
    >> http://lists.apple.com/mailman/options/cocoa-dev/mike.abdullah%
    >> 40gmail.com
    >>
    >> This email sent to <mike.abdullah...>
    >
  • On Oct 5, 2006, at 3:17 PM, Yorh wrote:

    > My application needs to be launched via safari (something like aim:
    > or mailto:).
    > I found the file launchservices.plist where I think the system
    > stores all these infos.
    > Can I add a simple NSDictionary inside that file in this way?

    I don't think you should do this.

    > Or are there any other places where I have to make this change?

    See http://developer.apple.com/documentation/MacOSX/Conceptual/
    BPRuntimeConfig/Articles/PListKeys.html#//apple_ref/doc/uid/
    20001431-102207

    Best Regards,

    Nir Soffer
  • Oh God, I've just re-read this.  Please do not modify this file!  I
    had misread your post and thought you were talking about your app's
    info.plist file.  That is the one you need to put your URL stuff into.

    Mike.

    On 10 Oct 2006, at 20:36, Nir Soffer wrote:

    >
    > On Oct 5, 2006, at 3:17 PM, Yorh wrote:
    >
    >> My application needs to be launched via safari (something like
    >> aim: or mailto:).
    >> I found the file launchservices.plist where I think the system
    >> stores all these infos.
    >> Can I add a simple NSDictionary inside that file in this way?
    >
    > I don't think you should do this.
    >
    >> Or are there any other places where I have to make this change?
    >
    > See http://developer.apple.com/documentation/MacOSX/Conceptual/
    > BPRuntimeConfig/Articles/PListKeys.html#//apple_ref/doc/uid/
    > 20001431-102207
    >
    >
    >
    >
    > Best Regards,
    >
    > Nir Soffer
    >
    > _______________________________________________
    > Do not post admin requests to the list. They will be ignored.
    > Cocoa-dev mailing list      (<Cocoa-dev...>)
    > Help/Unsubscribe/Update your Subscription:
    > http://lists.apple.com/mailman/options/cocoa-dev/mike.abdullah%
    > 40gmail.com
    >
    > This email sent to <mike.abdullah...>
previous month october 2006 next month
MTWTFSS
            1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31          
Go to today