A small javascript text parser