Code Monkey home page Code Monkey logo

dokuwiki-plugin-move's Introduction

move Plugin for DokuWiki

Move and rename pages and media files while maintaining the links.

All documentation for this plugin can be found at
http://www.dokuwiki.org/plugin:move

If you install this plugin manually, make sure it is installed in
lib/plugins/move/ - if the folder is called different it
will not work!

Please refer to http://www.dokuwiki.org/plugins for additional info
on how to install plugins in DokuWiki.

----
Copyright (C) Michael Hamann <[email protected]>,
              Andreas Gohr <[email protected]>,
              and others

This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; version 2 of the License

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

See the COPYING file in your DokuWiki folder for details

Sources of the icons contained in images/:

disk.png
folder_add.png
page.png
page_link.png

Silk icon set 1.3

_________________________________________
Mark James
http://www.famfamfam.com/lab/icons/silk/
_________________________________________

Licensed under a
Creative Commons Attribution 2.5 License.
[ http://creativecommons.org/licenses/by/2.5/ ]


rename.png

SEMLabs Free Web Design Icon Set,
http://semlabs.co.uk/blog/free-web-design-icon-set/

dokuwiki-plugin-move's People

Contributors

alexgearbox avatar annda avatar araname avatar becjie32 avatar bleistivt avatar chang-zhao avatar desolat avatar dregad avatar dturkalj avatar e-dschungel avatar friuli avatar glensc avatar jfmd21 avatar kastra28 avatar kumannn avatar martinr-kytka avatar micgro42 avatar michitux avatar mutanarq avatar nawan95 avatar nfriedli avatar oleksiyfur avatar rattkin avatar sawachan avatar schplurtz avatar splitbrain avatar th-we avatar tormec avatar trebmuh avatar vkristian avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

dokuwiki-plugin-move's Issues

Updating links (relative/absolute) bug

When I rename a page like
"bugs/start" into "bugs",
the renaming itself works well.
Page "/bugs/start" becomes "/bugs".

But updating the links on other pages that were [[bugs/start]] make them [[bugs]].
It means that they point now not relatively to the root, but relatively to the current namespace.

For example, if that link was on a page "/flies/crap", then the updated link [[bugs]] would point to non-existing "/flies/bugs".
So please mind that having separator or not in an inner link makes a difference for the resulting namespace base.

Tree based move doesn't allow move pages in an empty folder

Hi,
I'm trying to use the "tree based move" to move some pages into an empty folder which I've already created (permissions are read and write for all).

It seems to me that if the folder is empty it is not possible to move, with the drag & drop, any pages/folders inside it.

update documentation

hey @michitux and @micgro42 I'd like to publish a little newsletter post on the hackfest soon and it will direct people to the plugin page. Could you update the page to reflect the new state of the plugin?

Possibility to move a page to 'bin' (delete button)?

Hello, I'm looking for a good way to remove pages. Especially new users don't know how to remove pages in the DokuWiki and I would like a user-friendly way to remove a page from the wiki.
Would it be possible to add a 'bin' space which is unreachable for all users, except admins, where old pages can be moved to.
An extra bonus would be a separate 'delete' button to move pages to the bin.

info plugin crash

create page, insert this into it

The following **helper** plugins are available in this particular DokuWiki installation:
~~INFO:helperplugins~~

this results php fatal error with the following in error log:

PHP Warning:  Missing argument 1 for helper_plugin_move_handler::__construct(), called in /usr/share/dokuwiki/inc/plugincontroller.class.php on line 109 and defined in /usr/share/dokuwiki/lib/plugins/move/helper/handler.php on line 37 
PHP Warning:  Missing argument 2 for helper_plugin_move_handler::__construct(), called in /usr/share/dokuwiki/inc/plugincontroller.class.php on line 109 and defined in /usr/share/dokuwiki/lib/plugins/move/helper/handler.php on line 37 
PHP Warning:  Missing argument 3 for helper_plugin_move_handler::__construct(), called in /usr/share/dokuwiki/inc/plugincontroller.class.php on line 109 and defined in /usr/share/dokuwiki/lib/plugins/move/helper/handler.php on line 37 
PHP Warning:  Missing argument 4 for helper_plugin_move_handler::__construct(), called in /usr/share/dokuwiki/inc/plugincontroller.class.php on line 109 and defined in /usr/share/dokuwiki/lib/plugins/move/helper/handler.php on line 37 
PHP Warning:  Missing argument 5 for helper_plugin_move_handler::__construct(), called in /usr/share/dokuwiki/inc/plugincontroller.class.php on line 109 and defined in /usr/share/dokuwiki/lib/plugins/move/helper/handler.php on line 37 
PHP Fatal error:  Error, handler function getInfo with 0 parameters called which isn't implemented in /usr/share/dokuwiki/lib/plugins/move/helper/handler.php on line 363

this is on dokuwiki-20150810a

move doesn't work in animals

When installing the plugin in the farmer of a redirect farm, then it only works within the farmer. In the animals the icon is different:

move_plugin_icon_in_animals

and clicking in the icon doesn't result in any action.

DokuWiki and all plugins are up-to-date.

Relative page includes not updated correctly

When using page includes for example:

{{page>.1:page_1&nofooter&noeditbutton}}

The reference is only parsed correctly on namespace move if there is also a link to that page within the main page. Take this an example structure of:

wiki/old/namespace/main
wiki/old/namespace/1/page_1
wiki/old/namespace/1/page_2

Where the 'main' page content is:

====== Main ======

This is a test page

[[.1:page_1|link]]

{{page>.1:page_1&nofooter&noeditbutton}}

{{page>.1:page_2&nofooter&noeditbutton}}

When moving the namespace that this page and the referenced subpages are in, the result is:

====== Main ======

This is a test page

[[.1:page_1|link]]

{{page>.1:page_1&nofooter&noeditbutton}}

{{page>old:namespace:1:page_2&nofooter&noeditbutton}}

Not translated messages

In the methods move_page() and move_media() are some untranslated messages:
e.g.:

  • 'Error while updating the search index '.$idx_msg
  • 'The meta files of page '.$ID.' couldn\'t be moved'
  • 'The attic files of page '.$ID.' couldn\'t be moved. Please move them manually.'

Other possible improvement is adding a semicolon to the first string. That makes clear that $idx_msg is an additional message.
e.g.:

  • 'Error while updating the search index: '.$idx_msg

Further there are some other untranslated strings.

New Feature - Add native recursive find & replace function to the Move Plugin

Develop an interface to use the find & replace functions so that a user can
Change the media directory to shorten it for example (by FTP Filezilla)
and then use
Find: "{{:opencpn:opencpn_user_manual.."
Replace "{{:opencpn:user.."
All files in Directory: :opencpn:opencpn_user_manual
and -recursively below [check]

For example.

Conflict with Bootstrap Simplified Template

Right after installation an error message is shown:

A fatal error occured during compilation of the CSS files [...]
expected color value: failed at 'border: 1px dashed lighten(@ini_text, 30%);' in /lib/plugins/move/style.less at line 24

Installation Error in move/helper/rewrite.php

during installation this error comes up:

Fatal error: require_once() [function.require]: Failed opening required '__DIR__/handler.php' (include_path='.:/usr/share/php') in /var/www/web87/html/EH/DokuWiki_EH/lib/plugins/move/helper/rewrite.php on line 14

what to do ?

Move for Non-Admins

Thank you for this plugin, this is something really missing from Dokuwiki.

Your plugin seems the only one able to update links too. Unfortunately our users cannot access the Move functionality as it is only available for Admins. Is there a way to activate the feature for regular users too? It would make sense, as they already have the permissions to create and delete pages.
If not - would it be possible to add this feature to this plugin?

Moving files only

Hi,

I've just tested the move plugin on my wiki and stumbled across something.

When I try to move a namespace (pages and files) to another one the plugin indicated that 1 page and 30 media files are supposed to be moved. But when trying to move only media files it indicates that 0 files are moved although I'm in the same namespace. Am I doing something wrong?

Compatibility Question - Move & Indexmenu & Bootstrap3

Originally we had the
Dokuwiki Template and a few of the needed standard "Elenor of Tsort" plugings incluging
the main one that we use for navigation Indexmenu.

We recently changed to Bootstrap3 template and that seemed to be working well with no problems.

We had the Move Plugin installed for quite awhile but had not used it.

I believe I recall that the menus would expand and contract as originally.

One of our Editors recently used the Move Plugin to move a number of pages several stages, but basically in one long session.

Now I notice that the when we focus on a TOC item in the Indexmenu, the previous location does not contract, and the TOC simply gets longer on the left. We are using one of the Indexmenu Javascript TOC configurations.

I am wondering if this is caused by something particular to Indexmenu alone, or if it is related to an interaction. I also wonder if Bootstrap3 might be the problem.

Can you shed any light on this?
Other than that, Indexmenu has been working very well with Bootstrap3 and Move installed.

I am going to asking Bootstrap and Indexmenu about this too.

Is there a cache or something I could clear to perhaps help?

Thank you.

Namespaces other than WIKI in root folder not shown

I have several folders outside the WIKI folder in the root namespace in my wiki, when i want to use the tree based move plugin i am unable to move it because i cannot see them in the tree, all i can see is some *.txt files and the WIKI folder, nothing else.

Allow creation of new namespace in tree move

I have been using this plugin for some years, albeit infrequently, with much satisfaction but for one very annoying point : I cannot create a new namespace in the tree move interface.

Is there a "profound" reason for this or is this just a problem with the interface itself ?
It is indeed possible to create a new namespace by moving one page into it.

It is cumbersome to have to use one interface to move the first page to the new namespace and then go to the tree interface to move the rest. But I have not yet found a workaround when the new namespace is intended to contain only media files.

I propose two solutions for an interface in the tree mode :

  1. Use the rename interface and interpret e.g. :newnamespace:oldname as really meaning to move oldname under :newnamespace instead of escaping this input to _newnamespace_oldname.
  2. In the tree view, add a New namespace node at each level, and again use the rename button to prompt for the name. The actual creation would be deferred until the global move operation is input to avoid creating empty namespaces.

only moving inside same namespace?

[copied from wikipage, not verified]
Seems that namespaces can be moved only inside the same namespace. For example, can not move '':nsX'' into '':nsA:nsX:''. Is that correct ? --- //Carugnom//

Page move not working, call to undefined function getRevisions()

When I try to move a page, a blank page is shown and the page is not moved. Each attempt seems to produce the following error:

php[2864] PHP Fatal error: Call to undefined function getRevisions() in C:\www\dokuwiki\lib\plugins\move\helper.php on line 402

I'm running DokuWiki Elenor-of-Tsort 2016-06-26a with PHP 5.6.23. I had no problems with Detritus 2015-08-10a

Links to media files after moving

Hi Michitux,

it is magnificent, that there is a new plugin for this extremely important purpose, thank you. One thing I've found today when testing the first time:

When moving a namespace with the option to move both text files and media files the media links in the moved pages only work if they were defined as local links.

See this example:
I moved a namespace called ":technik:abt_ks:sap_bereitstellung_transparent" to the new namespace "group:abt_ks:sap_bereitstellung_transparent". The code for a page called "start" begins with these lines:

Bei Erhalt einer Zeichnungsanforderung …
{{bild_001.jpg?direct&}}
… zunächst folgendes überprüfen:

a) Prüfen, ob am Material keine Zeichnung verknüpft ist:
{{:technik:abt_ks:sap_bereitstellung_transparent:bild_002.jpg?direct&}}

