Added js log file. Js errors and info now reported and logged on server.

Also added debug_id param which if specified in url will be placed in the log items.