$version->replace()
Replaces the content of the current version with the given fields
$version->replace() has been marked as unstable. It might be changed in a future Kirby major or minor release without being considered a breaking change. Use with caution.
$version->replace(array $fields, Kirby\Cms\Language|string $language = 'default'): void
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
| $fieldsrequired | array<string, string> |
no default value | Content fields |
| $language | Kirby\Cms\Languageorstring |
'default'
|
Exceptions
| Type | Description |
|---|---|
Kirby\Exception\NotFoundException |
If the version does not exist |