Manual:MoveBatch.php: Difference between revisions
Appearance
Content deleted Content added
style |
prepare for translation |
||
| Line 31: | Line 31: | ||
|} |
|} |
||
<translate> |
|||
==Example== |
==Example== |
||
</translate> |
|||
;For Windows user |
|||
; <translate>For Windows user</translate> : |
|||
| ⚫ | |||
<translate> |
|||
| ⚫ | |||
| ⚫ | |||
<translate> |
|||
How to do that using moveBatch.php? |
|||
Command Code for batch moving will be like this: |
|||
</translate> |
|||
| ⚫ | |||
<translate> |
|||
To Do |
To Do |
||
* If you have local server, Run Apache+MySQL |
* If you have local server, Run Apache+MySQL</translate> |
||
| ⚫ | |||
<translate> |
|||
<Poem> |
|||
| ⚫ | |||
| ⚫ | |||
</translate> |
|||
| ⚫ | |||
<source lang=text> |
|||
| ⚫ | |||
| ⚫ | |||
</Poem> |
|||
| ⚫ | |||
| ⚫ | |||
| ⚫ | |||
</source> |
|||
<translate> |
|||
| ⚫ | |||
<translate> |
|||
* In CMD show where is your php.exe located, then show where is your moveBatch.php located and finally give where is your list file location |
* In CMD show where is your php.exe located, then show where is your moveBatch.php located and finally give where is your list file location |
||
Filanl Command will be look like this |
Filanl Command will be look like this |
||
</translate> |
|||
<code>C:\xampp\core\php55\php.exe C:\xampp\htdocs\mw\maintenance\moveBatch.php --noredirects C:\xxx.txt</code> |
<code>C:\xampp\core\php55\php.exe C:\xampp\htdocs\mw\maintenance\moveBatch.php --noredirects C:\xxx.txt</code> |
||
<translate> |
|||
That's it! |
That's it! |
||
</translate> |
|||
[[Category:Maintenance scripts{{translation}}|MoveBatch.php]] |
[[Category:Maintenance scripts{{translation}}|MoveBatch.php]] |
||
Revision as of 10:39, 8 January 2017
| MediaWiki file: moveBatch.php | |
|---|---|
| Location: | maintenance/ |
| Source code: | master • 1.46.0 • 1.45.4 • 1.43.9 |
| Classes: | Find code • Find documentation |
Details
moveBatch.php file is a maintenance script to move (rename) a batch of pages. If the target page already exist it will fail with an error message.
Usage
| Option/Parameter | Description |
|---|---|
-u <user> |
Username that will be shown in the log entries. If left empty, moves will be attributed to the user called Move page script. |
-r <reason> |
Reason for moves. If empty, no reason will be shown in the logs. |
-i <interval> |
Number of seconds to sleep after each move. If empty, defaults to 0. |
<listfile> |
File should contain lines of text in the following format:
existing name 1|new name 1
existing name 2|new name 2
existing name 3|new name 3
|
Example
- For Windows user
Suppose, A page called Manual:Wiki Edit was created in main namespace and we want to move it to Help: namespace.
How to do that using moveBatch.php?
Command Code for batch moving will be like this:
location of php.exe location of moveBatch.php --noredirects location of listfiles.txt
To Do
- If you have local server, Run Apache+MySQL
- Make list of pages you want to move and save as
xxx.txtfile. Pages name should be arranged like this:
Manual:Wiki Edit|Help:Wiki Edit
Manual:Extensions|Help:Manual:Extension
Manual:How to use moveBatch.php|Help:How to use moveBatch.php
- Open your CMD (Command Prompt window). To open do this press
windows key+R keythen writecmdand pressEnter - In CMD show where is your php.exe located, then show where is your moveBatch.php located and finally give where is your list file location
Filanl Command will be look like this
C:\xampp\core\php55\php.exe C:\xampp\htdocs\mw\maintenance\moveBatch.php --noredirects C:\xxx.txt
That's it!
[[Category:Maintenance scriptsTemplate:Translation|MoveBatch.php]]