πΎ Archived View for gemi.dev βΊ gemini-mailing-list βΊ 000830.gmi captured on 2023-11-04 at 13:08:25. Gemini links have been rewritten to link to archived content
β‘οΈ Next capture (2023-12-28)
-=-=-=-=-=-=-
Hi I am playing with server implementation for Gemini and I bumped into one case where I feel the behavior is not strictly specified so I would appreciate your help and clarification on it: Link in Gemini document can be relative link but how is actually defined behavior for relative link `../`? I have instinctively expected that it would work like `cd ..` on Linux but I have experienced that many clients treat it as "Back" button in classical browser - e.g. takes you to the previously visited page. What is the "correct"/expected/specified behavior for this case? Thanks for your help -- Sgiath GPG: 0x70f9c7de34cb3bc8
I would definitely expect it to be equivalent to "cd ..", just as you say. I.e. "Up" rather than "Back". This is how relative links work everywhere else*, I believe. Cheers, ew0k
Sgaith <Sgiath at pm.me> writes: > Hi I am playing with server implementation for Gemini and I bumped into one case where I feel the behavior is not strictly specified so I would appreciate your help and clarification on it: > > Link in Gemini document can be relative link but how is actually defined behavior for relative link `../`? I have instinctively expected that it would work like `cd ..` on Linux but I have experienced that many clients treat it as "Back" button in classical browser - e.g. takes you to the previously visited page. What is the "correct"/expected/specified behavior for this case? > > Thanks for your help It's really strange that a ../ link behaves like a back button, you may want to report that to the authors of your clients; `..' should take you "up" one level[0]. That said, if you're writing a server don't forget to clean the path you receive, because a client could send a request with one or more .. component in it. Omar Polo [0] the URL rfc specifies a cleaning algorithm that removes every .. path component with the preceding non-.. component.
On Tue, Mar 23, 2021 at 10:08:48AM +0100, Omar Polo <op at omarpolo.com> wrote a message of 22 lines which said: > [0] the URL rfc specifies a cleaning algorithm that removes every > .. path component with the preceding non-.. component. This is RFC 3986 <gemini://gemini.bortzmeyer.org/rfc-mirror/rfc3986.txt>, and, indeed, it is standard, it is not up to client's choice.
On Tuesday, March 23rd, 2021 at 10:54, Stephane Bortzmeyer <stephane at sources.org> wrote: > On Tue, Mar 23, 2021 at 10:08:48AM +0100, > > Omar Polo op at omarpolo.com wrote > > a message of 22 lines which said: > > > [0] the URL rfc specifies a cleaning algorithm that removes every > > > > .. path component with the preceding non-.. component. > > This is RFC 3986 > > gemini://gemini.bortzmeyer.org/rfc-mirror/rfc3986.txt, and, indeed, > > it is standard, it is not up to client's choice. Thanks everyone for response. I will fill this as bug than. --- Sgiath GPG: 0x70f9c7de34cb3bc8
---