finallymanaged to add notes to visitors with javascript. Contains much redundant code