output to page instead of alert
add duplicated check in setup server code