I am trying to migrate my existing html5 app into a metro app, and finding two major hurdles:
- .innerHtml is not supported due to security reason
- $.Ajax just doesn't work (I am using jsonp for data exchange from server)
Questions:
- How do I bypass the security issue for .innerHtml?
- What other alternative do I have to make $.Ajax work?
Q2: I had the similar problem, and I changed my $.get to:
Q1: WinRT block throws exceptions or warnings when you use
.innerHtml
for dynamic content. But they don't block you from using.innerHTML
all the time. Have you triedtoStaticHTML
method like following:Q2: regular javascript
xhr
call works for me. Actually I believed that I used.ajax
to send some simpleGET
orPOST
request before, but ended up usingxhr
for some other reasonsHope this helps.