💾 Archived View for bbs.geminispace.org › u › mbays › 11328 captured on 2024-05-12 at 18:54:44. Gemini links have been rewritten to link to archived content
⬅️ Previous capture (2024-05-10)
-=-=-=-=-=-=-
I guess I'm missing something. I just sourcedived to see what's going on, and it seems to me that because of the isEmpty_Range check in postOpenLinkCommand_DocumentWidget_ in ui/documentwidget.c, enabling "assume prompt" on urls with non-empty query does nothing at all. I think I'm suggesting simply deleting that check. The feature then works with gemkerkerkruip (and various other things on my capsule which work similarly). What could it break?
2023-10-30 · 6 months ago
🚀 mbays · 2023-11-01 at 12:28:
I just realised a subtlety I've been missing in the above -- I'd been assuming that empty query is equivalent to no query, but actually that doesn't seem to be prescribed in the gemini spec (unless I'm missing it?), and RFC 3986 indicates that it only holds if it's explicitly mandated in the scheme spec. Spellbinding actually makes use of this, responding with 10 on no query ([...]/cgi) but not on empty query ([...]/cgi?). It's tricky to use this though -- at least with molly brown, the variables passed to cgi scripts can't differentiate between these two.
🕹️ skyjake [OP/mod...] · 2023-11-02 at 13:40:
I think I'm suggesting simply deleting that check.
It's not quite that simple. If this feature was allowed with URLs that already have a query string, the expected behavior would be that the query string in the URL is pre-filled into the query prompt, so the user can edit it before sending it out. Also, other UI changes would be necessary to enable this behavior for a given link on the page.
It would solve this particular issue with Gemkerkerkruip, I think, although perhaps not in the most elegant way. The user would still get the `!?` in the prompt and would have to overwrite it...
empty query is equivalent to no query
According to RFC 3875 (CGI 1.1), at least in the web world the QUERY_STRING must be set to "" if the query component is missing from the URL. So CGI applications are indeed unable to make a distinction between those two cases.
I also don't think this is currently addressed in the Gemini spec, and did mention some time ago to @solderpunk that it would be nice to have an official companion spec for Gemini server CGI.
As it stands, Gemini applications don't have to use CGI, so they can check directly if a query component is present or not in the request URL and behave differently as needed. (Bubble has several cases of this, for example.)
Gemkerkerkruip — A gaming pick for Saturday: the roguelike text adventure Kerkerkruip by Victor Gijsbers and contributors, ported to Gemini by @mbays. I think there's something fascinating about combining text adventures with roguelikes.
💬 skyjake [mod...] · 12 comments · 2 likes · 2023-10-28 · 6 months ago