diff --git a/index.html b/index.html new file mode 100644 index 0000000..fb3137f --- /dev/null +++ b/index.html @@ -0,0 +1,26 @@ + + +First exercise on php + + + +
+Pick Category: + +Search: + +
+ + \ No newline at end of file diff --git a/results.php b/results.php new file mode 100644 index 0000000..233e2ce --- /dev/null +++ b/results.php @@ -0,0 +1,65 @@ + +".$movies[0][$i]."
"; + } + + elseif ($movie_type == 'Comedy') + { + for($i=0;$i<3;$i++) + if(stristr($movies[1][$i], $moviestxt) == TRUE) + echo "
".$movies[1][$i]."

"; + } + + elseif ($movie_type == 'Horror') + { + for($i=0;$i<3;$i++) + if(stristr($movies[2][$i], $moviestxt) == TRUE) + echo "
".$movies[2][$i]."

"; + } + + else echo "Movie not found!"; +} + +else echo "
Please insert a string
"; + +echo "
Return to search form
"; + +?> \ No newline at end of file