Ticket #40 (closed enhancement: fixed)

Opened 22 months ago

Last modified 21 months ago

Option to disable some URL encoding (AND pseis.org update)

Reported by: rselzler Owned by: sheep
Priority: High Milestone: 1.4.0
Component: Hatta Wiki Version: 1.3.3dev
Keywords: URL encoding option Cc:

Description

Encoding '/' as '%2F', when displayed in URLs, is distracting for me, because subdirectories are used extensively in PSEIS. Worse, I really don't want to impose this encoding on my users (or explain it to them)! I haven't been able to hack it out myself, so I'm hoping you might provide guidance or an option to disable encoding (at least for '/' !).

See also my  http://hatta-wiki.org/Randy page and request for comments regarding  http://pseis.org/wiki/index

BTW, I did notice when the Hatta site was down briefly...
I hope as is well :) --Randy

Change History

comment:1 follow-up: ↓ 2 Changed 22 months ago by sheep

  • Keywords option added
  • Priority changed from Normal to High
  • Version changed from unknown to 1.3.3dev
  • Status changed from new to accepted
  • Milestone set to 1.4.0

I will add such option as a temporary measure, but I really think that users should not need to know about such details, understand them and above all, make decissions about them. It should Just Work (tm).

I will think about different solution than the encoding, something that would be more robust. However, I can't promise when I can work on it. If you want to have a go yourself, it's done in the wiki_link and wiki_image methods (I should de-duplicate that code, by the way, and move it to a single function).

comment:2 in reply to: ↑ 1 Changed 22 months ago by rselzler

Replying to sheep:

I will add such option as a temporary measure, but I really think that users should not need to know about such details, understand them and above all, make decissions about them. It should Just Work (tm).

I will think about different solution than the encoding, something that would be more robust. However, I can't promise when I can work on it. If you want to have a go yourself, it's done in the wiki_link and wiki_image methods (I should de-duplicate that code, by the way, and move it to a single function).

Encoding does work in some respects, but not others. For example, which of these two (equivalent) URLs are easier to understand? Cut-n-paste into Wiki markup? Cut-n-paste into command lines? Cut-n-paste when browsing? In my opinion, the later is clearly better.

 http://pseis.org/user%2Ftutor%2Fface%2Fgui

 http://pseis.org/user/tutor/face/gui

--Randy

comment:3 follow-up: ↓ 4 Changed 22 months ago by sheep

The problem is that these two are *not* equivalent. Compare

 http://pseis.org/+history/something/1

with

 http://pseis.org/+history/something%2F1

Yes, I know, this is bad design of the history URLs. I wonder if I could fix it now.

comment:4 in reply to: ↑ 3 ; follow-up: ↓ 5 Changed 22 months ago by sheep

Sorry, it looks like I pointed you into the wrong direction.
To disable escaping of slashes in link generation you just need to add them to the safe="" (replace it with safe="/") in the WikiTitleConverter object.

comment:5 in reply to: ↑ 4 Changed 22 months ago by rselzler

Replying to sheep:

Sorry, it looks like I pointed you into the wrong direction.
To disable escaping of slashes in link generation you just need to add them to the safe="" (replace it with safe="/") in the WikiTitleConverter object.

This fix is, well... nothing less than orgasmic !

THANK YOU HATTA 8P

You did it for me again !!!

comment:6 Changed 21 months ago by sheep

  • Status changed from accepted to closed
  • Resolution set to fixed

There is now no %-escaping for slashes in Hatta. It was only problematic.

Note: See TracTickets for help on using tickets.