Consider the following examples:
Protocol Relative CSS URL
<link href="//example.com/wp-content/themes/twentytwelve/style.css" />
More appropriately called a “network-path reference” or “scheme-relative path”, a protocol-relative URL helps to avoid common scenarios such as:
- Broken SSL padlock icon in browser’s address bar when showing mixed HTTP/HTTPS content
- Error message in Internet Explorer saying, “This Page Contains Both Secure and Non-Secure Items”
- Serving HTTP assets when viewing HTTPS pages
The idea of using protocol-relative URLs was popularized by Paul Irish and has become common as sites switch between serving HTTP and HTTPS assets.
This plugin will standardize all properly enqueued theme files to use protocol-relative paths, even those added from third-party plugins.
- Activate the plugin through the Plugins menu in the WordPress admin.
Life saving plugin. After moving to HTTPs, a lot of the assets from Masterslider broke and caused very broken looking homepages.
Installation of this plugin fixed that, no configuration required.
As fabian mentioned, this won’t update the images on the site to pull from HTTPs.. but it’s not designed to do that, and many images are hard coded by your CSS; so it’s hardly fair to give this plugin less than 5 stars as it does exactly as it promises.
Contributors & Developers
“Protocol Relative Theme Assets” is open source software. The following people have contributed to this plugin.Contributors
Interested in development?
- Initial release