More Operators

I l @ ve RuBoard

I discussed most of PHP's operators in the previous chapters along with the variables that use them. These operators include arithmetic for numbers : addition (+), subtraction (-), multiplication (*), and division (/), along with the incremental (++) and decremental ( ”) shortcuts for increasing or decreasing the value of a number by 1. Then there is the assignment operator (=) which is used to set the value of a variable, regardless of type. I also introduced concatenation (.), for appending one string to another.

These are all handy for establishing the value of a variable but they are not of much use when it comes to conditionals. Now you will explore comparison and logical operators for working with conditionals.

I l @ ve RuBoard


PHP for the World Wide Web (Visual QuickStart Guide)
PHP for the World Wide Web (Visual QuickStart Guide)
ISBN: 0201727870
EAN: 2147483647
Year: 2001
Pages: 116
Authors: Larry Ullman

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net