Trying to get Rhoelements to work with an existing html5 javascript application.

Hello

I'm trying to get an existing application running on a ES400.  The application uses html5, jquery mobile and phonegap on a iPhone.  Currently in the log I get the following when I try to run the app.

ERROR: Engine  agent., line 0: undefined

SECURITY_ERR: DOM Exception 18: An attempt was made to break through the security policy of the user agent., line 0: undefined

0 2012-01-25 15:41:48

Any ideas.

Thanks

John

Robert Galvin
JohnWhat happens when you

John

What happens when you change your Startpage Config.xml entry from:

<StartPage value="http://localhost" /> 

to point to the actual starting page like:

<StartPage value=http://localhost/index.html /> 

My understanding of Phonegap is that it takes the applicatiion (html/js/css) files and wraps a native webview around it. I am assuming you are not trying to run the actual Phonegap application, but the same html/js/css files that it uses. Can you share the starting page

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


John Barnes
RobThanks for the response. 

Rob

Thanks for the response.  My start page is http://localhost:8080/index.html it starts to render in that it changes the background image.  But it doesn't render any more of the html.  The project normally uses phonegap, but I've taken the phonegap out.

John

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Nrusingha Chara...
Hello John.Is it possible for

Hello John.

Is it possible for you to share the index.html and config.xml files.

Thanks

Patro

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


John Barnes
Here is my config.xml and

Here is my config.xml and index.html

Thanks for the continued help.

John

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Gary Crean
Is there anywhere in the

Is there anywhere in the application that is trying an AJAX call to a file:// url.

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


John Barnes
Thanks for the response.  It

Thanks for the response.  It doesn't look like there are any calls to file://

John

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


John Barnes
HelloJust an update and

Hello

Just an update and another question.  It turns out the problem had to do with a local database.  I've bypassed it and the first page comes up.  If I execute the page using http the page comes up.  If I use file I get an message error in page.  I assume this is some ajax problem.  Our app is a collection of html5 and javascripts.  The change page in the index causes the next screen to come up which is a login screen.  But it seems the javascript referenced in the html isn't being called.  Any ideas on this?

Thanks

John

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Gary Crean
Hi John,What size database

Hi John,

What size database are you trying to create when you open it, I've seen in the past some users try and create a database larger than what is set in the Config.xml file.

The zip file you have attached to the forum, references many other JavaScript files, Without these it's hard for me to comment, If you are happy to email them, I can take a look for you.

Regards.

Gary.

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Robert Galvin
Hi John It sounds like you

Hi John

It sounds like you are trying to run the html/js files from the local file system by having the startpage=file:// . If this is the case, then it is a violation of Ajax security policy. Check the Web Server information in the help file. RhoElements comes with a built in Web Server so it will serve up local pages via http:// this should get your application to work:

Config.xml:

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


John Barnes
RobThanks for the response. 

Rob

Thanks for the response.  I've tried to use the web server, it didn't change any thing.  I'm including my config.xml

Thanks for the help

John

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Nrusingha Chara...
Hello John,Put your

Hello John,

Put your Rhoelements application in any location(\myweb in root folder) of device.

Configure the below XML tags in config.xml

<Enabled         Value="1"/>

<Port               Value="8080"/>

<WebFolder     Value=" \myweb"/>

Provide a link to the URL of the webfolder location inside your exisiting application like http://localhost:8080/index.htm

Try to access the RE app now form your existing application.

Does it help??

Thanks

Patro

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Darryn Campbell
PatroThanks for responding. 

Patro

Thanks for responding.  I tried this but still no luck.  My web folder is www at root.  Still getting the same error.

John

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Log in to post comments