On Sep 15, 2:30 pm, Matt Patenaude <[EMAIL PROTECTED]> wrote:
> OK, so, I've got a weird iPhone problem. One of the web applications
> I'm working on has to test for the existence of a function, and if it
> exists, execute it.
>
> On a normal browser, I'd do something like this:
>
> if (functionName) functionName(params);
If you don't know whether the function exists or not, and therefore
you really don't know what value the identifier 'functionName' refers
to, you probably should use a strict test:
if (typeof functionName == 'function') {
// use functionName
}
> And it works perfectly on every browser I've tried, including Safari 3
> Beta. However, it not only fails on the iPhone, but appears to trigger
> some sort of error.
You might try Firebug Lite for debugging:
<URL: http://www.joehewitt.com/blog/firebug_for_iph.php >
--
Rob
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"iPhoneWebDev" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/iphonewebdev?hl=en
-~----------~----~----~----~------~----~------~--~---