Skip to content

Instantly share code, notes, and snippets.

@MrJSdev
Last active April 11, 2017 06:24
Show Gist options
  • Select an option

  • Save MrJSdev/bd4f36e220ba404dc1d628ccd450bdb5 to your computer and use it in GitHub Desktop.

Select an option

Save MrJSdev/bd4f36e220ba404dc1d628ccd450bdb5 to your computer and use it in GitHub Desktop.
This is also the checking of array that contains specific word: The whole post is available at http://extracatchy.net
<?php
$students = array("Rahul, Salim, Aftab, Shahnawaz, Faizal, Sameer");
$stringtocheck = "Aftab";
if(is_our_student($students, $stringtocheck)) {
echo "It is our student.";
} else {
echo "Uknown child and he/she is not our student.";
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment