add log snippets for javascript and perl