How can I filter out profanity in base36 IDs?
问题 I want to use base36 in a web application I am developing... but as the id is visible to users as a url, I want to filter out profanity. Has anyone solved this? Or is this even a real problem? Does it make sense just to skip numbers in my database sequence? 回答1: Well, rather than try to amass all the swear words possible, just filter out the vowels. That'll leave you plenty of permutations in the space. Admittedly, you've just cut down from base 36 to base 31, but base 31 numbers are valid