ProfessorSr
OK. Here is where I am at so far. I have figured out how to create multiple form pages into a module. I also know how to create a custom page. Now, how do i get my module to display custom page.

At http://www.mytherapysession.net/m/complete/generalhealth you will see one of the pages that is displayed from my modules/mts/complete/classes/MtsCompleteModule.php

On this page there are a few functions like this:



function actionGeneralHealth () {

if (!$GLOBALS['logged']['member'] && see more !$GLOBALS['logged']['admin']) { // check access to the page
$this->_oTemplate->displayAccessDenied ();
return;
}

$this->_oTemplate->pageStart(); // all the code below will be wrapped by the user design

bx_import ('BxTemplFormView'); // import forms class

$oForm = new BxTemplFormView ($this->generalhealthForm); // create foprms class

$oForm->initChecker(); // init form checker

if ($oForm->isSubmittedAndValid ()) { // if form is submitted and not form errors were found, save form data

$aValsAdd = array ( // add additional fields
'date' => time(),
'patient_id' => $_COOKIE['memberID'],
);
$iEntryId = $oForm->insert ($aValsAdd); // insert data to database

if ($iEntryId) { // if post was successfully date
$sRedirectUrl = BX_DOL_URL_ROOT . $this->_oConfig->getBaseUri() . 'view/' . $iEntryId;
header ('Location:' . $sRedirectUrl); // redirect to created post view page
exit;
} else {
MsgBox(_t('_Error Occured')); // if error occured display error message
}

} else {

echo $oForm->getCode (); // display form, if the form is not submitted or data is invalid

}

$this->_oTemplate->pageCode(_t('_mts_complete_page_title_add'), true); // output is completed, display all output above data wrapped by user design
}

//end of code



Now, If you go to mytherapysession.net/example.php - you will see a basic custom page with no blocks.



What I want to do is to use a custom page to display the form in a block so that i can add more blocks to the page.
 
 
Below is the legacy version of the Boonex site, maintained for Dolphin.Pro 7.x support.
The new Dolphin solution is powered by UNA Community Management System.
PET:0.033371925354004