improvement to emagid.php, and new HTML/Form library