Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Web and WebWorks Development

Reply
Contributor
tranhuutam2001
Posts: 10
Registered: ‎11-04-2012
My Device: BB10 Dev Alpha A
My Carrier: Viettel
Accepted Solution

XMLHttpRequest cannot load

hi Community,

 

I found this weird thing and want to ask you guys, please help me if you met it before.

 

My app work well in Riple Simulator but run this error "XMLHttpRequest cannot load" when running on Dev Alpha.

But when I try to change the version of Widget tags in config.xml to 2.0.0.0, something like 

<widget xmlns="http://www.w3.org/ns/widgets"
xmlns:rim="http://www.blackberry.com/ns/widgets"
version="2.0.0.0"

 

The app work well, both in Riple and Dev Alpha

But if the version is 1.0.0.0, it just run on Riple, but not in Dev Alpha.

 

Could you tell me the difference of version 1.0 and 2.0?

One more info, I use 1.0 in WebWork SDK 1.0.2,  2.0 in SDK 1.0.1

 

I'm so confused,

Any help would be appreciated

 

Thanks

Please use plain text.
Developer
Pumano-
Posts: 215
Registered: ‎11-05-2011
My Device: Z10
My Carrier: Beeline

Re: XMLHttpRequest cannot load

try use latest SDK + you need to whitelisted your website (like http://site-where-i-download-something-using-xmlhttprequest.com ) at config.xml

Please use plain text.
Developer
Deepu_George_Jacob
Posts: 235
Registered: ‎12-13-2011
My Device: Curve 9380
My Carrier: Vodafone-IN

Re: XMLHttpRequest cannot load

hi,

 

Get xml as a string and converted into xml by using Dom.... I am using this type of method to get and parse xml...

 

Thanks

Deepu

Please use plain text.
Developer
The_Anomaly
Posts: 322
Registered: ‎08-06-2012
My Device: Dev Alpha / Playbook / Curve 9300

Re: XMLHttpRequest cannot load

As Pumano said you need to "whitelist" ANY website your app that it needs to access outside of your phone.  Do this using the <access... tag.  Read up in the HTML5 docs about the config.xml and access.

If it helped you, click like. :smileyhappy:
Please use plain text.
Contributor
tranhuutam2001
Posts: 10
Registered: ‎11-04-2012
My Device: BB10 Dev Alpha A
My Carrier: Viettel

Re: XMLHttpRequest cannot load

hi guys,

Thanks all for your helps,

I try the guide in this page https://developer.blackberry.com/html5/documentation/securing_your_ww_app_1866986_11.html

 

It works properly,
I also like all your reply and accept as solution, appreciate for all
 

 

Please use plain text.