Fixed some bugs, JSHint compatibility

Fixed candidate view sometimes being empty when it's the first view
opened
Fixed header breaking to two lines on Chrome.
Added a "hiddenlog" div which can be used for logging.
Refactored imageLoader.
Fixed things that JSHint didn't like or added them as exceptions through
control comments.