moved inline javascript to articles.js