# Image\_tag + ssl

**URL:** <https://www.ruby-forum.com/t/image-tag-ssl/59433>\
**Category:** Rails\
**Created:** [May 3, 2006, 7:06pm UTC](https://www.ruby-forum.com/t/image-tag-ssl/59433 "2006-05-03T19:06:27Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![joe-dumoulin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/9dc877/32.png) [@joe-dumoulin](https://www.ruby-forum.com/u/joe-dumoulin)\
**Post date:** [May 3, 2006, 7:06pm UTC](https://www.ruby-forum.com/t/image-tag-ssl/59433/1 "2006-05-03T19:06:27Z")

</div>

Hi,

If request.env[“HTTPS”] == “on”, shouldn’t image\_tag generate image  
URLS that use HTTPS?

Joe

---

<div class="post-metadata">

**Author:** ![joe-dumoulin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/9dc877/32.png) [@joe-dumoulin](https://www.ruby-forum.com/u/joe-dumoulin)\
**Post date:** [May 3, 2006, 7:06pm UTC](https://www.ruby-forum.com/t/image-tag-ssl/59433/2 "2006-05-03T19:06:49Z")

</div>

Joe Van D. wrote:

> Hi,
> 
> If request.env[“HTTPS”] == “on”, shouldn’t image\_tag generate image  
> URLS that use HTTPS?

If it’s not a complete URL I don’t think it’s necessary.

e.g. if the page URL is [https://www.exmaple.com](https://www.exmaple.com) and there’s a ![](https://www.ruby-forum.com/public/images/mygif.gif) the gif will automatically get loaded  
over HTTPS IIRC.

Try right clicking the image and select “view image” or whatever it’s  
called in your browser.

Jeroen
