-2

I am working on a site that is fully under https. The issue is that one of the pages calls an image that is not secure so I am having mixed content on that specific page. How can I change this call to have it secured?

<img src="<%=carImage%>" width="430" height="220" align="right" border="0">

Do I have to go to the source and change the actual carImage class, or can I just change it from here?

A.J
  • 1,140
  • 5
  • 23
  • 58
  • `https` is a "communication protocol", the transport layer. It does not matter _what_ you transport, nor does it matter to what you transport _how_ it is transported. You certainly do _not_ have to modify an image to deliver it via another protocol! Good god! – arkascha Oct 06 '16 at 22:12
  • Giving all the credit to what @arkascha already have sad, if the image source has this format : `http://example.com/images/my_image` you are not allowed to do it. – Franco Oct 06 '16 at 22:18

1 Answers1

2

I'm assuming carImage returns a protocol inclusive URL such as http://domain.com/something.ext. You'd need to change this to return an HTTPS URL.

If the image is on the same domain as the page you're viewing it on, consider making these image src values relative (i.e., remove http://domain.com or https://domain.com from the value returned by carImage)

Anand Bhat
  • 5,591
  • 26
  • 30