Millet mobile phone Load assests directory of the HTML file loading does not come out of the problem __html

Source: Internet
Author: User

Today, I run my project on the Millet 5 mobile phone, found in the load assests directory of HTML files can not load out, but I have no problem on other mobile phones, and then I carefully went to see the log inside the monitor, found that there are such a line: uncaught securityerror:failed to execute ' replacestate ' on ' History ': cannot is created in a document with Origin ' null ', I checked online, but There was no result and finally found it on stack overflow.
Stack Overflow Address: http://stackoverflow.com/questions/32453806/ uncaught-securityerror-failed-to-execute-replacestate-on-history-cannot-be
found that the need to add a line of JS code in HTML, Stack overflow above the idea is to add three lines of code, in fact, only to add a sentence is enough, the following is my code to deal with this problem:

  <script>
    $ (document). Bind (' Mobileinit ', function () {
        $.mobile.pushstateenabled = false;
    });
</script>

Add the position of the code of this sentence I use a screenshot to tell you:

It's OK to add this line between Jquery-1.11.1.min.js and Jquery.mobile-1.4.5.min.js.
You are welcome to correct me.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.