This elementary tutorial describes how to search an array to see if a specific item lies in it. In the tutorial, we create an array of strings such as "Apple" and "Orange" then show you how to use PHP to find out that "Apple" is in the array but "Monkey" is not. This can be useful in PHP programs if you have a collection of items (perhaps that a user has entered) and you want to know if a certain item is in that collection.
Want to learn php, we have set up a simple to follow quick guide to send you on your way.
We cover all the very basics of php also find our other tutorials covering an even wider range of php coding.
Platform(s): Linux, Windows, FreeBSD, Mac OSX, Sun Solaris
This tutorial will take you through both the IF and the IF-Else statement by comparing numbers, although relativly simple you can expand on them so that you can run checks on various things, such as passwords.
As in many languages, there are 150 different ways to do just about everything, the same rule applies for a simple connection and output of data in a mySQL database using PHP. This tutorial will give you only one way of accomplishing this, and while it works, it is definitely not the only way.
This article will explain how to build dynamic web pages with PHP. PHP is a very popular and easy to learn script language. Regardless if you are starting to build your website, or if you are already a pro, just read on to learn more about dynamic web pages and PHP.
The quickest way to learn PHP is to start using it and see what happens. This tutorial starts by diving right into the good old "Hello World" script you may have seen when learning other languages. Then, it presents another example that writes a Tip of the Day on your Web page using file and random functions.