Added console output for logs

Also added code to ensure that the main file handler for the logfile is
always the first entry in the handler list, even when the day changes
and the handler is recreated.