Skip to content
This repository has been archived by the owner on May 31, 2023. It is now read-only.

Commit

Permalink
Created PHP version of check-special-character (#6484)
Browse files Browse the repository at this point in the history
Co-authored-by: Harsh Raj <harshraj8843@gmail.com>
  • Loading branch information
esivakumar26 and harshraj8843 committed Mar 3, 2023
1 parent a112472 commit ac2a0c4
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions program/check-special-character/check-special-character.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?php
$string = readLine("Enter String: ");
if (preg_match('/[\'^£$%&*()}{@#~?><>,|=_+¬-]/', $string)) {
echo "one or more 'special characters' found";
} else {
echo "no 'special characters' found";
}
?>

0 comments on commit ac2a0c4

Please sign in to comment.