I would like to add a prefix to the title of many pages, in order to move them to a new namespace. the pages are all in the same category so in principle the replace text extension would be the tool. however, since replace text extension does not support regular expressions (I need to match the start of the title and replace it with the prefix) ...
any help/solutions are very much appreciated!
tomy
-- sent from nil
following up on my own question: do this using semantic inline queries as follows.
to move all pages in the category "collaborator" into the namespace "collaborator" use the maintance script moveBatch:
php moveBatch.php -u tag -r new-namespace -i 1 collMoveList.txt
for which one may generate the collMoveList with the following semantic query:
{{#ask:[[Category:Collaborator]] |?mainlabel |?#= |format=template |template=formatMovePages |limit=5000}}
the template:formatMovePages looks like this
{{{1}}}|Collaborator:{{{1}}}<br>
cheers tomy
Thomas Alexander Gerds tag@biostat.ku.dk writes:
I would like to add a prefix to the title of many pages, in order to move them to a new namespace. the pages are all in the same category so in principle the replace text extension would be the tool. however, since replace text extension does not support regular expressions (I need to match the start of the title and replace it with the prefix) ...
any help/solutions are very much appreciated!
tomy
-- sent from nil
mediawiki-l@lists.wikimedia.org