A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://stackoverflow.com/questions/49200397/how-to-remove-defaults-in-jquery-smoothstate below:

javascript - How to remove defaults in Jquery smoothState?

Edit: Have you tried to add the specific class lists to the smoothState.js blacklist?

Initialized smoothState.js like this:

blacklist: '#form'

The error occurred because of the same-origin policy:

https://developer.mozilla.org/en-US/docs/Web/Security/Same-origin_policy

What will cause this error message: Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource

Some information: JSONP is a communication technique used in JavaScript programs running in web browsers to request data from a server in a different domain, something prohibited by typical web browsers because of the same-origin policy.

JSONP takes advantage of the fact that browsers do not enforce the same-origin policy on script tags. Note that for JSONP to work, a server must know how to reply with JSONP-formatted results. JSONP does not work with JSON-formatted results.

Links: Have a look at wikipedia JSONP

How to fix this? I would really prefer using jQuery where you can add dataType : 'jsonp'. This will solve the request error.

Some jQuery code:

   $.ajax({
        type: "GET",
        url: 'https://gc.synxis.com/rez.aspx?Hotel=0000&Chain=00000&template=RBE&shell=RBE',
        async:true,
        dataType : 'jsonp',   //add this data type
        crossDomain:true,
        success: function(data, status, xhr) {
            alert(xhr);
        }
    });

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4