add customized tags to render html page
add sql for active interlock