Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 629087
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T19:42:26+00:00 2026-05-13T19:42:26+00:00

I’m having trouble understanding how this method works. From the documentation, it specifies: canOpenURL:

  • 0

I’m having trouble understanding how this method works.

From the documentation, it specifies:

canOpenURL: Returns whether an
application can open a given URL
resource.

- (BOOL)canOpenURL:(NSURL *)url

Parameters url A URL object that
identifies a given resource. The URL’s
scheme—possibly a custom
scheme—identifies which application
can handle the URL.

Return Value NO if no application is
available that will accept the URL;
otherwise, returns YES.

Discussion This method guarantees that
that if openURL: is called, another
application will be launched to handle
it. It does not guarantee that the
full URL is valid.

Availability Available in iPhone OS
3.0 and later. Declared In UIApplication.h

Specifically, if it:

guarantees that that if openURL: is called, another application will be launched to handle it.

Then for example, if I pass in tel://HELLOWORLD, it returns YES, and when I’m attempting to openUrl, the phone application is not calling it. Nothing happens, so I’m assuming the full url is not valid when attempting to dial the number.

I understand that it does not validate the full URL, but by design, why is it not showing me an error or something if I am unable to dial the number?

Basically what I’m wondering is: what is it exactly validating?

I’m not convinced that it just checks for the handler type and the apps that support that specific handler (tel:// in this case will not work for iPod Touch for example.).

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T19:42:26+00:00Added an answer on May 13, 2026 at 7:42 pm

    Validation is not the purpose of this function. It is only checking whether there is an application registered for this url scheme.

    E.g. on the iPod touch or iPad, there is no phone app, and thus canOpenURL will return NO for tel: urls.

    Or if you ask it for an url with the foo: scheme, it will return true if the user device has any App installed that claims to handle this scheme.

    It can’t possible validate the url, because it doesn’t know anything about the foo scheme or whatever scheme the next app developer comes up with. And you won’t want to load the App to validate the url at this point, either.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

link Im having trouble converting the html entites into html characters, (&# 8217;) i
Does anyone know how can I replace this 2 symbol below from the string
For some reason, after submitting a string like this Jack’s Spindle from a text
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
I'm having trouble keeping the paragraph square between the quote marks. In firefox the
I have a jquery bug and I've been looking for hours now, I can't
this is what i have right now Drawing an RSS feed into the php,
I have this code to decode numeric html entities to the UTF8 equivalent character.
We're building an app, our first using Rails 3, and we're having to build

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.