CORE POS - IS4C
The CORE POS front end
HelloWorld.php

AutoLoader.php should be included in any top level scripts. If the URL in the browser address bar is your script, it's a top level script. No other includes are necessary. AutoLoader will include other classes as needed.

body_content() draws the page. Methods from BasicPage provide the standard input box at the top and footer at the bottom. DisplayLib::boxMsg() is a utility function that puts the 'Hello World' message in a standard message box.

preprocess() handles input. In this case any form input causes a redirect to the main display script.

Note the very last line creating an object. That's necessary to actually display anything.

<?php
include_once(dirname(__FILE__).'/../lib/AutoLoader.php');
class HelloWorld extends BasicPage {
function body_content(){
$this->input_header();
echo '<div class="baseHeight">';
echo DisplayLib::boxMsg('<b>Hello World!</b><br />
Enter anything to continue');
echo '</div>';
$this->footer();
}
function preprocess(){
if (isset($_REQUEST['reginput'])){
header("Location: {$this->page_url}gui-modules/pos2.php");
return False;
}
return True;
}
}
new HelloWorld();
?>