Support » Plugin: Nice Navigation » [Plugin: Nice Navigation] Hardlinking to http://, Mixed Content Pop-ups, Fix

  • On sites where the URL is https://, the Nice Navigation plugin is returning http:// instead (hard linking to http:// instead of being relative)

    Examples in header:

    <link rel='stylesheet' id='nice-navigation-css'  href='http://mysite/wp-content/plugins/nice-navigation/styles.css?ver=1.2' type='text/css' media='screen' /></strong>
    <strong><script type='text/javascript' src='http://mysite/wp-content/plugins/nice-navigation/script.js?ver=1.2'></script>

    While the other header references use https:// correctly:

    <link rel='stylesheet' id='thickbox-css'  href='https://mysite/wp-includes/js/thickbox/thickbox.css?ver=20090514' type='text/css' media='all' />
    <script type='text/javascript' src='https://mysite/wp-includes/js/l10n.js?ver=20101110'></script>
    <script type='text/javascript' src='https://mysite/wp-includes/js/jquery/jquery.js?ver=1.6.1'></script>

    This causes those annoying pop-ups with handling mixed content in IE:


    WP_PLUGIN_URL // full url, no trailing slash
    [the wordpress site itself must be set up for http]
    This line grabs what wordpress is reporting as the plugin url

    NOTE: These constants are *not SSL aware*. Apparently they are intended for Core use, not Plugins. See

    SOLUTION: Change reference from WP_PLUGIN_URL to plugins_url() on this line

    define( "NICE_NAVIGATION_URL", plugins_url() . '/nice-navigation/');

  • The topic ‘[Plugin: Nice Navigation] Hardlinking to http://, Mixed Content Pop-ups, Fix’ is closed to new replies.