Fix potential problems with javascript/translations

'Automation Instructions' may contains quotes in translations: let's be
sure to correctly escape it before using it in JavaScript
Merge pull request #1645 from mlocati/fix-js-string-jobs

Fix potential problems with javascript/translations