fix some bugs and radio buttons