The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

SSL Folder - access insecure content

Discussion in 'General Discussion' started by monkey64, Feb 21, 2012.

  1. monkey64

    monkey64 Well-Known Member

    Joined:
    Nov 6, 2011
    Messages:
    86
    Likes Received:
    0
    Trophy Points:
    6
    cPanel Access Level:
    Root Administrator
    I have an SSL folder as well as a non SSL part to my site.

    If I'm in my SSL folder, referencing any insecure images outside the SSL 'wrapper' gives me the "Parts of the page you are viewing were not encrypted before being transmitted over the Internet" in FF. Expected.

    The way I would usually deal with this issue, is to make a copy of my images folder within the SSL folder. But that could turn out to be an admin nightmare becuase I have two sets of images to update.

    Is it possible to reference content by using a different method? Perhaps using PHP's document root? What is the recommended method?

    I have found this article:
    Creating symlinks to redirect your site

    But I don't want to blindly screw up my WHM installation or plunge my website into a technological abyss!
    Any ideas?
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,854
    Likes Received:
    675
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    My suggestion would be to edit the script configuration to call the images from the direct path, as opposed to the URL. For example, when linking the images in your script, use:

    Code:
    /home/username/public_html/path/to/image.jpg
    Instead of:

    Code:
    http://example.com/path/to/image.jpg
    This will allow it to be accessed via a secure and non-secure URL.

    Thank you.
     
  3. monkey64

    monkey64 Well-Known Member

    Joined:
    Nov 6, 2011
    Messages:
    86
    Likes Received:
    0
    Trophy Points:
    6
    cPanel Access Level:
    Root Administrator
    Michael.

    Thanks for that, but I since discovered that I can create a shortcut (think they are called Aliases).
    WinSCP has the option of creating a new "link", which I found allows you to access material via a secure and non-secure URL.

    The main advantage with this method is that the ULS stay the same. I will keep your code above in mind though.

    Thanks
     
Loading...

Share This Page