How do I Open a Browser Window from Android?

Get help using Construct 2

Post » Fri Oct 09, 2015 6:37 pm

I'm fairly certain I've done this before...

On Touch -> MyButton = Browser Location ("www.example.com")

So it works when testing.

When I export and try on my Android Device, the browser doesn't open or respond at all!

Any one know why?
B
14
S
5
Posts: 26
Reputation: 1,070

Post » Sat Oct 10, 2015 5:13 am

Are you using the Browser Object?
Image
B
75
S
23
G
3
Posts: 673
Reputation: 9,283

Post » Sat Oct 10, 2015 9:45 pm

Yes, using the Browser object. It appears that there is a bug with the latest version of Intel XDK - and it would usually work.

Waiting for a fix apparently....
B
14
S
5
Posts: 26
Reputation: 1,070

Post » Mon Oct 12, 2015 11:44 am

@cybertron7 - any chance you can post a short demo somewhere for us to debug it? I know InAppBrowser works (I'm using it now).
Intel Corporation
B
5
S
2
Posts: 133
Reputation: 871

Post » Mon Oct 12, 2015 5:20 pm

@imaffett

It's probably less of a bug than anything. I'm just using the normal "browser" object to try and open a URL.

So I installed Cranberry PhoneGapInAppBrowser which allows me to target the "_SYSTEM" rather than in app browser.

This makes the Android App use it's native browser to launch, and solves my problem.
B
14
S
5
Posts: 26
Reputation: 1,070

Post » Wed Nov 11, 2015 5:09 pm

cybertron7 wrote:I'm fairly certain I've done this before...

On Touch -> MyButton = Browser Location ("www.example.com")

So it works when testing.

When I export and try on my Android Device, the browser doesn't open or respond at all!

Any one know why?




I am running into the exact same thing.
Who dares wins
B
57
S
17
G
21
Posts: 1,878
Reputation: 19,572

Post » Wed Nov 11, 2015 5:32 pm

lennaert wrote:
cybertron7 wrote:I'm fairly certain I've done this before...

On Touch -> MyButton = Browser Location ("www.example.com")

So it works when testing.

When I export and try on my Android Device, the browser doesn't open or respond at all!

Any one know why?




I am running into the exact same thing.



Adding an astrix to the internal whitelist on intelxdk solves the problem .... (or specify urls)


<_<
Who dares wins
B
57
S
17
G
21
Posts: 1,878
Reputation: 19,572

Post » Wed Nov 11, 2015 7:32 pm

alibest23 wrote:@cybertron7 @lennaert The probelem is not in construct 2 :) this probelem happen for me whene i copile my zipe file with cocoon :p .. he have so bugs :p anyway try compile your project zip with " Ludia " and it will work :)




I posted the solution above.

The security kep the app from opening an un specified URL, due to security measures.

You can either add approved URLs to the internal/external whitelist of the intelxdk settings for your app or add an astriks "*" to allow all.
Who dares wins
B
57
S
17
G
21
Posts: 1,878
Reputation: 19,572

Post » Mon Oct 17, 2016 9:15 am

@imaffett
Hello

little offtop
Probably you know about sound delay problem.
On mobile it's about 0.5 sec .
For example:
in my game when player press button
works animation then after about 0.5 sec play sound.
this delay absolutly ruined gameplay expereince.
Maybe you know when in XDK will fix it ?
Image
B
14
S
6
G
5
Posts: 99
Reputation: 3,825

Post » Mon Oct 17, 2016 4:38 pm

@Chigabooga -- the XDK builds standard Cordova (aka PhoneGap) apps. It has no bearing on the way your apps are initialized, how they run or how the various Cordova plugins work. Thus, there is no "fix" that the XDK can provide to deal with the audio delay issue you are experiencing. I recommend you search Stack Overflow for issues related to Cordova or PhoneGap apps and audio delays, and include keywords in your search regarding the plugin or HTML5 technique you are using to play your audio. Any solutions you find for Cordova/PhoneGap apps can be applied to an app built with the XDK, since it simply builds a Cordova app.
Intel Corporation
B
13
S
3
Posts: 79
Reputation: 925

Next

Return to How do I....?

Who is online

Users browsing this forum: No registered users and 9 guests