Script APIs for the maximum page title and reference lengths
Last modified by Vincent Massol on 2026/10/15 16:28
$xwiki.documentTitleMaxLength and $xwiki.documentLocalReferenceMaxLength return the maximum length of a page title and of a page's local reference, as allowed by the database. The standard editor, the in-place editor and the AppWithinMinutes title fields now use the first one, so a title that is too long can no longer be entered and then fail to save. $doc.getLocalReferenceMaxLength() and XWikiDocument#getLocalReferenceMaxLength() are deprecated in favour of the new APIs.