• Resolved lernerconsulting

    (@lernerconsult)


    WordPress Multisite installed on multisiterootdomain.com
    Running ASA on a site with domain mapped to mappeddomain.dom (so mapped.multisiterootdomain.com gets mapped to mappeddomain.com).

    Collection not displaying on page

    Calls to admin-ajax.php have the wrong domain name. This generates an error (visible in Firefox Inspector) “Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at multisiterootdomain.com//wp-admin/admin-ajax.php. (Reason: CORS header ‘Access-Control-Allow-Origin’ missing).”

    The domain for admin-ajax.php should have the mapped domain, the domain of the site calling ASA. Also, there is that double slash / .

    /wp-admin/options-general.php?page=amazonsimpleadmin%2Famazonsimpleadmin.php&task=collections#manage_collection
    Clicking the Collection Browse button does properly display the Amazon items in the collection.
    Example of one of the ajax calls shows in the Inspector in the Parameters tab:
    action asa_async_load
    asin B0008D6WBA
    nonce c9541dcc6d
    params {“items”:”20″}
    tpl default

    Test on /wp-admin/options-general.php?page=amazonsimpleadmin%2Famazonsimpleadmin.php&task=test
    “Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://multisiteroot.com//wp-admin/admin-ajax.php. (Reason: CORS header ‘Access-Control-Allow-Origin’ missing).”
    action asa_async_load
    asin B0008D6WBA
    nonce f80e74f0fa
    params []
    tpl book

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter lernerconsulting

    (@lernerconsult)

    Collection (and individual ASA shortcodes) display properly if un-check “Use asynchronous mode (AJAX)” in ASA1 Options tab.

    Plugin Author Timo

    (@worschtebrot)

    Thanks for your feedback. I’ll check this for the next update and improve ASA1 for multisite usage.

    Please keep in mind that ASA1 is totally free and meant for the Amazon affiliate starter. For advanced users, there is ASA2 (https://getasa2.com/) which has a much larger range of functions. It’s multisite compatible and tested with all latest PHP7 versions.

    Plugin Author Timo

    (@worschtebrot)

    The wrong AJAX URL in multisite installations got fixed with version 1.3.0. Thanks for pointing that out.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Wrong URL in WP Multisite, for /wp-admin/admin-ajax.php’ is closed to new replies.