Ajax update & issue #13 almost done

Implemented helper files and brought back the size of the ajax.php
controller. Still very if not TOO big.