I have been trying to sanitize user input for saving safely in the database and then redisplaying.
If a user enters something like M'Cain for the name, how should I sanitize it before sending to the database, and then when reading back, deal with it so that it displays correctly.
Currently I am using sanitize_text_field which adds the \ before the apostrophe, but this then displays when I display it back.
Do I simply use strip_slashes before outputing back to the screen or another function?