Skip to content
This repository has been archived by the owner on May 7, 2024. It is now read-only.

Hosted app tutorial does not work properly #343

Closed
vas85 opened this issue Feb 5, 2016 · 5 comments
Closed

Hosted app tutorial does not work properly #343

vas85 opened this issue Feb 5, 2016 · 5 comments

Comments

@vas85
Copy link

vas85 commented Feb 5, 2016

When I use the latest update and Cordova 5.4.1 and the hosted app tutorial:
http://taco.visualstudio.com/en-us/docs/create-a-hosted-app/

I get the following error:
"APPHOST9624: The app can’t use script to load the https://cordovahostedweb-starter.azurewebsites.net/ url because the url launches another app. Only direct user interaction can launch another app."

The error is triggered by this line:
window.location.replace(targetUrl);

The allow-navigation tag is set to the following in config.xml and the CSP is set the same as in the tutorial

Can you please have a look? This seems like a severe issue

@vas85
Copy link
Author

vas85 commented Feb 5, 2016

Tag @Mikejo5000 @kirupa

@Mikejo5000
Copy link
Contributor

Hi Vas,
I'll take a look. Do you get this error on targeting Windows? What OS? See this error on any other targets? On Windows 10, please verify that you have "Windows 10.0" selected in config.xml, Windows tab (Windows target version). Win81 is not supported in this sample...

@vas85
Copy link
Author

vas85 commented Feb 5, 2016

Ah. I think that might be my problem. When I select Windows 10.0 I get an error about the UWP platform version being too old. Does that get fixed if I update VS?

Thanks for your help

@Mikejo5000
Copy link
Contributor

That should get fixed on the VS update; when you start the update, check the optional features to install and make sure that "Universal Windows App Develoment Tools" is selected. It should get selected automatically when you choose to install Cross-plat Mobile Development/ "HTML/JavaScript (Apache Cordova) Update 5", but I'd just make sure about it.

@vas85
Copy link
Author

vas85 commented Feb 5, 2016

Verified updating to the latest version of VS and selecting "Windows 10.0" in config.xml fixed it.

Thanks!

@vas85 vas85 closed this as completed Feb 5, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants