$fileActions->changeName()
Renames the file (optionally also the extension). The store is used to actually execute this.
$fileActions->changeName(string $name, bool $sanitize = true, string|null $extension = null): Kirby\Cms\FileActions
Parameters
Name | Type | Default |
---|---|---|
$namerequired | string |
no default value |
$sanitize | bool |
true
|
$extension | string ornull |
null
|
Return type
Kirby\Cms\FileActions
This method does not modify the existing $fileactions
object but returns a new object with the changes applied. Learn more →
Exceptions
Type | Description |
---|---|
Kirby\Exception\LogicException |
Parent class
Kirby\Cms\FileActions