- Include URL *wikipedia.org/*
- Exclude URL *wikipedia.org/*?useskin=monobook
- Redirect To $1wikipedia.org/$2?useskin=monobook
Proper syntax for URL Rewriter on Wikipedia for article sections Topic is solved
Moderators: FranklinDM, Lootyhoof
-
- Lunatic
- Posts: 463
- Joined: 2019-08-13, 00:30
- Location: Casumia
Proper syntax for URL Rewriter on Wikipedia for article sections
I use URL Rewriter. I do not know how regular expressions work, so I use the following wildcard settings:
Browser: Pale Moon (Pusser’s repository for Debian)
Operating System: Linux Mint Debian Edition 4 (amd64)
※Receiving Debian 10 LTS security upgrades
Hardware: HP Pavilion DV6-7010 (1400 MHz, 6 GB)
Formerly user TheRealMaestro: æsc is the best letter.
Operating System: Linux Mint Debian Edition 4 (amd64)
※Receiving Debian 10 LTS security upgrades
Hardware: HP Pavilion DV6-7010 (1400 MHz, 6 GB)
Formerly user TheRealMaestro: æsc is the best letter.
-
- Keeps coming back
- Posts: 784
- Joined: 2020-11-03, 06:47
- Location: Philippines
Re: Proper syntax for URL Rewriter on Wikipedia for article sections
This wildcard should work for links that have section names in it:
- Include URL *wikipedia.org/*#*
- Exclude URL *wikipedia.org/*?useskin=monobook#*
- Redirect To $1wikipedia.org/$2?useskin=monobook#$3
merry mimas
XUL add-ons developer. You can find a list of add-ons I manage at http://rw.rs/~job/software.html.
Mima avatar by 絵虎. Pixiv post: https://www.pixiv.net/en/artworks/15431817
-
- Lunatic
- Posts: 463
- Joined: 2019-08-13, 00:30
- Location: Casumia
Re: Proper syntax for URL Rewriter on Wikipedia for article sections
What you offer redirects to the correct page with the proper skin, but for both example links, it is always to its header (as though the hash’s string were stripped away), not the intended section (example result).
Browser: Pale Moon (Pusser’s repository for Debian)
Operating System: Linux Mint Debian Edition 4 (amd64)
※Receiving Debian 10 LTS security upgrades
Hardware: HP Pavilion DV6-7010 (1400 MHz, 6 GB)
Formerly user TheRealMaestro: æsc is the best letter.
Operating System: Linux Mint Debian Edition 4 (amd64)
※Receiving Debian 10 LTS security upgrades
Hardware: HP Pavilion DV6-7010 (1400 MHz, 6 GB)
Formerly user TheRealMaestro: æsc is the best letter.
-
- Keeps coming back
- Posts: 784
- Joined: 2020-11-03, 06:47
- Location: Philippines
Re: Proper syntax for URL Rewriter on Wikipedia for article sections
That's weird, both example links redirect correctly with my wildcard. Are we using the same URL Rewriter? (I'm using the one by papush, versioned at 2.8.4)
merry mimas
XUL add-ons developer. You can find a list of add-ons I manage at http://rw.rs/~job/software.html.
Mima avatar by 絵虎. Pixiv post: https://www.pixiv.net/en/artworks/15431817
-
- Lunatic
- Posts: 463
- Joined: 2019-08-13, 00:30
- Location: Casumia
Re: Proper syntax for URL Rewriter on Wikipedia for article sections
Yes, we are using the same version. I am using the redirect you have given together with the one I had listed at first, for if I do not use mine, then ordinary Wikipedia articles will not redirect as wished. (What you had given works as intended in isolation.) I cannot see how to add more than one exclusion pattern to it, as I think could cure this. Semicolons fail.
Browser: Pale Moon (Pusser’s repository for Debian)
Operating System: Linux Mint Debian Edition 4 (amd64)
※Receiving Debian 10 LTS security upgrades
Hardware: HP Pavilion DV6-7010 (1400 MHz, 6 GB)
Formerly user TheRealMaestro: æsc is the best letter.
Operating System: Linux Mint Debian Edition 4 (amd64)
※Receiving Debian 10 LTS security upgrades
Hardware: HP Pavilion DV6-7010 (1400 MHz, 6 GB)
Formerly user TheRealMaestro: æsc is the best letter.
-
- Keeps coming back
- Posts: 784
- Joined: 2020-11-03, 06:47
- Location: Philippines
Re: Proper syntax for URL Rewriter on Wikipedia for article sections
Ahh, yeah. I didn't consider both rules being used at the same time. Unfortunately I don't know how I could do multiple exclude rules with this extension, sorry.
merry mimas
XUL add-ons developer. You can find a list of add-ons I manage at http://rw.rs/~job/software.html.
Mima avatar by 絵虎. Pixiv post: https://www.pixiv.net/en/artworks/15431817
-
- Astronaut
- Posts: 749
- Joined: 2020-05-31, 04:33
Re: Proper syntax for URL Rewriter on Wikipedia for article sections
I wrote a post awhile back about doing multiple excludes with the pipe symbol, don't know if it would help you in this case: viewtopic.php?p=226322#p226322
-
- Lunatic
- Posts: 463
- Joined: 2019-08-13, 00:30
- Location: Casumia
Re: Proper syntax for URL Rewriter on Wikipedia for article sections
This works! More precisely, changing my initial exclusion pattern to *wikipedia.org/*?useskin=monobook|#* shuts out correctly framed sites, so this, working with Jobb’s pattern, directs all Wikipedia links where I would. This is the second time this thread on WebComponents had helped me. (The other was when I had had problems with the Archive and Fanbox.) I wish that I could mark you both as having solved my problem.
Browser: Pale Moon (Pusser’s repository for Debian)
Operating System: Linux Mint Debian Edition 4 (amd64)
※Receiving Debian 10 LTS security upgrades
Hardware: HP Pavilion DV6-7010 (1400 MHz, 6 GB)
Formerly user TheRealMaestro: æsc is the best letter.
Operating System: Linux Mint Debian Edition 4 (amd64)
※Receiving Debian 10 LTS security upgrades
Hardware: HP Pavilion DV6-7010 (1400 MHz, 6 GB)
Formerly user TheRealMaestro: æsc is the best letter.
-
- Astronaut
- Posts: 749
- Joined: 2020-05-31, 04:33
Re: Proper syntax for URL Rewriter on Wikipedia for article sections
Wow! I use URL Rewriter to redirect all Wikipedia links to the privacy friendly alternative Wikiless.org, and with the change in Wikipedia formatting my Wikiless pages were a big mess. Now I used your solution and edited in Wikiless and everything looks great again!
Include URL */en.wikipedia.org/*#*
Redirect To $1/wikiless.org/$2?useskin=monobook#$3
And wikiless is a mess because (I assume) of what wikipedia changed, so wikiless links are now (mostly) fixed with:
Include URL *wikiless.org/*?lang=en
Redirect To $1wikiless.org/$2?useskin=monobook