In the example the picture "bild_001" appears. But the picture "bild_002" can't be found, because the given namespace for the picture is the path before the movement by the plugin.

Regards Juergen

Latest release leads to gateway error

2016-06-26a "Elenor of Tsort"

After installation of the latest release of the move plugin (2017-01-02), I get only a blank white screen.
Trying to access the wiki again leads to gateway error.

After removing the updated move plugin, the wiki is working normal again.

New Feature - Undo

An undo button, with the ability to undo stored in some file for some adjustible period of time, provided there are no further changes?

Might be very useful.

Swedish language files

Here are Swedish language files for inclusion in some future version.

lang.php:

<?php
/**
 * swedish language file
 *
 * @license    GPL 2 (http://www.gnu.org/licenses/gpl.html)
 * @author     Gary Owen <>
 */

// settings must be present and set appropriately for the language
$lang['encoding']   = 'utf-8';
$lang['direction']  = 'ltr';

// for admin plugins, the menu prompt to be displayed in the admin menu
// if set here, the plugin doesn't need to override the getMenuText() method
$lang['menu'] = 'Flytt/Namnbyte på Sida/Namnrymd...';
$lang['desc'] = 'Plugin för Flytt/Namnbyte på Sida/Namnrymd...';

$lang['notexist']    = 'Sidan %s finns inte';
$lang['medianotexist']    = 'Media filen %s finns inte';
$lang['notwrite']    = 'Du har inte tillräcklig behörighet att ändar på den här sidan';
$lang['badns']       = 'Otillåtet tecken i namnrymd.';
$lang['badname']     = 'Otillåtet tecken i sidnamn.';
$lang['nochange']    = 'Sid- och namnrymdsnamn är inte ändrade';
$lang['nomediachange']    = 'Mediafil- och namnrymdsnamn är inte ändrade';
$lang['existing']    = 'En sida som heter %s finns redan i %s';
$lang['mediaexisting']    = 'En mediafil som heter %s finns redan i %s';
$lang['root']        = '[Rotnamnrymd]';
$lang['current']     = '[Nuvarande]';
$lang['renamed']     = 'Sidnamn ändrat från %s till %s';
$lang['moved']       = 'Sida flyttad från %s till %s';
$lang['move_rename'] = 'Sida flyttad och namnändrad från %s till %s';
$lang['delete']     = 'Borttagen av pluginen';
$lang['norights']    = 'Du har inte tillräcklig behörighet för att ändra %s.';
$lang['nomediarights']    = 'Du har inte tillräcklig behörighet att ta bort %s.';
$lang['notargetperms'] = 'Du har inte tillräcklig behörighet för att skapa sidan %s.';
$lang['nomediatargetperms'] = 'Du har inte tillräcklig behörighet för att skapa mediafilen %s.';
$lang['filelocked']  = 'Sidan %s är låst. Försök senare.';
$lang['linkchange']  = 'Länkar som ändrats på grund av flytt/namnändring';

