Blankman
Blankman

Reputation: 267230

referencing a url like src="//www.example.com/blah.js"

I've seen references for images and .js files like:

src="//www.example.com..."

is this a technique so it works in both http and https?

Upvotes: 4

Views: 603

Answers (1)

CrayonViolent
CrayonViolent

Reputation: 32527

yes. If you leave off the protocol, most modern browsers will use whatever is being used by the current page.

Upvotes: 3

Related Questions