WordPress.org

Ready to get started?Download WordPress

Forums

WP FullCalendar
Events do not appear in IE 8 & 9 when admin and frontend schemes are different (1 post)

  1. Dylan Barlett
    Member
    Posted 2 months ago #

    When FORCE_SSL_ADMIN is true, admin_url() returns an HTTPS URL. If is_ssl() is false (i.e. the frontend page is accessed over HTTP), there is a scheme mismatch that prevents the call to admin-ajax.php from working in IE 8 & 9. This is a limitation of XDomainRequest used in IE < 10 - see #7 on http://blogs.msdn.com/b/ieinternals/archive/2010/05/13/xdomainrequest-restrictions-limitations-and-workarounds.aspx.

    Steps to reproduce (WP FullCalendar 0.8.4):

    1. Add define('FORCE_SSL_ADMIN', true); to wp-config.php
    2. Add [fullcalendar] to a page
    3. View page over HTTP in Chrome or Firefox - events appear
    4. View page over HTTP in IE 8 or 9 - events do not appear
    5. View page over HTTPS in IE 8 or 9 - events appear

    Fix: modify localize_script() in wp-fullcalendar.php:

    //$js_vars['ajaxurl'] = admin_url('admin-ajax.php');
    if( is_ssl() ) {
        $js_vars['ajaxurl'] = admin_url('admin-ajax.php', 'https');
    } else {
        $js_vars['ajaxurl'] = admin_url('admin-ajax.php', 'http');
    }

    https://wordpress.org/plugins/wp-fullcalendar/

Reply

You must log in to post.

About this Plugin

About this Topic

  • RSS feed for this topic
  • Started 2 months ago by Dylan Barlett
  • This topic is not resolved
  • WordPress version: 3.7.1