$lang['ns_move_in_progress'] = 'En namnrymdsflytt eller namnändring av %s sidor och %s mediafiler pågår.';
$lang['ns_move_continue'] = 'Fortsätt flytt av namnrymd';
$lang['ns_move_abort'] = 'Avbryt flytt av namnrymd';
$lang['ns_move_continued'] = 'Namnrymdsflytt från %s till %s pågår, %s åtgärder återstår.';
$lang['ns_move_started'] = 'En namnrymdsflytt från %s till %s har startat, %s sidor och %s mediafiler kommer att flyttas.';
$lang['ns_move_error'] = 'Ett fel uppstod under namnrymdsflytt från %s till %s.';
$lang['ns_move_tryagain'] = 'Försök igen';
$lang['ns_move_skip'] = 'Hoppa över nuvarande åtgärd';
// Form labels
$lang['newname']     = 'Nytt sidnamn:';
$lang['newnsname']   = 'Nytt namn för namnrymden:';
$lang['targetns']    = 'Välj ny namnrymd:';
$lang['newtargetns'] = 'Skapa ny namnrymd:';
$lang['movepage']   = 'Flytta sida';
$lang['movens']     = 'Flytta namnrymd';
$lang['submit']      = 'Genomför';
$lang['content_to_move'] = 'Innehåll att flytta';
$lang['move_pages']  = 'Sidor';
$lang['move_media']  = 'Mediafiler';
$lang['move_media_and_pages'] = 'Sidor och mediafiler';
// JavaScript preview
$lang['js']['previewpage'] = 'OLDPAGE kommer att flyttas till NEWPAGE';
$lang['js']['previewns'] = 'Alla sidor och namnrymder i namnrymden OLDNS kommer att flyttas till namnrymden NEWNS';

