adding json parse logic into terms.html and terms.js