Question

I am using brackets to edit a simple HTML document. The document refers to a CSS hosted on a CDN:

<head>
    <title>Test server monitor</title>
    <link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css">
</head>

This call works perfectly from the production server. However, when loaded in Chrome using the Live Preview mode, the external CSS is not loaded. I guess the reason is some cross-site limitation.

How do I allow Chrome to use A CSS from a CDN called from a local file?

Was it helpful?

Solution

You can fix this relatively easy, simply change your href to:

http://netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css

The http: ensures the correct protocol is being implemented for the request.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top