Hi all,
Sharing of URLs of non latin wiki's werent really easy and when copy pasting we get the unicode numerals in the URL like http://ta.wikipedia.org/wiki/%E0%AE%B5%E0%AE%BF%E0%AE%95%E0%AF%8D%E0%AE%95%E...
en:User:Mountain had come up with a shortify project[1] and thanks to Yuvipanda its now live on Tamil Wikipedia. All pages have a link on the right side of article title. http://tawp.in/r/262 is the same link and is being displayed there. The feedback from the community is to have this hosted by Wikimedia itself as it would be more reliable than individual running it. So there came the idea of a mediawiki extension and hence Shorturl extension[2] was born by some really quick work by Yuvipanda.Its live here[3].(See the toolbox for short URL) While this may be a small thing, it does help non latin wiki's a lot.Having it in the extension form is more reliable even though the URL length goes up, but still its worthy.The URL length can be shortened with mod_rewrite rules on. I would ideally like this to be used across non latin wikimedia properties as it helps these projects(like echoed here[4]). Please let me know how to do this. Bugs on wikimedia bugzilla will do?
Feedback appreciated.
[1] https://github.com/mountain/shortify [2] http://www.mediawiki.org/wiki/Extension:ShortUrl [3] http://wiki.busroutes.in/wiki/Chennai [4] http://lists.wikimedia.org/pipermail/wikimediaindia-l/2011-March/002699.html http://lists.wikimedia.org/pipermail/wikimediaindia-l/2011-March/002699.html Regards Srikanth.L
Srikanth Lakshmanan wrote:
Hi all,
Sharing of URLs of non latin wiki's werent really easy and when copy pasting we get the unicode numerals in the URL like http://ta.wikipedia.org/wiki/%E0%AE%B5%E0%AE%BF%E0%AE%95%E0%AF%8D%E0%AE%95%E...
...
So there came the idea of a mediawiki extension and hence Shorturl extension[2] was born by some really quick work by Yuvipanda
...
[1] https://github.com/mountain/shortify [2] http://www.mediawiki.org/wiki/Extension:ShortUrl [3] http://wiki.busroutes.in/wiki/Chennai [4] http://lists.wikimedia.org/pipermail/wikimediaindia-l/2011-March/002699.html <http://lists.wikimedia.org/pipermail/wikimediaindia-l/2011-March/002699.html
Regards Srikanth.L
Looks good, although I'm not sure what the advantage in this case is over using a page id. Both have the same disadvantage: * They are binding to a pageid instead of a pagename.
This means whenever the page is (un)deleted, moved, merged, split, or becomes a redirect. The link is longer correct.
I saw a different short-url service for en.wikipedia which also uses numbers, but internally converts to a page title.
In order words:
* http://en.wikipedia.org/wiki/Talk:Foobar = > (pageid: 12, namespace: 1, title:Foobar) converted to 1 * shorturl/1 = > namespace:1, title:Foobar -> en.wikipedia.org/wiki/ Talk:Foobar
This will always stay the same.
* en.wikipedia.org/wiki/Talk:Foobar = > pageid: 12 converted to base64 * (page is re-created, moved, split, merged, whatever) * shorturl/base64 => pageid: 12 => unknown page id, or perhaps http://en.wikipedia.org/wiki/A_different_page
If the extension does not use the title, but the pageid, we might as well really use the pageid:
* http://ta.wikipedia.org/?curid=2810 (already works) * http://ta.wikipedia.org/wiki/Special:ShortUrl/262 (proposal; // base_convert ( 2810, 10, 36 ); )
Even shorter :-)
-- Krinkle
On Tue, Apr 12, 2011 at 8:55 PM, Krinkle krinklemail@gmail.com wrote:
- http://ta.wikipedia.org/?curid=2810 (already works)
- http://ta.wikipedia.org/wiki/Special:ShortUrl/262 (proposal; //
base_convert ( 2810, 10, 36 ); )
I think "permalink" is the common used term for this kind of url. So Special:Permalink/262.
On Tue, Apr 12, 2011 at 9:32 PM, Bryan Tong Minh bryan.tongminh@gmail.com wrote:
On Tue, Apr 12, 2011 at 8:55 PM, Krinkle krinklemail@gmail.com wrote:
- http://ta.wikipedia.org/?curid=2810 (already works)
- http://ta.wikipedia.org/wiki/Special:ShortUrl/262 (proposal; //
base_convert ( 2810, 10, 36 ); )
I think "permalink" is the common used term for this kind of url. So Special:Permalink/262.
In fact it already exists in 1.18 as of r79036
http://www.mediawiki.org/w/index.php?title=Special:Code/MediaWiki/79036
Op 12 apr 2011, om 21:35 heeft Bryan Tong Minh het volgende geschreven:
On Tue, Apr 12, 2011 at 9:32 PM, Bryan Tong Minh bryan.tongminh@gmail.com wrote:
On Tue, Apr 12, 2011 at 8:55 PM, Krinkle krinklemail@gmail.com wrote:
- http://ta.wikipedia.org/?curid=2810 (already works)
- http://ta.wikipedia.org/wiki/Special:ShortUrl/262 (proposal; //
base_convert ( 2810, 10, 36 ); )
I think "permalink" is the common used term for this kind of url. So Special:Permalink/262.
Well, permalink is a permanent link to a certain revision (oldid) And has been in de sidebar for a while now and a specialpage-redirect has been implemented in 1.18.
However a permanent link to a revision or a short link to the current page are two very different things.
Short-url intends to make a link to [[Article name]] available in a shortform, especially useful for non-latin article names.
Permanent-url intends to make the same content available under a permanent location, the fact that the url (can [1]) be shorter is a side-effect.
If a page is modified (new revision), the permalink will be outdated. ...if a page recreated the permanent will no longer work at all.
So summarized: * Imho a ShortUrl-specialpage extension is redundant as the few characters saved with base64 instead of the page-id (not revision id) directly is not much and only introduced a new number/variable into the mix of things to keep track of * Short page-id links already exist by using /?curid=<pageid> * Pageid is not a reliable way to link to an "article" of a certain subject.
-- Krinkle
On Tue, Apr 12, 2011 at 10:01 PM, Krinkle krinklemail@gmail.com wrote:
Op 12 apr 2011, om 21:35 heeft Bryan Tong Minh het volgende geschreven:
On Tue, Apr 12, 2011 at 9:32 PM, Bryan Tong Minh bryan.tongminh@gmail.com wrote:
On Tue, Apr 12, 2011 at 8:55 PM, Krinkle krinklemail@gmail.com wrote:
- http://ta.wikipedia.org/?curid=2810 (already works)
- http://ta.wikipedia.org/wiki/Special:ShortUrl/262 (proposal; //
base_convert ( 2810, 10, 36 ); )
I think "permalink" is the common used term for this kind of url. So Special:Permalink/262.
Well, permalink is a permanent link to a certain revision (oldid) And has been in de sidebar for a while now and a specialpage-redirect has been implemented in 1.18.
However a permanent link to a revision or a short link to the current page are two very different things.
Oh right, I always get confused between "curid" and "oldid".
This is just another instance of https://bugzilla.wikimedia.org/show_bug.cgi?id=21572
Note that there's javascript there for creating curid links, too.
Note those urls may have caching problems.
-1 to the base36 thing.
2011/4/12 Krinkle krinklemail@gmail.com:
Looks good, although I'm not sure what the advantage in this case is over using a page id. Both have the same disadvantage:
- They are binding to a pageid instead of a pagename.
Actually just recently i thought of a different idea. It looks like the Interlanguage extension is finally in the beginning of its way to being rolled out (see https://bugzilla.wikimedia.org/15607 ). Maybe this extension can be modified so that typing something like http://mul.wikipedia.org/wiki/Barack_Obama:ar will redirect to http://ar.wikipedia.org/wiki/%D8%A8%D8%A7%D8%B1%D8%A7%D9%83_%D8%A3%D9%88%D8%.... It wont make the name very short, but it will certainly be better than http://ar.wikipedia.org/wiki/%D8%A8%D8%A7%D8%B1%D8%A7%D9%83_%D8%A3%D9%88%D8%... for sending by email or instant messaging.
The advantage is that it will work for any language. The interlanguage wiki may have the names limited only to characters which don't have to undergo URL-encoding; this doesn't necessarily mean "English".
("mul" is the ISO 639 code for "multiple languages". There was no decision to give the future Interlanguage wiki this name; i just made it up. The domain can have any other name.)
-- Amir Elisha Aharoni · אָמִיר אֱלִישָׁע אַהֲרוֹנִי http://aharoni.wordpress.com "We're living in pieces, I want to live in peace." - T. Moore
Srikanth Lakshmanan srik.lak@gmail.com writes:
I would ideally like this to be used across non latin wikimedia properties as it helps these projects. Please let me know how to do this. Bugs on wikimedia bugzilla will do?
First, extensions that are deployed should be in subversion. Get commit access if you don't already have it and put it in SVN: http://www.mediawiki.org/wiki/Commit_access
This gets the ball rolling. The extension will need to be translated on Translatewiki before it can be deployed anywhere and putting it in SVN with the proper i18n files and such will make that happen almost automatically (http://www.mediawiki.org/wiki/Localisation).
You'll likely start to get reviews at this point for code style. You can get a jump on those by reading over http://www.mediawiki.org/wiki/Manual:Coding_conventions and starting to get your code in shape.
Next you should try to get two or more reviews by trusted developers. They will help you find any thing that doesn't have a chance of making it past the next step. Find a couple of people to look over your code and point out any flaws in it. Make sure they know you're trying to follow this guide. If they know you're trying to get your code deployed, they'll look for things that would block deployment or alternatives to deployment that you might not be aware of.
They may also point you to another extension that is already in use whose functionality duplicates what you want, or could be easily extended to do what you want. In that case, you should use your newly-acquired SVN access to work on the extension that is already in use.
Finally, anything that is deployed on the Wikimedia cluster needs to be reviewed by Tim Starling for security and scalability issues. He has written written a page on this on MediaWiki that you should read and use before getting this far: http://www.mediawiki.org/wiki/Security_for_developers
Any issues that Tim identifies *must* be addressed before anyone can deploy your code on the cluster. If you've followed the advice of earlier reviewers closely, you probably won't have too much of a problem here. Tim takes his job very seriously, though, so he may well spot a show-stopper that eluded your earlier reviewers.
Finally, you need to file a bug in Bugzilla to have it deployed. The bug will need several things:
* The “shell” keyword so that people with shell access can find the request. * The bug should point to on-wiki community consensus for having the extension installed on a particular wiki. No extension is deployed across all “non Latin Wikimedia properties” without first getting consensus from the individual wiki. * Finally, an extension that hasn't been deployed yet should acknowledge that fact and point to Tim Starling's approval for deployment.
Getting something deployed is not an easy task, but if you can meet the challenge, you know you've done something that not many people are capable of.
(I've written the above up on MediaWiki, too: http://www.mediawiki.org/wiki/Writing_an_extension_for_deployment)
Good Luck!
Mark.
* Srikanth Lakshmanan srik.lak@gmail.com [Tue, 12 Apr 2011 22:29:33 +0530]:
Hi all,
Sharing of URLs of non latin wiki's werent really easy and when copy pasting we get the unicode numerals in the URL like
http://ta.wikipedia.org/wiki/%E0%AE%B5%E0%AE%BF%E0%AE%95%E0%AF%8D%E0%AE%95%E...
en:User:Mountain had come up with a shortify project[1] and thanks to Yuvipanda its now live on Tamil Wikipedia. All pages have a link on
the
right side of article title. http://tawp.in/r/262 is the same link and is being displayed there. The feedback from the community is to have this hosted by Wikimedia itself as it would be more reliable than
individual
running it. So there came the idea of a mediawiki extension and hence Shorturl extension[2] was born by some really quick work by Yuvipanda.Its live here[3].(See the toolbox for short URL) While this may be a small thing, it does help non latin wiki's a lot.Having it in the extension form is more reliable even though the URL length goes up, but still its worthy.The URL length can be shortened with mod_rewrite rules on. I would ideally like this to be used across non latin wikimedia properties as
it
helps these projects(like echoed here[4]). Please let me know how to
do
this. Bugs on wikimedia bugzilla will do?
Feedback appreciated.
I wish the numerous http and mail clients as well as web engines were able to display such links "urldecoded", like Firefox does. I've made such patch for MediaWiki https://bugzilla.wikimedia.org/show_bug.cgi?id=25934 However, phpbb didn't decode such links, IE6/7/8 not as well :-( A lots of software and web engines probably has to be updated to recognize the utf-8 URI's. Dmitriy
wikitech-l@lists.wikimedia.org