html - What does `//` in javascript's src attribute do? -
this question has answer here:
- is valid replace http:// // in <script src=“http://…”>? 12 answers
- can change http:// links //? 6 answers
i'm using facebook's javascript sdk , has double forward slashes. mean?
<script src="//connect.facebook.net/en_us/all.js"></script>
i know single /
means root directory, //
? telling source use http://
, path?
this "protocol-relative" link. uses http or https depending on used load current page.
Comments
Post a Comment