Fixed URL's to use location.protocol.