What is meta? ×
Meta Stack Exchange is where users like you discuss bugs, features, and support issues that affect the software powering all 133 Stack Exchange communities.

The Request

I set out on the Crusade for the Holy Grail of no-redirections (named by Denilson Sá) to eliminate every shortened URL on Stack Overflow. But the foreign hordes are overwhelming me, and I need reinforcements!

The Mission

Find every shortened URL, follow it, check it and inline the unshortened/long version into the post, like this:

For details see the documentation here: http://tinyurl.com/3zbelpa

Turns into:

See the documentation for further details.

Watch out for hidden LMGTFY links and flag them for Moderator Attention if the answer only consists of those. If the answer does also hold valuable information like other links or further information, edit the LMGTFY-Link out, and leave the above link for future reference.

If you encounter links to duplicates, vote to close/flag the question, and edit the answer anyway.

But, watch out for traps! As Joel Coehoorn♦ informed me, there are edge-cases which need the existence of shortened URLs. Including but not limited to:

  • Certain Wikipedia-Links
  • Archive.org Wayback-Machine
  • Browsershots.org
  • Google Books

Make sure that you're not breaking any of these by inlining them.

If you find shortened URLs in comments, there's at the moment not much we can do about them. LMGTFY and other objectionable content needs to be cleansed flagged none the less.

Also there are shortened URLs hiding in the woods (known to some as "Code"), these are no danger to our lands and can therefore be left unchecked and unchallenged.

The Tools

Our most valuable light in the darkness of the night is the search (roughly sorted by number of hits, cleaned ones at the bottom (doesn't mean that they don't come back)):

Feel free to expand and edit that list.

While paying a visit, Rob Hruska showed us the way to a magician which allows us to see beyond shortened URLs without fear for ourselves. Jeff Mercado also showed as an apparatus which does the same. These are only tools on our crusade to protect and help ourselves, we need to cleanse the land from redirections nonetheless.

The Reward

Eternal honor and glory...and of course you can keep every captured Flag-Weight and Badge.

share|improve this question

closed as off-topic by Al E., rene, Martijn Pieters, Undo, Shadow Wizard Jun 29 at 22:15

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "This question pertains only to a specific site in the Stack Exchange Network. Questions on Meta Stack Exchange should pertain to our network or software that drives it as a whole, within the guidelines defined in the help center. You should ask this question on the meta site where your concern originated." – Al E., rene, Martijn Pieters, Undo, Shadow Wizard
If this question can be reworded to fit the rules in the help center, please edit the question.

