some cleanup on cntrl
and updated UI on edit.html