image testing and update function with checkbox