#set default values #submit msg $profile->msg_updateSuccess = "Your Profile was updated successfully."; //set all output to be returned instead of printed $profile->returnOutput = true; //test for last page and no errors to submit form, otherwise start form if (@$_POST['formitable_multipage'] != "end" || isset($profile->errMsg)) { $profileOpen = $profile->openForm(); $smarty->assign('profileOpen', $profileOpen); } else { $profile->submitForm(false); } //first page - test for no submit OR errors set with a field on the first page if (!isset($_POST['submit']) || isset($profile->errMsg) && isset($_POST['firstname'])) { #print first page $page1 = "page 1"; $smarty->assign('page1', $page1); $fname = $profile->printField('firstname'); $smarty->assign('fname', $fname); $lname = $profile->printField('lastname'); $smarty->assign('lname', $lname); $end = $profile->multiPage("end"); $smarty->assign('end', $end); $profileClose = $profile->closeForm(); $smarty->assign('profileClose2', $profileClose); } else { $smarty->assign('updateMsg', $profile->submitMsg); #unset prevPath unset($_SESSION['prevPath']); } $content = $smarty->fetch("./user/user.upd_profile.tpl.html");
$page1 = "page 1"; $smarty->assign('page1', $page1); $id = $staff->printField('identifier'); $smarty->assign('id', $id); $fname = $staff->printField('firstname'); $smarty->assign('fname', $fname); $lname = $staff->printField('lastname'); $smarty->assign('lname', $lname); $reg_date = $staff->printField('reg_date'); $smarty->assign('reg_date', $reg_date); $username = $staff->printField('username'); $smarty->assign('username', $username); $password = $staff->printField('password'); $smarty->assign('password', $password); $pass_verify = $staff->printField('password', '', true); $smarty->assign('pass_verify', $pass_verify); $chg_pass = $staff->printField('change_password'); $smarty->assign('chg_pass', $chg_pass); $acc_status = $staff->printField('account_status'); $smarty->assign('acc_status', $acc_status); $end = $staff->multiPage("end"); $smarty->assign('end', $end); $staffClose = $staff->closeForm(); $smarty->assign('staffClose3', $staffClose); } else { #submit msg $smarty->assign('updateMsg', $staff->submitMsg); #unset prevPath unset($_SESSION['prevPath']); } $content = $smarty->fetch("./user/user.reg_user.tpl.html");
?> </td> <td width=225><?php $newForm->printField("Age"); ?> </td> <td width=225><?php $newForm->printField("gender"); ?> </td> </tr> </table> <?php //on the first page set multipage to "start" $newForm->multiPage("start"); $newForm->closeForm(); ?> <?php //test for a field on the previous page OR errors set with a field from this page } elseif (isset($_POST['FName']) || isset($newForm->errMsg) && isset($_POST['City'])) { /*** open form pg 2 of 3 ***/ ?> <h3>Page 2 of 3</h3> <table> <tr> <td width=225><?php $newForm->printField("Occupation"); ?> </td>