Forum:Red links on imported pages

When I import pages from Wikipedia to Religion Wiki there are often very many red links. Since the wiki software automatically determines whether religion wiki has an article or not and colors the corresponding link red or blue, why couldnt it just automatically make links to pages that dont exist (on religion wiki) redirect to Wikipedia? (As opposed to going to a 'create article' page). Granpa 20:29, June 15, 2010 (UTC)


 * You can either do that or remove the links entirely. You just need to edit the XML before you import (preferably with Notepad++), the standard windows notepad messes up encoding...or if you use linux, any text editor.


 * You just need to search for the links and do a find and replace, either replace them with nothing to remove them entirely.


 * OR


 * For linking them to wikipedia replace ' with [[wikipedia: and ' with |]].


 * -- 20:33, June 15, 2010 (UTC)


 * Yes. I know that I can do it manually but ours is a new wiki and we import very many pages from wikipedia and have few editors. Thats why I was wondering if the software could be made to automatically redirect links to nonexistant pages to wikipedia instead of the usual 'create article' page. Granpa 21:41, June 15, 2010 (UTC)
 * I don't think that's what you want. Red links encourage people to add content to your site.  If you're just going to point everyone to Wikipedia then what's the point of your site? -- 23:29, June 15, 2010 (UTC)


 * On the Software Wiki i've actually found a use for the redlinks. Lots of relevant WP articles (lists and comparisons of software) are stuffed into it's own namespace. For now they just sit there, and the redlinks they generate on Special:WantedPages give us a clue of which articles we should be creating. 23:53, June 15, 2010 (UTC)


 * Religion wiki is for religion articles only. the redlinks are mostly just nonreligious stuff anyway. Granpa 00:33, June 16, 2010 (UTC)


 * (edit conflict)Yes I found stripping out links from imported Wikipedia articles manually a pain, and counter productive as I then found as the wiki grew I was putting back stuff I had striped. As OSE says having red links helps to see what articles (and templates) are needed. I do on a few items use the Wikipedia: link but only for items were the article would be a straight clone long term (never likely to be modified as a non core item) but defines something of possible interest to non expert viewers were a definition is usefull. (But a more distinctive link colour would be better than the rather subtle colour shift currently used IMO)


 * You may also whilst stripping links out add the wikipedia template to imported articles as to tell readers its based on a wikipedia article. (as the edit summary of several i looked at neglected to cite the source but they are clearly from wikipedia, in style and having various wikipedia article management categories listed) I tend to rewrite / Wikiaise articles at the time of import as well as so as not to be a 'mirror site'. All the templates i import have in the edit summary a note as to were they are copied (wikipedia or other wikia or wikimedia sites) from so future editors can go to the source to help fix problems or update them in future with new versions (and credit the original authors). - BulldozerD11 00:42, June 16, 2010 (UTC)

Thanks to Devnull69 at Greasemonkey userscripts there is now a script that will change redlinks into links to wikipedia. The script can be found here: http://userscripts.org/topics/60318 var theBrokenLinks = document.evaluate('//a[contains(@title,"(page does not exist)")]',document.body,null,6,null); for (i=0;i<theBrokenLinks.snapshotLength;i++){ var theMatch = theBrokenLinks.snapshotItem(i).href.match(/\?title=(.*)&action/)[1]; theBrokenLinks.snapshotItem(i).href = 'http://en.wikipedia.org/wiki/'+theMatch;} I have added it to my user javascript page and it works fine. Granpa 19:49, September 20, 2010 (UTC)
 * Does anybody see any reason that I should not put this on our site-wide javascript page? Is there anyway this could interfere with anything? Granpa 20:27, September 20, 2010 (UTC)
 * You really shouldn't redirect people away from your wiki. Make a separate wplink template to link to Wikipedia. -- 20:51, September 20, 2010 (UTC)
 * As I pointed out above, Religion wiki is for religion articles only. the redlinks are mostly just nonreligious stuff anyway. So its either remove the redlinks enirely or redirect them to wikipedia. And  removing them all by hand is totally  impractical. Granpa 21:12, September 20, 2010 (UTC)
 * I guess you won't take no for an answer, so why did you ask? -- 22:16, September 20, 2010 (UTC)
 * I asked whether it would interfere with the software not whether you approved of it on philosophical grounds. Granpa 22:58, September 20, 2010 (UTC)

Here is an example of why it is needed. http://fish.wikia.com/wiki/Octopus Granpa 23:06, September 20, 2010 (UTC)

subscribing


 * Granpa - Thats just an example of (very) lazy copying from wikipedia with no initial clean up of the page to make it suitable for a wiki, as its missing nearly 20 templates, had interwiki links left in initially and was displaying a template with an abusive message in it at the top of the page. Auto linking all red links to Wikipedia would not fix a lot of the problems with that page anyway. Also not every wiki would want/be suitable to link to wikipedia for red links, and what about all the images also missing. - BulldozerD11 00:44, September 21, 2010 (UTC)