Invisible special characters in my PHP requests…
Hello,
I use a special Keyboard (french-bepo), and there is a special keys Combination which kills quite often my php request :
If I type [SHIFT] + [SPACE], it creates a special SPACE : a nbsp space.
The problem is that it's completely invisible in phpstorm Editor :
from example the request "SELECT * FROM foo"; won't work, just because I forgot to release the SHIFT key after typing FROM.
The only way to see it is to copy-paste the code in notepad++, and change the encoding view from UTF-8 to ANSI : here the invisible special chars appear.

See ? in notepad++ an "Â" appears between FROM and foo… and you understand why my request does not work…
Is there à way in phpstorm settings to show this special character in editor window ???
(I've tried to change encoding in File/settings/Editor/File Encodings, but there is no difference)
Best Regards,
Fabrice
Please sign in to leave a comment.
In PhpStorm, there's a special inspection for that -
Non-ASCII characters.The only problem with it is that it doesn't work with strings as expected: https://youtrack.jetbrains.com/issue/WI-43522
While it awaits resolution, you can use Ctrl+F in the Regex mode searching for
[^\x00-\x7F]: http://prntscr.com/kuft12Many Thanx,
Even if it's not "automatic", your regex solution works perfectly, I won't need anymore to open notepad++ to check my strings.
Try "Zero width locator plugin" (just in case) -- that "Â" might be part of some Unicode symbol.
Thanx Andriy,
this soluce is even better than non-ascii characters inspection (almost all strings had warnings, because french language uses tons of non-ascii characters…) and Regex solcution.
Now I have an immediate alert when I type the npsb space.