move.txt:

====== Flytta och byt namn ======

Den här pluginen gör det möjligt att flytta och/eller byta namn på den aktuella sidan och/eller namnrymden. Följande begränsningar gäller:

  * Du måste ha behörighet att redigera nuvarande/alla sidor i aktuell namnrymd.
  * Sidan/sidorna som flyttas får inte vara låsta.
  * Om du vill flytta en sida måste du också ha behörighet att skapa dokument in den nya namnrymden.
  * Det går inte att flytta en sida till en namnrymd där det redan finns en sida med det namn du vill ge sidan.

Alla länkar från alla sidor till sidor som flyttas uppdateras så att de pekar på det nya namnet eller den nya platsen.

LESS-bug: @ini_text incompatible with bootstrap template

Hey there,

I'm currently having trouble with using your plugin with my bootstrap-template. My template does not provide less variables, but your style.less calls the @ini_text at line 24. So I got an error message. Fixed this with replacing it by the color code directly, but this might be overwritten with the next update. So maybe you can use a local color code here.

Thanks
Franzi

only move media files

Hi,

only moving media files without pages doesn't come to an end in the dialogue "Move in Progress..." although the files in fact are moved.

After cancelling, the page that is influenced by the media moves cannot be edited any more. Instead of this there is a message

Fatal error: Error, handler function adaptRelativeId with 1 parameters called which isn't implemented in /opt/lampp/htdocs/wiki/lib/plugins/move/helper/handler.php on line 381

