We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 40088
    • 708 Posts
    Revo 2.5.8
    NP 3.0.4

    The button.css ’sheet that NP is adding to the head tag is using a relative url which is throwing a SSL browser warning.

    I have configured the site to use absolute https urls which works fine except with this one NP asset.

    I need to either force an absolute url or stop NP from loading the file.
      Todd
      • 3749
      • 24,544 Posts
      This is the code that does that:

      $assetsUrl = $modx->getOption('np.assets_url', null, MODX_ASSETS_URL . 'components/newspublisher/');
      $modx->regClientCss($assetsUrl . 'css/button.css');


      Since you don't have an np.assets_url System Setting, the code is using the MODX_ASSETS_URL, which should be https unless you've hard-coded a non-https URL in config.inc.php. I'm surprised this doesn't cause problems elsewhere.

      Do you have code to force https in your .htaccess file? That might solve it.

      If none of that helps, you can create a System Setting with the key: np.assets_url and put your absolute URL to the assets directory as the value. Be sure it ends in a slash. That should survive any upgrades to NP or MODX.



        Did I help you? Buy me a beer
        Get my Book: MODX:The Official Guide
        MODX info for everyone: http://bobsguides.com/modx.html
        My MODX Extras
        Bob's Guides is now hosted at A2 MODX Hosting