Added searching based on Lot

git-svn-id: https://rosehill.googlecode.com/svn/trunk@61 100bd78a-fc82-11de-b5bc-ffd2847a4b57
This commit is contained in:
inghamn 2010-01-28 20:21:40 +00:00
parent 2e91a35e6f
commit dcbda56d96
3 changed files with 36 additions and 5 deletions

View File

@ -52,6 +52,8 @@
}
?>
</select>
<label for="lot">Lot</label>
<input name="lot" id="lot" size="3" value="<?php echo isset($_GET['lot']) ? View::escape($_GET['lot']) : ''; ?>" />
</td>
</tr>
</table>

View File

@ -4,7 +4,7 @@
* @license http://www.gnu.org/copyleft/gpl.html GNU/GPL, see LICENSE.txt
* @author Cliff Ingham <inghamn@bloomington.in.gov>
*/
$knownFields = array('lastname','firstname','cemetery_id','section_id');
$knownFields = array('lastname','firstname','cemetery_id','section_id','lot');
$search = array();
foreach ($_GET as $field=>$value) {

View File

@ -1,9 +1,38 @@
<?php
/**
* @copyright 2009 City of Bloomington, Indiana
* Logs a user into the system.
*
* A logged in user will have a $_SESSION['USER']
* $_SESSION['IP_ADDRESS']
*
* @copyright 2006-2010 City of Bloomington, Indiana
* @license http://www.gnu.org/copyleft/gpl.html GNU/GPL, see LICENSE.txt
* @author Cliff Ingham <inghamn@bloomington.in.gov>
*/
$template = new Template();
$template->blocks[] = new Block('loginForm.inc');
echo $template->render();
if (isset($_REQUEST['return_url'])) {
$_SESSION['return_url'] = $_REQUEST['return_url'];
}
require_once '/var/www/libraries/SimpleCAS/SimpleCAS/Autoload.php';
$options = array('hostname'=>'bandit.bloomington.in.gov',
'uri'=>'cas');
$protocol = new SimpleCAS_Protocol_Version2($options);
$client = SimpleCAS::client($protocol);
$client->forceAuthentication();
if ($client->isAuthenticated()) {
$user = new User($client->getUsername());
$user->startNewSession();
setcookie('cas_session','true',0,'/','.bloomington.in.gov');
if (isset($_SESSION['return_url'])) {
header('Location: '.$_SESSION['return_url']);
}
else {
header('Location: '.BASE_URL);
}
}
else {
echo "Could not log in";
}