Set url slug on page creation
I am creating pages using the standard method below and i have a form field where the user can insert the url slug. I have looked at the api docs but cannot see anywhere how to set the url slug.
$data = array('ctID' =>$ct->getCollectionTypeID(), 'cDescription' => $this->post('boatOverview'), 'cName' => $this->post('boatName')); $p->update($data);
Any guidance would be appreciated i have tried adding 'urlSlug' => $this->post('urlfield'));