/* A bit of fancy footwork to get the browser's inside dimensions in pixels. Should work on both NS4+ and IE4+. If it doesn't we default it to something sane. The dimensions are returned to the server via a Javascript cookie so as to not muck up our nice clean URL. The function is called if we don't have the dimensions already, or on a resize event to fetch the new window dimensions. */?>
<?php
require 'HTML/QuickForm.php';
$form = new HTML_QuickForm();
$form->addElement('text','my_name','Your name: ');
$form->addElement('submit','send','Say Hello');
if ($form->validate()) {
$form->process('say_hello');
} else {
$form->display();
}
function say_hello($data) {
print 'Hello, ' . $data['my_name'];
}
?>