application.showURL

Working with rc7 and OS X 10.3 I have an issue with showURL.

While using application.showURL(‘website’) I get the following errormessage:

‘java.lang.NoClassDefFoundError’…

Don’t know what happens here but it looks like a bug :cry:

In rc7 we found a way to also open a browser in developer instead only in client, but this seems not to work on mac (no problem on windows)
Behavior changed back to old bahavior for MAC only.
Will be available in release after 1.2rc8
Note: in client running on mac you shoud not have a problem.

Well Jan, I just checked this with rc8 but I don’t have a clue what happens… In other words nothing happens… Not on mac developer (as you said) not on mac client and not on Linux client. Don’t know for Windows!

application.showURL(‘http://www.servoy.com’) is not working in your client??

absolutely. It does NOT. I have it with a fixed url, an url taken from a field and it doesn’t work!

BTW I placed in it a global method but I guess that won’t make any difference…

If you do place it in a global do not use ’ (single quotes, which indicates text)
So application.showURL(‘website’) SHOULD be application.showURL(website)

OK Jan. Thanks, that one did the trick!

The other one is that the field NEEDS “http://” in front of the address. The example doesn’t show that in Developer BTW…

Added to sample text, thanks for pointing out

Jan Blok:
If you do place it in a global do not use ’ (single quotes, which indicates text)
So application.showURL(‘website’) SHOULD be application.showURL(website)

but what about this?

var url = 'http://www.somedomain.com/index.shtml?id=';
url += id_client;
application.showURL(url);

It doesn’t work on Mac Client :(

no browser is showing? got an error in .log.txt?

Jan Blok:
no browser is showing? got an error in .log.txt?

The browser (Safari) doesn’t show anything.

works brilliant here. Does this work?

application.showURL(‘http://www.servoy.com’)

are you running developer or client?
Which version of OS X?
Which version of Java?
Which version of Servoy?

jaleman:
works brilliant here. Does this work?

application.showURL(‘http://www.servoy.com’)

It’s very strange… It works:

application.showURL('http://www.servoy.com')

but It doesn’t work!!

var url = 'http://www.servoy.com';
application.showURL(url)

are you running developer or client?
Which version of OS X?
Which version of Java?
Which version of Servoy?

Client, Mac OS X 10.4.3, Java 1.4.2-54, Servoy R2 2.2.3-build 335[/code]

Strange, are you sure you don’t have a typo somewhere? Try copy pasting the code below:

var url = 'http://www.servoy.com'
application.showURL(url)

The code above works brilliant on exactly the same system as you specced.

jaleman:
Strange, are you sure you don’t have a typo somewhere?

I’m sorry… :oops:

There were some espaces in the URL, and showURL doesn’t work:

var name = 'John Smith';
var url = 'http://www.something.com?name=' + name;
application.showURL(url);

I’ve changed the code:

var name = escape('John Smith');

and it works. Thanks!!

is escape a know function in Servoy?

I never saw of heard of it!

HJK:
is escape a know function in Servoy?

I never saw of heard of it!

Servoy supports all core javascript functions. There are many references available. Here’s one:

http://developer.mozilla.org/en/docs/Co … _Reference

HJK:
is escape a know function in Servoy?

I never saw of heard of it!

Harjo,

The escape() - and unescape() - functions are part of the core JavaScript
library of functions. However, these two functions have been deprecated
because they do not work properly for non-ASCII characters.

For more information, see this URL:
http://www.js-examples.com/javascript/core_js15/fcns.php#1012712


Marc Norman
Servoy