sKunKbad Posted June 13, 2009 Share Posted June 13, 2009 I've got a js file that calls some image files, but I need the locations of the images in the file to be absolute, because they are called from dirs and sub-dirs. The problem is I get the secure/unsecure items warning, so I'm looking for a way to have javascript determine to use https or http. Haven't found anything yet. Quote Link to comment Share on other sites More sharing options...
Axeia Posted June 13, 2009 Share Posted June 13, 2009 How about another approach, simply get the url via javascript and then paste your relative path after that.. and use that full path? Quote Link to comment Share on other sites More sharing options...
.josh Posted June 13, 2009 Share Posted June 13, 2009 document.location.protocol Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.