Webjames .htaccess problem
Jim Nagel (444) 25 posts |
Webjames is not obeying certain .htaccess files in my local website. For instance: (That autoindex shows 001.php among the other files, and if I click it, Webjames does serve it.) In the log file (!Syslog.Logs.Webjames) I see these lines: This has been happening since I upgraded Webjames from Chris Gransden’s 2013 patch to his 2016 patch (thanks to someone in this forum who gave the secret link). Is there some setting I need to change? I’m boggled. (The identical files uploaded to my ISP webhost behave correctly.) |
Rick Murray (539) 13840 posts |
Because WebJames is not Apache. Ignore everything you read online about the content of the htaccess file. That which is described in WebJames’ help is that which is supported (basically it’s a restricted form of the Attributes file).
Because that is Apache. If I were you, I’d configure WebJames to refer to a /webjames file and leave /htaccess for the sole use of Apache (it’s a setting in the Config file). |
Jim Nagel (444) 25 posts |
This is in Webjames.Help in its History section: As I said earlier, the 2013 (and 2007) versions of Webjames did obey my .htaccess files in exactly the same way as Apache does and still does. My problem is with the 2016 Webjames update (which I only in the past 10 days discovered and installed); maybe I need to revise some obscure setting in Wj, but what? |
Rick Murray (539) 13840 posts |
The help also says:
|
Jim Nagel (444) 25 posts |
Here is the entirety of my .htaccess file in the directory in question. Nothing complicated. Webjames 2016 does not obey either of the two commands (# is a comment), whereas Webjames 2013 and Apache do obey them. Why is the 2016 incarnation of Webjames throwing up the “Unknown attribute” stuff in the log, whereas the 2013 Webjames and Apache are happy? |
John Sandgrounder (1650) 574 posts |
!WebJames was re-complied some time ago for Ras Pi 3 comatibility. Maybe, it was re-complied using an out-of-date source code. The “re-compiled for Pi 3” version which I have is dated 08 October 2016. I downloaded it in May 2017. It did what I wanted, so I did not do any further regression testing (like htaccess). This looks like something we will have to look out for when we need a version for the Pi 4. |
Jim Nagel (444) 25 posts |
I dug around in my backups and found some old Syslog files for Webjames, which would date from when I was using the 2013 incarnation of it (ie, ancestor of the 2016 version you mention). And I’m surprised to find the lines like “Unknown attribute: directoryindex” in the OLD logfile too. So I’m wrong in my earlier posts today about this being new in the 2016 version of Webjames. Perhaps when Alex Waugh added support for .htaccess files way back in 2000 (see my quote from History), it was before the .htaccess HQ had invented commands such as “directoryindex” and “options”? I have no idea. I second and third the motion that out-of-date sources be revisited in compiling the eventual Pi4 version of Webjames. And the built-in Autoindex module should be opened for customization by the user (perhaps by a reference in Attributes). |