Hi, I have a function where you can choose which special characters to allow inside your input, and depending on function call input it will choose correct if statement to run, one if statement allows special characters such as underscore and dash (_ and -), another if statement is set to allow empty spaces and apastrophes
Both of if statement work like they should, they allow special characters that they are supposed to allow, but when it comes to stopping consecutive use of those special characters, only if statement that allow - and _ works at detecting and block consecutive use of them, while second if statement that is responsible for space and apastrophe doesn't detect consecutive use of space and apastrophe, why is that?
Code was too long so here is pastebin code
Pastebin.com is the number one paste tool since 2002. Pastebin is a website where you can store text online for a set period of time.