Replace pg_query() with pg_query_params() & some minor changes
Merge branch 'master' of github.com:chk1/eggtracker