Fileman
Manage Files
Move a file
This function moves a file or directory to a new location. If the destination is an existing directory, the source is moved into it. The function returns an error if the destination already exists.
Important:
When you disable the File Storage role, the system disables this function.
get/Fileman/move_file
Query parameters
destinationstring path required
Example:public_html/subdir/new.txt
The path to move the source to.
sourcestring path required
Example:public_html/old.txt
The path to the file or directory to move.
Response
HTTP Request was successful.
Example response
{
"apiversion": 3,
"func": "move_file",
"module": "Fileman",
"result": {
"data": {
"src": "/home/user/public_html/old.txt",
"dest": "/home/user/public_html/subdir/new.txt"
},
"status": 1
}
}