adding toggler code