Skip to content
Browse files

Allow scheme-relative urls

URLs starting with "//" will choose the scheme of the current page.  This allows more flexibility when loading content from CDNs.
  • Loading branch information...
1 parent 099d9c8 commit 2b3e0b79bd6673ebb60f0c3541480cbfc861f2ad @serveace committed Apr 16, 2013
Showing with 1 addition and 0 deletions.
  1. +1 −0 web/webkit/src/main/scala/net/liftweb/http/Req.scala
View
1 web/webkit/src/main/scala/net/liftweb/http/Req.scala
@@ -551,6 +551,7 @@ object Req {
!updated.startsWith("javascript:") &&
!updated.startsWith("http://") &&
!updated.startsWith("https://") &&
+ !updated.startsWith("//") &&
!updated.startsWith("#"))
rewrite.openOrThrowException("legacy code").apply(updated) else updated)
}

0 comments on commit 2b3e0b7

Please sign in to comment.
Something went wrong with that request. Please try again.