14  
3  
Here's another site that can expand the links for us for many different sites: longurl.org –  Jeff Mercado Jul 20 '11 at 20:32
15  
While fixing these, please don't just put a "+" after the shortened link to go to the shortener preview page; inline the full site URL. –  Rob Hruska Jul 20 '11 at 21:12
2  
`@Bobby and @Rob: Sorry, that was probably me. I didn't realize my mistake until I had already "fixed" about a dozen posts. –  Chris Frederick Jul 20 '11 at 21:28
1  
@Chris - NP, I think I got most of them. –  Rob Hruska Jul 20 '11 at 21:29
5  
That explains the edit queue number. I've never seen it that high before. –  mmyers Jul 20 '11 at 22:24
7  
Reminder: funky Wikipedia links and links that include URLs in the querystring will usually be properly encoded if copied out of the Firefox or Chrome address bar. IE users can continue to sell their souls to URL shorteners, or get a real browser. –  Shog9 Jul 20 '11 at 22:33
2  
I guess we should extend this quest to other sites from the stackexchange family! –  Denilson Sá Jul 20 '11 at 22:58
2  
Some time ago we looked at http status codes for a sample of the links found in stackoverflow posts - over 10% returned 301. –  martin clayton Jul 20 '11 at 22:59
2  
This question title delivers the lulz. When you need a break, take a moment to enjoy everything that live.lmgtfy.com has to offer. –  Brad Mace Jul 21 '11 at 6:38
1  
We need some way to educate our users. I've seen the hit count for some URL shorteners go up from yesterday! –  Denilson Sá Jul 21 '11 at 17:04
1  
5  
As a part of this effort, could a dev remove the shortened url from the post-ban message please? –  M. Tibbits Jul 27 '11 at 18:46
1  
What do we have to do when Jon Skeet post a tinyurl? stackoverflow.com/questions/4344336/… –  Cyril Gandon Aug 11 '11 at 15:09
2  
@Nightfirecat: Despite the ensnaring thought, do not engage into edit-wars of any kind. If somebody rolls back these changes, only roll back once and leave a comment with further explanations. If the user rolls back again, flag for Mod Attention. Though, my heart bleeds if I think about bothering the mods with such peanuts, it's better then to engage into a vendetta with a user. Don't forget, we have the blessings of the Diamonds with us. –  Time Traveling Bobby Nov 7 '11 at 7:50

11 Answers 11

You'll likely get better search results for posts entered prior to the last data dump via SEDE. And add a search for http://tr.im/ — It's defunct now but was still active when Stack Overflow first launched.

Aside from that, we've had this discussion before (can't find the link right now) and from that I'll caution that there are a few edge cases where the shortened urls are required. Examples includes links into archive.org's wayback machine, browsershots.org, and certain wikipedia links (though I think the last has since been fixed).

share|improve this answer
    
Good points about the links, I'll add that. –  Time Traveling Bobby Jul 20 '11 at 19:05
    
I'm quite interested to see that previous discussion. I can't imagine why you would need obfuscated URLs for links to the Wayback Machine to work. The regular links work just fine for me across sessions, and as I understand it, the obfuscation services just store that same URL to be expanded later. –  Cody Gray Jul 21 '11 at 4:09
1  
@Cody - the issue is that you have to include the full url for the original page as a query string parameter for the wayback machine, and the regex kept choking on the second http:// . A quick check shows they've made improvements since then, but I'd still be wary of edge cases. –  Joel Coehoorn Jul 21 '11 at 4:32
    
Since tr.im is now defunct, how can we "fix" those links? Or... We can't?! –  Denilson Sá Jul 21 '11 at 16:54
1  
@Denilson - In many cases, we'll be able either infer where they were pointing or run a google search to find an equivalent link. In others, we may just need to flag the post for moderator deletion or edit that part of post out. –  Joel Coehoorn Jul 21 '11 at 17:18

That's great, but we also need some way to remove URL shorteners from the comments.

During this quest of the Holy Grail of no-redirections, I've found many short URLs in the comments, and it makes me sad that I can't do anything to fix those.

share|improve this answer
    
Awesome title! I have to get this somewhere into my question! And you're right...we can flag LMGTFY-Comments, but can't really do anything about the others, I fear. We'll see, maybe a Mod comes along with a good idea. –  Time Traveling Bobby Jul 20 '11 at 20:40
    
Eh,.... LMGTFY? –  GUI Junkie Jul 20 '11 at 22:16
24  
@GUI Junkie, what? You don't know LMGTFY? lmgtfy.com/?q=LMGTFY :-) (Okay, I admit, this was kinda mean…) –  Denilson Sá Jul 20 '11 at 22:18
    
I'm smiling now –  GUI Junkie Jul 20 '11 at 22:24
    
I thought there would be viagra somewhere for me –  GUI Junkie Jul 20 '11 at 22:32
2  
Yep. Go ahead and flag them in comments, and a mod can edit the comment. LMGTFY comments can be flagged for removal. –  nhinkle Jul 20 '11 at 23:20
8  
So far the only legitimate use for a url shortener that I know of is the one Jon Skeet uses when hinting to question askers that they should improve their question. It even has a much friendlier name. tinyurl.com/so-hints vs msmvps.com/blogs/jon_skeet/archive/2010/08/29/…, I'd prefer the shortened version as long as I know it's safe and has a friendlier name than a random hash. –  Jeff Mercado Jul 21 '11 at 0:41
    
@Jeff - and so as not to take up too much of a comment when including long links or multiple links. –  tvanfosson Jul 25 '11 at 15:44

Maybe somewhat less used, but CloudApp has a URL-shortener called cl.ly.

share|improve this answer
    
You just hit a pot of gold! 232 hits on SO. Thank you very much! –  Time Traveling Bobby Jul 20 '11 at 21:57
2  
Huh... Most times I find a cl.ly link, it's actually for image hosting. Thus, I don't believe those image-hosting links should be removed. –  Denilson Sá Jul 20 '11 at 23:20

I wasn't aware that shortened URLs were considered poor form. Personally, I always use full URLs in questions and answers, but often use shortened URLs in comments due to the character limit.

If SO policy is to eliminate shortened URLs, then we should:

  • Tell people. I don't know if SO has a mechanism for making announcements, but there should at least be a mention of this in the FAQ.
  • Stop counting URLs against the character limit in comments.
  • Filter new questions, answers, and comments to catch shortened URLs.

Before embarking on this crusade, however, I'd want to know if shortened URLs are really a problem on SO. I understand the theoretical security risk, but in practice how often does it happen that someone posts a shortened URL on SO that points to something other than what's represented? I'd expect those cases to be pretty rare, and I'd hope that such posts would be downvoted into oblivion.

share|improve this answer
13  
Point 1: a short URL that points to another question in StackOveflow won't show up in "Linked" list of questions at the right side. Point 2: it is better for the user experience to know the destination of a link. Sometimes I decide if I should follow or not a link based on the URL itself. Point 3: Shorteners don't improve the user experience in any way. Actually, as I said, they degrade the experience. Point 4: Shorteners are usually used by new users that still don't know how to correctly insert links. –  Denilson Sá Jul 20 '11 at 22:48
1  
1: Fair enough, but links to other SO questions aren't terribly long anyway -- I'm not sure I'd bother shortening such a link. Links to documentation on other sites (very common in SO comments) can be quite long and shortening them helps in comments. 2: I agree, but on the other hand it's better for the user experience if I can use as many characters as I need to in order to explain something. 3: See 2. 4: Rather than banning shortened links, then, perhaps we should help the new users? I'm not arguing for more shortened URLs, just not convinced that eliminating them is useful. –  Caleb Jul 20 '11 at 22:59
3  
Side note: there is a short form for links to SE posts: site.stackexchange.com/q/postID, e.g. meta.stackexchange.com/q/99164 for this one. –  nhinkle Jul 20 '11 at 23:26
10  
@Denilson - you forgot the big one: Point 5: link rot - if/when the shortening service goes belly up (eg. tr.im), then all those links become dead & the question/answer/comment they're used in becomes, at least partially, useless. –  Alconja Jul 21 '11 at 3:52
9  
They're poor form everywhere. I'm not going to click links that I don't know where they point. That's just irresponsible. –  Cody Gray Jul 21 '11 at 4:07
    
@Alconja: True, but that also happens on non-redirected links. Anyway, the lesser is the number of redirections, the lower is the probability of link rot. –  Denilson Sá Jul 21 '11 at 4:17
2  
@Cody - they're not poor form on Twitter, they're absolutely essential when you're character limited. Granted, comments are as limited as tweets, but long urls can seriously cut into your comment space, esp. if you include multiple links (such as to ref. docs). –  tvanfosson Jul 25 '11 at 15:46
1  
@tvanfosson: I don't think Stack Exchange has bought Twitter yet. Can't wait, though; it'd really help that site out to redirect the focus on content rather than noise. –  Cody Gray Jul 25 '11 at 15:49
3  
"Shorteners don't improve the user experience in any way" I'd disagree with this point at least. IBM has hundreds of SupportPacs all with 4-char names. If you know that they live at bit.ly/SupportPacs and that SupportPac XXXX is at bit.ly/SupportPacXXXX then you can get to them from any browser without resorting to search. I can see why they were expanded but I'm hoping that if can transfer these form bit.ly to IBM's URL shortener that I can restore the mnemonic links in my answers. –  T.Rob Jul 28 '11 at 0:43

I admire the zeal of the quest and would bang my head through a rock before ever adding a short.url. However, would it not be possible for the asker to propose a more automated approach? It would surely be a flick of the wrist for the SE programmers (Superero without H) to replace that for a 'click here'?

And let me please finish with... amiright?

Edit As George comments, the approach would be to do that on the fly.

share|improve this answer
3  
Better yet, have the system check the answer for shortened URLs before the answer is posted. –  uɐɯsO uɐɥʇɐN Jul 20 '11 at 23:14
1  
Actually, as the original question proposed, not only we are replacing the short URLs, but are also adding relevant link texts. Oh, and from what I saw, there are so many different cases that an automated approach would be a pain to write, and would still fail a lot. –  Denilson Sá Jul 20 '11 at 23:23
    
I was getting at what George is suggesting, but alas, brevity is always mine enemy. –  GUI Junkie Jul 21 '11 at 5:45
    
@Denilson, it may not be trivial. But a link has either a text that can be respected o a link that can be replaced with a 'click here' textlink. The end result might not be so nice as a manual edit, but would be workable. –  GUI Junkie Jul 21 '11 at 6:42

Another nefarious purpose for shortened URLs: hiding amazon.com affiliate tags. (Other affiliate tags as well, presumably.)

I just fixed one of those. I'll not be surprised to find others.

share|improve this answer

Please remember, don't bother with posts that only contain a link. If there is no context around that link (if the link breaks, is the answer still useful?) .. flag the post as a non-answer.

I just deleted a few non-answers that had been edited to expand the actual URL, I hate to see people waste time :)

share|improve this answer
    
Go ahead and edit the link anyway, if you have edit permissions - no point in the link staying in that form for any amount of time regardless. –  Nightfirecat Nov 4 '11 at 21:24

It has been brought to my attention that you can search for links using the url: option. I don't know precisely how smart this functionality is, but it does seem to ignore links embedded in code. We might be able to leverage this functionality to automatically detect shortened URLs before they are ever posted.

share|improve this answer

Thanks to the people who are going through the database and fixing posts. But please don't blindly replace URLs by the longer URLs, take the time to go through the posts review them.

  • Do not replace shortened URLs if they are part of the question. Example: Split Twitter RSS string using Python — the question is asking how to parse a string that happens to contain a short URL; replacing it by the longer URL would not make any sense.
  • If the URL was directly in the text (and was intended as a link, not as part of the question as above), don't leave [http://bit.ly/abcde](http://real-url.example.com/wibble) in the markdown, take the time to write a real description for the link, like [the description of the `wibble` command in the official documentation](http://real-url.example.com/wibble).
  • If the URL is to an image, upload it to Stack Exchange's image hosting (press Ctrl+G, click on from the web and enter the URL image).
  • If you see other problems in the post, such as a signature or spelling errors, take the opportunity to improve the post.
share|improve this answer

I was just now haunted by an unearthly creature in the form of: "http://kjkh.me/oXek9p". It crept out of this dungeon. In my bewilderment I turn to the noble crusadors of LMFTFY for council. What is the righteous path for for a lowly peasant?
Downvote? Comment? Friendly advice? Refer to this page?

share|improve this answer
2  
Edit it to link to the actual page. I just did. Downvote, comment, friendly advice optional. –  Jeff Mercado Oct 4 '11 at 1:27

Not the answer you're looking for? Browse other questions tagged .