strip bad chars from tags