Exemplo n.º 1
0
// programmer:	Jafarkhani
// create Date:	89.02
//---------------------------
require_once 'header.php';
include_once '../global/public.php';
include_once '../formGenerator/form.class.php';
include_once '../devotions/dvt.class.php';
include_once '../states/states.class.php';
include_once '../rents/rnt.class.php';
$FormID = $_GET["FormID"];
$referenceID = $_GET["referenceID"];
$LetterID = isset($_GET["LetterID"]) ? $_GET["LetterID"] : "";
$fromPage = isset($_GET["from"]) ? $_GET["from"] : "";
$RefID = isset($_GET["RefID"]) ? $_GET["RefID"] : "0";
//__________________________________________________________
$formRecord = FormGenerator::select("FormID=" . $FormID);
$formFile = $formRecord[0]["FileType"] == "" ? false : true;
if ($formFile) {
    $fileContent = "<tr><td>" . file_get_contents("../../" . FormImagePath . "form" . $FormID . "." . $formRecord[0]["FileType"]) . "</td></tr>";
}
$output = "";
//__________________________________________________________
switch ($formRecord[0]["reference"]) {
    case "devotions":
        $mainDateRecord = be_devotion::select("dvt01=" . $referenceID);
        $mainDateRecord = $mainDateRecord[0];
        break;
    case "states":
        $mainDateRecord = be_state::select("sta02=" . $referenceID);
        $mainDateRecord = $mainDateRecord[0];
        break;