You need to know that .[^!,+,§,\),\(,=,\-,\.,:,,,\w]
is a monstrosity. In normal regex, this would be:
.[^-.,:+=!§()\w]
The [brackets]
indicate a character class. They mean "match one character in this class," or, when the first charcter is ^
"match one character that is not in this class." So there is never any need to repeat a character in a character class. This one has eleven commas!
Your test could be expressed in this compact fashion:
$theregex = '~.[^-.,:+=!§()\w]~';
echo (preg_match($theregex, $yourstring)) ? "**It Matches!**" : "Nah... No match." ;
But that probably doesn't work the way you want anyway
The original regex begs the question: what where they thinking when they wrote this? Clearly whoever wrote this was regex-illiterate (and I don't mean to be gratuitously condescending... that's just a fact.) Therefore, it is quite likely that they had something quite different in mind when they wrote it. And if that's a case, it doesn't matter how well you translate it: it won't do the job it was intended for.
If you know what the regex is supposed to do, tell us, and we'll help you fix it.