Extension talk:Duplicator

From MediaWiki.org
Jump to navigation Jump to search

Success message links don't work[edit]

I'm finding that when I duplicate a page, although the code is there to create a link to the new page, it isn't actually converted into a link, and so the only way to navigate to the new page is to manually copy its name and change the URL. This is not ideal for non-technical users.

Here's what the success message looks like for me on MW 1.27.1 (no spaces between the brackets because, ironically, they aren't converted into real links):

[ [Page 1] ] was copied to [ [Page 2] ]. 1 { { PLURAL:1|revision was|revisions were } } copied.

  • I have the same problem with MW 1.29 .

[[User:Bmrberlin| Bernd M.]] (talk) 04:58, 26 July 2017 (UTC)

Screenshot request[edit]

It would be handy to see what the history of the duplicated article looks like. Jayvdb 06:08, 28 July 2007 (UTC)

It simply looks like the old history, but with an additional entry at the top stating "Copied from Page" Mike.lifeguard 04:24, 21 March 2008 (UTC)

permissions[edit]

Is it possible to restrict this by permission? Mike.lifeguard 04:22, 21 March 2008 (UTC)

Yes, it uses the duplicate permission.  — Mike.lifeguard | @meta 02:25, 6 October 2008 (UTC)

How to remove the link in the TOOLBOX ?[edit]

How to remove the link in the TOOLBOX ? almaghi 15:44, 28 September 2009 (UTC)

Should there be a parameter to disable :
/**
 * Extension setup function
 */
function efDuplicator() {
    global $wgHooks;
    $wgHooks['SkinTemplateBuildNavUrlsNav_urlsAfterPermalink'][] = 'efDuplicatorNavigation';
    $wgHooks['MonoBookTemplateToolboxEnd'][] = 'efDuplicatorToolbox';
}

Adding a Copy or Duplicate link to the article top options (where watch, delete, edit are)[edit]

I know its possible and i've tinkered around trying to do this but I can only get a link that points to the root URL of my wiki. It needs to be appended with Special:Duplicate/<Pagename> so that the duplicate form has the source field pre-populated... Can anyone suggest how to add the additional link cleanly... I have been editing the Duplicate.php by adding in a new class CopyAction invoked at the end with CopyAction::init();

