Example #1
0
    $NextYearBudget = 0;
    // Table Headers
    echo '<form onSubmit="return VerifyForm(this);" id="form" action="' . htmlspecialchars($_SERVER['PHP_SELF'], ENT_QUOTES, 'UTF-8') . '" method="post" class="noPrint">';
    echo '<div>';
    echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />';
    echo '<br />
			<table class="selection" width="90%" summary="' . _('Budget Entry') . '">
			<tr>
				<th colspan="3">' . _('Last Financial Year') . '</th>
				<th colspan="3">' . _('This Financial Year') . '</th>
				<th colspan="3">' . _('Next Financial Year') . '</th>
			</tr>
			<tr>
				<th colspan="3">' . _('Year ended') . ' - ' . Date($_SESSION['DefaultDateFormat'], YearEndDate($_SESSION['YearEnd'], -1)) . '</th>
				<th colspan="3">' . _('Year ended') . ' - ' . Date($_SESSION['DefaultDateFormat'], YearEndDate($_SESSION['YearEnd'], 0)) . '</th>
				<th colspan="3">' . _('Year ended') . ' - ' . Date($_SESSION['DefaultDateFormat'], YearEndDate($_SESSION['YearEnd'], 1)) . '</th>
			</tr>
			<tr>';
    for ($i = 0; $i < 3; $i++) {
        echo '<th width="10%">' . _('Period') . '</th>
				<th width="10%">' . _('Actual') . '</th>
				<th width="10%">' . _('Budget') . '</th>';
    }
    echo '</tr>';
    // Main Table
    for ($i = 1; $i <= 12; $i++) {
        echo '<tr>';
        echo '<th>' . $PeriodEnd[$CurrentYearEndPeriod - (24 - $i)] . '</th>';
        echo '<td class="number">' . locale_number_format($Actual[$CurrentYearEndPeriod - (24 - $i)], $_SESSION['CompanyRecord']['decimalplaces']) . '</td>';
        echo '<td><input type="text" readonly="true" class="number" size="12" name="' . $i . 'last" value="' . locale_number_format($Budget[$CurrentYearEndPeriod - (24 - $i)], $_SESSION['CompanyRecord']['decimalplaces']) . '" /></td>';
        echo '<th>' . $PeriodEnd[$CurrentYearEndPeriod - (12 - $i)] . '</th>';
Example #2
0
 }
 $LastYearActual = 0;
 $LastYearBudget = 0;
 $ThisYearActual = 0;
 $ThisYearBudget = 0;
 $NextYearActual = 0;
 $NextYearBudget = 0;
 // Table Headers
 echo '<FORM name="form" ACTION=' . $_SERVER['PHP_SELF'] . '?' . SID . ' METHOD=POST>';
 echo '<CENTER><br><TABLE>';
 echo '<TR><TH COLSPAN=3>' . _('Last Financial Year') . '</TH>';
 echo '<TH COLSPAN=3>' . _('This Financial Year') . '</TH>';
 echo '<TH COLSPAN=3>' . _('Next Financial Year') . '</TH></TR>';
 echo '<TR><TH COLSPAN=3>' . _('Year ended') . ' - ' . Date($_SESSION['DefaultDateFormat'], YearEndDate($_SESSION['YearEnd'], -1)) . '</TH>';
 echo '<TH COLSPAN=3>' . _('Year ended') . ' - ' . Date($_SESSION['DefaultDateFormat'], YearEndDate($_SESSION['YearEnd'], 0)) . '</TH>';
 echo '<TH COLSPAN=3>' . _('Year ended') . ' - ' . Date($_SESSION['DefaultDateFormat'], YearEndDate($_SESSION['YearEnd'], 1)) . '</TH></TR>';
 echo '<TR>';
 for ($i = 0; $i < 3; $i++) {
     echo '<TH>' . _('Period') . '</TH><TH>' . _('Actual') . '</TH><TH>' . _('Budget') . '</TH>';
 }
 echo '</TR>';
 // Main Table
 for ($i = 1; $i <= 12; $i++) {
     echo '<TR>';
     echo '<TD BGCOLOR="a9d3e7">' . $PeriodEnd[$CurrentYearEndPeriod - (24 - $i)] . '</TD>';
     echo '<TD BGCOLOR="d2e5e8" ALIGN="RIGHT">' . number_format($actual[$CurrentYearEndPeriod - (24 - $i)], 2, '.', '') . '</TD>';
     echo '<TD BGCOLOR="d2e5e8" ALIGN="RIGHT">' . number_format($budget[$CurrentYearEndPeriod - (24 - $i)], 2, '.', '') . '</TD>';
     echo '<TD BGCOLOR="a9d3e7">' . $PeriodEnd[$CurrentYearEndPeriod - (12 - $i)] . '</TD>';
     echo '<TD BGCOLOR="d2e5e8" ALIGN="RIGHT">' . number_format($actual[$CurrentYearEndPeriod - (12 - $i)], 2, '.', '') . '</TD>';
     echo '<TD><INPUT TYPE="TEXT" onChange="numberFormat(this,2)" onKeyPress="return restrictToNumbers(this, event)" STYLE="text-align: right" SIZE=14 NAME=' . $i . 'this' . ' VALUE="' . number_format($budget[$CurrentYearEndPeriod - (12 - $i)], 2, '.', '') . '"></TD>';
     echo '<TD BGCOLOR="a9d3e7">' . $PeriodEnd[$CurrentYearEndPeriod + $i] . '</TD>';