Community @ The Turning Gate

Support community for TTG plugins and products.

NOTICE

The Turning Gate's Community has moved to a new home, at https://discourse.theturninggate.net.

This forum is now closed, and exists here as a read-only archive.

  • New user registrations are disabled.
  • Users cannot create new topics.
  • Users cannot reply to existing topics.

You are not logged in.

#1 2014-08-27 21:14:24

garyhouk
Member
Registered: 2014-08-26
Posts: 12

Publisher and HTTPS image paths

Hello,

Is there a way to disable publisher from using https in the image path? The thumbnails on my site aren't showing up bc I don't have an ssl cert and really don't want to pay $100 for one.

Tx,

Gary

Offline

#2 2014-08-27 22:25:18

rod barbee
Moderator
From: Port Ludlow, WA USA
Registered: 2012-09-24
Posts: 17,830
Website

Re: Publisher and HTTPS image paths

which presentation are you using? I'm not seeing this in any of my tests.

what other configurations are you using?

can you post a link?


Rod 
Just a user with way too much time on his hands.
www.rodbarbee.com
ttg-tips.com, Backlight 2/3 test site

Offline

#3 2014-08-27 22:32:12

garyhouk
Member
Registered: 2014-08-26
Posts: 12

Re: Publisher and HTTPS image paths

Hi Rod,

Tx for the response. I used publisher to create a gallery and published it here: http://www.garyhouk.com/galleries/weddings/  If you look at the 'view source' you'll see they are prefixed with https. If you copy the url and paste it in the browser the image is not found due to the https. Remove the s, and you'll see my image is indeed there.

Tx,

Gary

Offline

#4 2014-08-27 23:45:20

rod barbee
Moderator
From: Port Ludlow, WA USA
Registered: 2012-09-24
Posts: 17,830
Website

Re: Publisher and HTTPS image paths

First, get the spaces out of the template name. Files and folder name should contain only letters, numbers, underscores, or dashes.


secondly, your host server is running under Windows:
http://www.garyhouk.com/lib/autoindex/verify.php

TTG requires Linux OS and Apache servers. But first try getting those spaces out and see if that works.


Rod 
Just a user with way too much time on his hands.
www.rodbarbee.com
ttg-tips.com, Backlight 2/3 test site

Offline

#5 2014-08-28 02:21:19

garyhouk
Member
Registered: 2014-08-26
Posts: 12

Re: Publisher and HTTPS image paths

Hey Rod,

Ok, point taken. I removed the space but it made no difference. If you look at the source code on www.terrywhitephotography.com in his galleries, everything is http, not https. My gallery page consistently has https in the image path: http://www.garyhouk.com/galleries/album/index.php  I can't find an option anywhere to turn it off. I'm not on Linux/Apache, but for something this trivial that shouldn't make a difference (unless Matt's using conditioning to add in https if you aren't on an Apache server!), which I highly doubt. Any other ideas?

Tx so much,

Gary

Offline

#6 2014-08-28 03:24:08

rod barbee
Moderator
From: Port Ludlow, WA USA
Registered: 2012-09-24
Posts: 17,830
Website

Re: Publisher and HTTPS image paths

The server requirements for TTG specify a Linux server. Occasionally people have gotten away with using a Windows server but Windows server hosting is not supported.

Everything in all my galleries are also http, not https. This is a hosting issue I think

Any other ideas?

change hosting


Rod 
Just a user with way too much time on his hands.
www.rodbarbee.com
ttg-tips.com, Backlight 2/3 test site

Offline

#7 2014-08-28 03:32:13

garyhouk
Member
Registered: 2014-08-26
Posts: 12

Re: Publisher and HTTPS image paths

Hey Rod,

Ok, I'll change hosts. Does everyone seem to be using Blue Hosting for the most part? Any others you'd recommend?

Tx,

Gary

Offline

#8 2014-08-28 03:42:48

rod barbee
Moderator
From: Port Ludlow, WA USA
Registered: 2012-09-24
Posts: 17,830
Website

Re: Publisher and HTTPS image paths

I've been happy with Blue Host. And if you use Matt's link like the one you can find at the bottom of any of the product pages it's only $4.95/mo (at 36 months)


Rod 
Just a user with way too much time on his hands.
www.rodbarbee.com
ttg-tips.com, Backlight 2/3 test site

Offline

#9 2014-08-28 08:42:18

Ben
Moderator
From: Melbourne, Australia
Registered: 2012-09-29
Posts: 4,399

Re: Publisher and HTTPS image paths

Apache servers do not supply a setting for $_SERVER['HTTPS'] when viewing through http.  The framework therefore only checks that this value is set or not set to determine whether links should use the http or https protocol.
Your site is running on IIS, which always creates a setting for $_SERVER['HTTPS'], set to 'on' or 'off' depending on how the site is accessed.  Therefore the assumption that a set value implies access via https fails on your server, and links are created with https in all cases.

You can fix this by changing line 165 in ttg-be/framework/helpers/URLHelper.php from:

if (!empty($_SERVER['HTTPS'])) {

to:

if (!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off') {

I'll add this IIS-specific fix to the framework for a future maintenance release.  Let me know if you're not comfortable in updating that line and I'll email you the amended file.

Last edited by Ben (2014-08-28 08:45:36)

Offline

#10 2014-08-28 09:45:39

garyhouk
Member
Registered: 2014-08-26
Posts: 12

Re: Publisher and HTTPS image paths

Hey Ben,

Tx for the code change! I'm a developer by day so that was no problem at all to change. I definitely think it would be a good idea to add it in for a maintenance release. In my case, I'm just trying it out on my personal site before I put it on my photography site so this worked perfectly for the gallery. The issue with not being on Apache may still stop me from getting everything up, but for now it's one less problem to deal with.

Best Regards,

Gary

Offline

#11 2014-08-28 10:32:14

Ben
Moderator
From: Melbourne, Australia
Registered: 2012-09-29
Posts: 4,399

Re: Publisher and HTTPS image paths

Hi Gary,  I'm glad that worked.  IIS is a tricky one, since we don't have the resources to test against it, and some of the behaviour of PHP differs from that on Apache.  We try to fix issues that customer's encounter, but don't provide any guarantees or assurance that we will solve problems encountered on Windows servers, especially those running IIS.

Offline

#12 2014-08-28 12:13:23

garyhouk
Member
Registered: 2014-08-26
Posts: 12

Re: Publisher and HTTPS image paths

Hey Ben, since we are on the topic of IIS vs Apache, could you quickly tell me whether the auto-index is failing bc I'm on IIS? If you look at http://www.garyhouk.com/galleries.php you'll see that the file path is actually the physical drive path. Is this another issue similar to the image paths and IIS?

Offline

#13 2014-08-28 12:15:09

garyhouk
Member
Registered: 2014-08-26
Posts: 12

Re: Publisher and HTTPS image paths

BTW - You can see that the gallery is up there and appears to be working fine: http://www.garyhouk.com/galleries/breanna

Offline

#14 2014-08-28 12:28:01

Matthew
Administrator
From: San Francisco, CA
Registered: 2012-09-24
Posts: 5,795
Website

Re: Publisher and HTTPS image paths

The auto index does not support IIS:
http://www.garyhouk.com/lib/autoindex/verify.php


Matt

The Turning Gate, http://theturninggate.net

Offline

#15 2014-08-28 12:33:56

garyhouk
Member
Registered: 2014-08-26
Posts: 12

Re: Publisher and HTTPS image paths

Ok, that's what I needed to know. Time to contact Blue Hosting. ;-)

Offline

Board footer

Powered by FluxBB