[pmwiki-users] SSL Migration & Coexistance etc.
Patrick R. Michaud
pmichaud at pobox.com
Sun Jun 4 11:59:39 CDT 2017
On Sun, Jun 04, 2017 at 04:35:58PM +0200, Walter Keller wrote:
> $PubDirUrl = 'http://www.mydomain.com/path/to/pub';
> ===> $PubDirUrl = '//www.mydomain.com/path/to/pub';
> By the definition of URIs, the browser use http: or https: as in the
> current request and everything works like a charme.
> (1) I propose to change sample-config.php accordingly - or can anybody
> see a disadvantage here?
1a. Historically, some browsers and web consumers don't properly handle the '//...' link format. Yes, technically such browsers are out of specification, but "your browser is out of spec" isn't exactly the message many sites want to be transmitting to their visitors. And desktop browsers aren't the only consumers of web content -- we also have reader apps on smart phones, search engine spiders, site analysis tools, etc.
PmWiki strives to follow a "strict in what it produces, liberal in what it accepts" philosophy. The "strict" part of that implies that any urls we produce really ought to be as complete as possible.
1b. There are a number of sites recommending against relative URLs:
1c. The sample-config.php file serves several purposes; one of them is to help get things up and running quickly, and another is to educate. A lot of newcomers aren't going to be familiar with the nuances of relative-scheme URLs, and are likelier to be confused upon seeing a "url" that doesn't include a scheme. They might not even recognize it as a url. In the interest of keeping sample-config.php as accessible to newcomers as possible, I'd prefer it to continue to use the full url.
So, while I completely recognize the value of relative-scheme urls, I think its usage belongs in cookbook or discussion and not something that is considered a best default practice. I totally accept that others' may have different views on this.
> (3) while integrating the newest sample-config.php, I had to change
> ==> include_once("$FarmD/scripts/xlpage-utf-8.php");
> I guess this is necessary for every wikifarm and should
> be changed in sample-config.php
Again, sample-config.php's intended audience has traditionally been newcomers... and I really didn't want to burden a newcomer with "What's this $FarmD variable used for?!" when they're unlikely to be using a farm anyway for their initial setup. If this change is made, it'd be the _only_ reference to $FarmD (or farming) inside of sample-config.php. I think I'd rather keep the simplicity for now... someone who is building a WikiFarm will be able to figure out the need for $FarmD pretty quickly I think. (Perhaps your experience here was otherwise.)
Thanks for the excellent suggestions and analysis!
More information about the pmwiki-users