just really struggling to assemble the href destination in php (i'm newish to php!)

update... Ok... made the optionbar addition... thanks to some forum posting i eventjually tracked down...

next issue... can the extension be tweaked slightly to allow for optional copy of the document version history... e.g. take a snapshot of just the latest version ! — Preceding unsigned comment added by Robski~mediawikiwiki (talkcontribs) 16:28, 12 January 2010‎ (UTC)

extension to the editor[edit]

I'm the maker of the GoogleTranslate extension. I thus wonder if we could make this extension cooperate with the Template:Language and the my translator.

Roughly this would look like:

  • A new special edit button to the editor
  • Button checks for existing page in the (pre)selected languages.
  • Creates the page and adds the "Template:Language" to both the pages....
  • In case the page does not exist in the specified languages it should be created....
  • * suggest page names etc.??

Further, maybe the duplication could then be made to handle a range of pages. That is I have about 400 pages(!!), that I would like to "process" in this way....

Thus the advanced version of this would possibly make a "temporary translated version" as a sub-page to the to-be final language specific page. This page can the be promoted to be the final page, when someone has made the review edit. — Preceding unsigned comment added by 87.59.237.40 (talkcontribs) 18:41, 25 June 2010‎ (UTC)

Warning when duplicating an article[edit]

I just got a warning, when I tried to duplicate an article and its talk page:

Strict Standards: Only variables should be passed by reference in [...]Duplicator.page.php on line 105

Both pages were duplicated just as expected. No problems there, but this warning was printed twice, before the actual content of the page was (including the opening html-element)

Before any problems occur because some lines are added or removed from the code and the line number does not fit anymore, here is line 105 in the Duplicator.page.php I am using:

if( $this->duplicate( $this->sourceTitle->getTalkPage(), $this->destTitle->getTalkPage() ) ) {

It is in the function execute.

I am running MediaWiki 1.17.0 with PHP 5.3.5 (apache2handler) and Duplicator 1.2.

Again this is nothing serious, the extension itself works just as expected. I just wanted to let you know about it. --Frog23 14:29, 5 October 2011 (UTC)

German mediawiki Version 1.22.6[edit]

The extension does not copy the exact content of a page. Instead it puts the __DISAMBIG__ in. That makes the extension kind of useless, because you have to copy the content again. Example: http://rockinberlin.de/index.php?title=Test2 Any hints, how to prevent his? --[[User:Bmrberlin| Bernd M.]] (talk) 10:57, 9 April 2015 (UTC)

Could this extension be made ready for usage on Wikimedia wikis?[edit]

This extension is mentioned as a possible solution to phab:T120783 ("Allow copy of pages"), a Community Wishlist item.

I see an old comment from 2007 (phab:T10833#127614) that raises concerns about "history duplication without any of the linking metadata that would make it manageable."

I'm wondering if those issues might have been addressed at all, in later versions of this extension?

Is anyone actively working on this extension, currently?

Thanks! Quiddity (WMF) (talk) 20:09, 9 September 2016 (UTC)

Gives a warning on on MW 1.29.1[edit]

Gives a warning on on MW 1.29.1, Warning: Parameter 1 to efDuplicatorToolbox() expected to be a reference, value given in ...\wiki\includes\Hooks.php on line 186 --Rob Kam (talk) 23:16, 12 September 2017 (UTC)

I suggest to create a task on Phabricator for this if this is still the case for 1.31.x. Cheers --[[kgh]] (talk) 09:41, 13 March 2019 (UTC)

Duplicated pages don't show up as Recent changes[edit]

It's the simplest extensions that are the best. I love this extension. I just upgraded to the master version of this extension in my MW-1.28.2 private enterprise site to get the fix where, after duplicating the pages, it provides working links to both the source and destination pages. W00t! .. The only thing missing through is that duplicated pages don't show up in the "Special:RecentChanges" pages. Is that an easy fix for the owner of this extension? Hope so. --- User:revansx

I suggest to create a task on Phabricator for this. Cheers --[[kgh]] (talk) 09:41, 13 March 2019 (UTC)

duplicated pages have the "created by" property of the source page[edit]

when visiting the history of a duplicated page, the page creator (and first edit) is listed as the creator/author of the page that was duplicated rather than the user who performed the duplication. Is this the intended behavior?

This is a problem for me when also using Extension: categorywatch in that when duplicating a page that is in a watched category, notification get sent out on behalf of the creator of the original page, rather than the user who did the duplication as would be expected. Revansx (talk) 21:38, 30 January 2019 (UTC)

I suggest to create a task on Phabricator for this. Cheers --[[kgh]] (talk) 09:40, 13 March 2019 (UTC)

Issues with MediaWiki 1.32[edit]

All, has anyone else had issues with Duplicator and MediaWiki 1.32? I recently tried to duplicate a page and got an Internal Error with a traceback that can be seen here: https://www.mediawiki.org/wiki/Topic:Uvk534c3g65obfzp

Indeed as far as the wikiapiary says, I might be the first Mediawiki 1.32 site to try Duplicator?

Please let us know what becomes of this. I'm eager to upgrade my mw1.30 site to 1.32 and Duplicator is a big part of how my users use my site. Revansx (talk) 22:00, 12 March 2019 (UTC)


Yes, had issues also on 1.32, created a right mess, as the duplicated page was there, but didn't seem to exist in the DB, had to force delete the failed duplication to tidy up.

Just re-tested now to remind myself, got the following when doing the duplication - "Internal error - [XIjMhF@T27P4Hc-2jIsVpQAAAA8] 2019-03-13 09:25:25: Fatal exception of type "MediaWiki\Revision\RevisionAccessException""

When trying to visit the duplicated (failed) page, VisualEditor says "Error loading data from server: latestnotfound: Could not find latest revision for title. Would you like to retry?"

Source edit says "The revision #0 of the page named "TOPL Test" does not exist. This is usually caused by following an outdated history link to a page that has been deleted. Details can be found in the deletion log." --Freekycheese (talk) 09:37, 13 March 2019 (UTC)

Tracked with task T218096 --[[kgh]] (talk) 09:39, 13 March 2019 (UTC)