method setUrl documentation in bbn\Appui\Cms

Inserts the url for the note if it doesn't exist a published note with the same url or update the url of the given note.

function(string $id_note, string $url, $ignore = false) { if ($tmp = $this->note->urlToId($url)) { if ($ignore && ($tmp === $id_note)) { return 0; } throw new Exception(X::_('The url you are trying to insert already belongs to a published note. Unpublish the note or change the url!')); } if (!$this->note->get($id_note)) { throw new Exception(X::_('Impossible to find the given note')); } if ($res = $this->note->insertOrUpdateUrl($id_note, $url)) { $this->cacheDelete($id_note); } return $res; }

Inserts the url for the note if it doesn't exist a published note with the same url or update the url of the given note. BBN is a suite of PHP and JS libraries and VueJS components - all open-source! bbn.io, build applications, the quick way

This website uses cookies to ensure you get the best experience on our website.