I introduced this new hook "TitleMove" in the MW core. I had no option while making the Edit Throttle code. This hook interrupts a Move - crucial for checking against vandals. I was surprised actually that this hook wasnt there already. I think it should be added. Its simple, basically a copy of the hook "ArticleSave"
global $wgUser;
$fname = 'Article::MoveArticle';
wfProfileIn( $fname );
if( !wfRunHooks( 'TitleMove', array( &$this, &$wgUser, &$nt, NULL ) ) ) {
wfDebug( "$fname: TitleMove hook aborted move!\n" );
wfProfileOut( $fname );
return false;
}
(near to the top of "function MoveTo", in Title.php, to be added after:
$pageid = $this->getArticleID();
---------------------------------
Access over 1 million songs - Yahoo! Music Unlimited.
> $wgHooks['ParserBeforeStrip'][] = 'testHook';
>
> You can see what I think that should do, I hope. In reality it does
> nothing at all, all articles are parsed the same way as without the
Sorry, this ended up being an issue with Zend Studio's cludgy workspace
management screwing up remote file locations, that I think was confused
by server-side caching. Sorry to take up the space on the list...
SS
I'm building a searchable index where many of the listings have
letters with diacritical marks (eg tilde, umlaut, etc.). How can I
enter them so that they're seachable as the character *without* the
diacriticals? So, for instance
Ñato
which is
Nato with a tilde over the "N"
I'd like a search on "Nato" to pull up that Ñato.
Is there an easy way?
Thanks.
Tim
Hi,
Maybe I've done something wrong but I haven't got the list of accented
characters when I edit a page: something like what you find at the
bottom of:
http://meta.wikimedia.org/w/index.php?title=Meta:Sandbox&action=edit
Any idea about where I could set it right, or can I steal it from the
mediawiki site and put it on my editpage.php ?
Thanks for any clue.
François
Are there any suggestions on how to host multiple content domains in a
single wiki? Namespaces were my initial approach but the maintenance
overhead of having to monitor and correct page names (to put them in the
right namespace) gets out of control very quickly. The act of creating a
page in a namespace is currently beyond intuition for the average user. Is
there perhaps an easier way to organize (and separate) articles? Something
like a directory tree would suffice. Would Categories be any more practical?
I suspect not.
The reasons I'd like to have all content in a single wiki is to
1. Be able to edit metapages without having to replicate changes across
multiple wikis.
2. Unify all the user profiles so that users don't have to register for each
wiki, if they should choose to participate in more than one, and so that I
don't have to replicate permissions for those users.
So if there is a good, clean way to achieve these points, such as sharing a
database or something, I'd be very
interested to know.
Alright, I figured it out. It's a little bit tricky for non-programmers, so here is a manual:
With MediaWiki 1.8.2 it goes like this:
1. CharInsert has to be downloaded from http://svn.wikimedia.org/viewvc/mediawiki/trunk/extensions/CharInsert/CharI… Make sure not to download THIS CharInsert.php but to download the CharInsert.php FROM there.
2. Put the CharInsert.php in your extension folder or make a new CharInsert folder in your extension folder and put the php in there.
3. Place
require_once("$IP/extensions/CharInsert/CharInsert.php");
or
require_once("$IP/extensions/CharInsert.php");
(depending on where you put it) inside LocalSettings.php
4. The corresponding JavaScript code is needed. Normally it's already there, in /common/wikibits.js
5. Copy http://de.wikipedia.org/w/index.php?title=MediaWiki:Edittools&action=edit into your MediaWiki:Edittools page. Now the chars should already be available on edit pages.
6. Copy http://de.wikipedia.org/w/index.php?title=MediaWiki:Onlyifediting.js&action… into your MediaWiki:Onlyifediting.js page.
7. Copy http://de.wikipedia.org/w/index.php?title=MediaWiki:Monobook.js&action=edit into your MediaWiki:Monobook.js page, maybe not everything, only the very last part concerning Onlyifediting.js. Make sure to get this line right:
src="/w/index.php?title=MediaWiki:Onlyifediting.js&action=raw&ctype=text/javascript&dontcountme=s"
Instead of /w/ use the name of your wiki folder.
8. Now it should show up on edit pages with the JavaScript scroll list. If not, try refresh.
See also here: http://meta.wikimedia.org/wiki/CharInsert
Phoenix
______________________________________________________________________________
"Ein Herz für Kinder" - Ihre Spende hilft! Aktion: www.deutschlandsegelt.de
Unser Dankeschön: Ihr Name auf dem Segel der 1. deutschen America's Cup-Yacht!
I'm somewhat new to mediawiki, hopefully someone can give me advice on
how to best change the way wikitext is parsed. I'd like to add a couple
things, like some [cust]custom BBCode[/cust] my forum users want. From
what I've read of the docs I should use the 'ParserBeforeStrip' hook,
but it doesn't work for me:
function testHook(&$parser, &$text, &$strip_state) {
$text = "HEY! YOU'D NOTICE THIS RIGHT?!";
}
$wgHooks['ParserBeforeStrip'][] = 'testHook';
You can see what I think that should do, I hope. In reality it does
nothing at all, all articles are parsed the same way as without the
hook. Help?
SS
Racking my brains and searching on this, what file will allow me to do this?
Our company requires we warn people that we do not control the exteranl
links and that content maybe questionable etc. They want the warning right
under the line under the title "External links" and above the links
themselves.
Thank you!
File a feature request at Bugzilla (bugzilla.wikimedia.org) if you
think people want this.
----
Gary Kirk
On 11/12/06, Dave Yost <ListMail(a)yost.com> wrote:
> When you preview a page you're editing, it says at the top of the preview:
>
> This is only a preview; changes have not yet been saved!
>
> There should be a Save button right there and/or a link to the bottom
> of the page where the Save button and other stuff are.
> _______________________________________________
> MediaWiki-l mailing list
> MediaWiki-l(a)Wikimedia.org
> http://mail.wikipedia.org/mailman/listinfo/mediawiki-l
>
--
Gary Kirk
When you preview a page you're editing, it says at the top of the preview:
This is only a preview; changes have not yet been saved!
There should be a Save button right there and/or a link to the bottom
of the page where the Save button and other stuff are.