The mentioned page contains commands of the include plugin and the qna plugin.

Regards
Juergen

Tree move : add checkbox option

Tree move is really good when I must move a lot of pages, but, if I have a lot of pages in the end of my list of pages, it's very hard to drag'n drop. I have a namespace with 600 entries, and my screen is not big enough to see all in once, so I use scrollbar and it's slow...
With checbox, just "check" all the pages we want move, then select the namespace where we want to move them.
If we could use the drag'n drop OR checkbox, it would be wonderful, good for all :)

conflict with "siteexport" plugin: no links rewrite

Under Release 2016-06-26a "Elenor of Tsort"
When both "siteexport" and "move" plugins are activated at the same time, when moving/renaming a file, links on pages pointing to this new name are not updated (checkbox "rewrite links" is checked).
Desactivating the "siteexport" plugin solves the issue.

Feel free to ask for more info.

Regards

not showing destination field

using doku hrun, with move plugin, it is not showing destination field for selection and becuase of the same the progress shows fail

media gets moved, but links are not updated

2015-08-10a "Detritus" / move plugin 2015-05-16

Problem: Media (pictures, jpgs) can be moved via the tree based move, but links to these media are not changed accordingly, despite the fact that the preview shows the link adjustment on the respective pages. "Adjust links after move" is checked. Purging the page cache doesn't help. There are no signs of link adjustment on the "recent edits" page. Only after manual link adjustment, the pictures are then shown again from their new location.

I was hoping to get around the manual re-linking by using the move plugin....

Renaming via the pagetool doesn't invalidate cached pages

After renaming a page, the links to that page are altered correctly, but the cached versions containing pages are not invalidated, thus the old versions appear. Only after edit-cancel the new version with correct link is visible.

Support the struct plugin

Using a field of type "Page" in the struct plugin allows you to refer to one or multiple pages in the structured data of a page. However, when renaming a page using the move plugin, these pages inside the struct data are not renamed.

It would be nice if the move plugin could check pages for struct data and rename them accordingly. However, that would probably require working with the struct plugin's models and functions.

Update: I found out the support can also be done the other way round (from inside the struct plugin), and there is a test for this over there. I managed to pretty quickly end up with dangling references between pages, so maybe the support is just not complete.

It looks like the struct plugin makes sure that any data entered for the page being moved is also moved, but it does not update references to the page being moved on other pages.

transaction not finished when no media files

Hello

I move a namespace, asking for media and pages. If there is no media, the transaction is considered not finished and I will get the Continue/abort buttons on the next trip to the plugin page. But transaction is actually finished.

Could someone confirm this or is it related to my config ?

[feature request] automatic redirection

Hi.

I've been thinking of this feature a few times so, it needs to be shared here.

When moving a page (or a few pages), it would be really handy that the plugin adds an automatic redirection (into the .htaccess maybe?).

Hope that this will retain your attention.

Unable to access Tree based move

I have to move multiple files and pages but Tree based move link is not available from Move page.
I am admin, and I have also setup manager privileges to admin and my userneme.
Can you please help.

Simple Page Rename does not show up

I´m using Release 2016-06-26a "Elenor of Tsort" with the move-plugin. My Template is 'dokuwiki'.
In the config i´m allowing move-rights to @user. But i don´t see the button for simple rename showing up on the webpage.
I don´t see any errors in the webserver-logfiles.
Any hints how to hunt this problem?

Thanks

tags

would you mind creating and pushing release tags to github?

this adds lots of benefits, able to compare changes between releases, and more importantly release tarball of specific release.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.