Properly escape quotes from input field values