Discussion:
Embedded Documentation Force Trailing Slash?
(too old to reply)
MKG
2018-06-28 14:49:50 UTC
Permalink
Hi Fossil Users,

I'm trying to setup a site using fossil embedded documentation and since run into an issue. Here I have a document "test/index.md" in the file tree. When accessing the file with the following url "<base url>/index.cgi/doc/trunk/test/" it works as expect. But without the trailing slash "<base url>/index.cgi/doc/trunk/test" the document isn't served.

<base url>/index.cgi/doc/trunk/test/ ---> works
"<base url>/index.cgi/doc/trunk/test ---> doesn't work

Technically, this is correct but I'm wondering if there is a way to add the trailing slash when necessary to make it more usable. BTW I'm using CGI and the server runs Apache.

Thanks.

MKG.
Richard Hipp
2018-06-28 15:08:58 UTC
Permalink
Post by MKG
<base url>/index.cgi/doc/trunk/test/ ---> works
"<base url>/index.cgi/doc/trunk/test ---> doesn't work
Technically, this is correct but I'm wondering if there is a way to add the
trailing slash when necessary to make it more usable.
I don't recall a way of making the /doc webpage do that.
--
D. Richard Hipp
***@sqlite.org
MKG
2018-06-28 16:05:35 UTC
Permalink
Thanks for the reply. It would be great if the following feature request be considered for future versions.

Currently if a FILE ends in "/" then the names "FILE/index.html", "FILE/index.wiki",
and "FILE/index.md" are tried in that order. If no "/" at the end, if the FILE is not found a 404 is served.

Changing it to if a FILE doesn't end in "/" and also if the FILE isn't found, then it should be tried as a directory and hence the "FILE/index.html", "FILE/index.wiki" and "FILE/index.md" should be tried. Failing all of that a 404 should be served.

I can file a feature request using the Fossil ticketing system if you'd like.

Thanks again.
Post by Richard Hipp
Post by MKG
<base url>/index.cgi/doc/trunk/test/ ---> works
"<base url>/index.cgi/doc/trunk/test ---> doesn't work
Technically, this is correct but I'm wondering if there is a way to add the
trailing slash when necessary to make it more usable.
I don't recall a way of making the /doc webpage do that.
--
D. Richard Hipp
_______________________________________________
fossil-users mailing list
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
Loading...