<?php
/**
* @author Prakash Khanchandani
* @copyright 2013
* @program hyperDemo.php
* demonstrating the generation of hyper links through the list processor
*/
require_once "listPrcsr.php"; // the list processor class
require_once "getData.php"; // functions to generate data for the demo
/*
create a descriptive array for the data. Consult basicDemo.php for a description
of this array.
*/
$des[] = array("Branch", "L", "Y", "Y", "brnch");
$des[] = array("Product Type", "L", "Y", "N", "");
$des[] = array("Account No", "L", "Y", "Y", "acnt");
$des[] = array("Title", "L", "Y", "N", "");
$des[] = array("Available Balance", "R", "Y", "N", "", 2);
$des[] = array("Ledger Balance", "R", "Y", "N", "", 2);
/*
the Branch and AccountNo elements will be contained in the hyperlink
with "brnch" and "acnt" as the request elements. Note the includeInGet is
set to a "Y" for both these while it is set to "N" for the others. */
$lp = new listPrcsr();
$lp->moneyFormat = "R";
$lp->data = getLimitedData();
$lp->des = $des;
$lp->opt = "Y";
/*
setting opt to "Y" above will enable hyperlinks. */
$lp->prg = "";
/*
the program to be called is set above. */
$lp->max = 0;// display full list in one page
$out = $lp->gnrtOutput();
include 'inc1.php';
?>
|