Reference

Guide

$page->changeSlug()

Changes the slug/uid of the page

$page->changeSlug(string $slug, string $languageCode = null): Kirby\Cms\Page

Parameters

Name Type Default Description
$slug string
$languageCode string null

Return type

Kirby\Cms\Page

Exceptions

Type Description
Kirby\Exception\LogicException

If the directory cannot be moved

Details

Source code

kirby/src/Cms/PageActions.php#L81