That much I finally realised minutes ago. So to developer @Malvineous: Can you look into adding this feature in a future update? (Speaking on behalf of the Miraheze community, whose farm switched from ReplaceText early this year.) --Slgrandson (talk) 13:32, 26 March 2023 (UTC)
Extension talk:MassEditRegex
Sorry for the late response, I don't seem to get notifications of messages here. I'm not actively working on this extension due to time constraints but I am happy to merge patches if anyone else wishes to add this functionality. -- Malvineous (talk) 11:50, 3 October 2023 (UTC)
- I may file a request at WM Phabricator, thus making my début there.
- What's been keeping you busy lately?
(Typing from my Galaxy Tab A.)
--Slgrandson (talk) 12:27, 3 October 2023 (UTC)
when i move a file page then use masseditregex to rename all backlinks to the old name, it looks like it only renames escaped links ([[:file:foo.png]]), but not when it's used as an image ([[file:foo.png]]). is there a setting i can toggle to have it rename non-escaped file links?
Is there any way to edit all pages in the Main namespace, even though those pages don't have a prefix? If not, I think that would be a good addition to the extension.
I have the same question—tried to play around with a regex that would capture all titles but that didn't work.
I found a good solution. Go to Special:AllPages, and just select then copy the list of pages. And paste all that into the list of pages box on MassEditRegex.
Having upgraded from MW 1.35.0 to 1.39.1, and PHP 7.4 to to 8.0.26, this extension no longer works.
Every page returns the error message, unable to open /extensions/MassEditRegex/MassEditRegex.special.php , as requested by /includes/AutoLoader.php
This is a file which isn't included in the extension.
False alarm - a full reinstall of the extension solved the problem. Weird, but something must have broken in the transfer.
Starting with version 1.38.2 "Execute in browser" check works only for "Show preview". If checked and "Execute" is attempted, a popup window opens as usual but no action happens. Running without Execute in browser check works, but it is much slower than in 1.37.2. Execute in browser is useful as it does not suffer from timeouts for big updates (limited by 50 pages at the time only). Detected in version 8.4.1 (bed9fa2) 07:08, 6 July 2022, Environment: MediaWiki 1.38.2, PHP 7.4.30 (fpm-fcgi), MariaDB 10.8.3-MariaDB, ICU 71.1.
I'd like to add something to a certain namespace. Thus I entered "Namespacename:" for the page prefix option. The preview works fine however when trying to actually do the changes I get "Error: The MediaWiki API returned the error code invalidtitle: Bad title "File:"." I am not sure if this is a bug or feature request.
I am encountering this same issue. The Show Preview button shows exactly what I want, with all pages in the namespace getting altered, but attempting to Execute (with "Execute in Browser") results in the "invalidtitle" pop-up. However, running with "execute in browser" unchecked seems to work--it's just that I've got many tens of thousands of articles to affect, so it stops after the first 1000.
In MediaWiki 1.3.1 and above, Extension:Replace Text is included by default and only needs enabled.
Is there any functionality that this extension provides that is not covered by that one?
What do you meant with redundant value? Anyhow it has a different approach and the regex functionality is more versatile.
The extension provides examples for adding content to the very bottom of a page, but not to the top. Thus I fiddled with regexes a bit and found this solution, e.g.:
Detect any first character at the beginning of a page:
→ Search for: /^(.)/
Prepend my content to the char found a the beginning of a page including a line break:
→ Replace with: MyContent\n$1
IDK if you tested this, but working just from regex (since I've never used this extension and it might behave differently than expected), the match fragment /^/
should work, with replacement MyContent\n
.
In my new wiki i want to bulk create sub-categories (to be filled later) and a list of pages that we need with a custom "to-do" template, but i just get a "Edit failed: <Page Name> does not exist" from the tool... can i change this beahavior (and make the tool create pages that don't exist instead of just giving up), or is there a tool that allows me to do that?
No. You could probably have a look at the Extension:DataTransfer for bulk creating pages.
Should i go to the category page (to edit all pages in the old category), and do a text replace?
[[Category: Old Category Name]]
with:
[[Category: New Category Name]]
What about spaces (which get converted to underscore in some cases)?
My rename failed. First i went to the category page https://MyUrl/Category:Delete_Me
, which lists one page called Deleteme
![](http://upload.wikimedia.org/wikipedia/commons/thumb/4/4b/Mass-edit-0.png/220px-Mass-edit-0.png)
Next, i clicked `Edit All`, and got the Mass Edit page with the category pre-loaded.
![](http://upload.wikimedia.org/wikipedia/commons/thumb/2/20/Mass-edit-2.png/220px-Mass-edit-2.png)
So far, so good. Then i enter my desired find-replace text:
find: \[\[Category:Delete Me\]\]
replace: [[Category: New Category Name]]
![](http://upload.wikimedia.org/wikipedia/commons/thumb/c/ca/MassEdit_Text.png/220px-MassEdit_Text.png)
But when i submit, i get an error, saying the page (the page that's in the old category) doesn't exist:
![](http://upload.wikimedia.org/wikipedia/commons/thumb/3/35/MassEdit_Missing_Page.png/220px-MassEdit_Missing_Page.png)