require scriptHtml before calling it