My ASP.NET MVC3 website, www.mysite.com, retrieves images from images.mysite.com. When I do not go to my site and do not use SSL, it works flawlessly. However, when you log in, it gets
Only protected content is displayed.
message in IE9. I understand it. What is the best way to handle URL switching for my images? Should I check if I am currently using SSL, and redirect my images to https://images.mysite.com , otherwise http://images.mysite.com ?
EDIT: This is an e-commerce site, so most of the time the site is viewed without protection. But after logging in, I still need to pull out some of the same images, and, of course, if they return to the regular catalog page, access to the images will be required. I might just have to always use https://images.mysite.com . It just seemed redundant.
source share