replaces all puts with puts2log - rollback for jquery.js