/**
  * Creates new user in this user group.
  * WARNING: Data is not sent to Kayako unless you explicitly call create() on this method's result.
  *
  * @param string $full_name Full name of new user.
  * @param string $email E-mail address of new user.
  * @param string $password Password of new user.
  * @return kyUser
  */
 public function newUser($full_name, $email, $password)
 {
     return kyUser::createNew($full_name, $email, $this, $password);
 }
    echo !$form_valid && $fields_valid['enable_dst'] !== true ? ' error' : '';
    ?>
">Enable Daylight Saving Time.</span>
			</label>
		</fieldset>

		<input type="submit" name="submit_user" value="Submit">
	</form>
<?php 
}
//we are creating the user
if ($render === 'submit') {
    //load default user group
    $user_group = kyUserGroup::getAll()->filterByTitle(USER_GROUP_TITLE)->first();
    //create the user
    $user = kyUser::createNew($full_name, $email, $user_group, $password)->setEnableDST($enable_dst)->setSendWelcomeEmail(SEND_WELCOME_EMAIL);
    if (is_numeric($user_organization_id)) {
        $user->setUserOrganizationId($user_organization_id);
    }
    if (strlen($salutation)) {
        $user->setSalutation($salutation);
    }
    if (strlen($salutation)) {
        $user->setDesignation($designation);
    }
    if (strlen($salutation)) {
        $user->setPhone($phone);
    }
    if (strlen($salutation)) {
        $user->setTimezone($timezone);
    }