21.09.2015, 22:31
Check the documentation for strfind because you are using it incorrectly. You need to check that it is "not -1" rather than "equal to 0" because strfind returns the position the substring was found at and not just true or false.
Edit: for cleaner code and more efficient maintenance you should add all search keywords into an array and loop over it. To verify an IP address you can also use sscanf:
Edit: for cleaner code and more efficient maintenance you should add all search keywords into an array and loop over it. To verify an IP address you can also use sscanf:
PHP код:
sscanf(input, "{p<.>dddd}")