| Definition | example (Code) | pitfalls | |
| variable | variable are used to store information. | This is a variable being called with php | Make sure to put the dollar sign |
| Definition | example (Code) | pitfalls | |
| Strings | a string stores and manupulates text | This phrase is being echoed This phrase is being printed single quotes double quotes |
aslo starts with dollar sign |
| Definition | example (Code) | pitfalls | |
| PHP code block | Blocks the browser from reading the code | //, /**/ | make sure not to block code that is needed |
| Definition | example (Code) | pitfalls | |
| Array - Associative | each ID key is associated with a value. | The hometown array says that jane lives in Monteview. | make sure the associated value is what you planned for. |
| Definition | example (Code) | pitfalls | |
| Array - Numeric | each ID key is associated with a value. | This numeric array says that I am 21. | make sure the value is what you planned for. |
| Definition | example (Code) | pitfalls | |
| Array - Multidemensional | an array that multiple arrays | This Multidemensional array says that I was born 1989-09-16. | make sure the value is what you planned for. |
| Definition | example (Code) | pitfalls | |
| Operators - Assignment | to return values after gven values | Addition 7 Subtraction 3 Division 2.5 multiplication 10 |
Do the math right it might be a good idea to use excel befoe implimenting into the php page. |
| Definition | example (Code) | pitfalls | |
| Comparison Operators | To test something | This is a test of an index if the numbers are equal. Index 3 and 4 are the same. This is a test of an index if the numbers are not equal. The indexs that are being comapred are not the same. This is a test if a number is less than 100. The number is smaller than 100. This is a test if a number is greater than 10. The number is larger than 10. This is a test if a number is less than or equal to 100. The number is smaller than 100. This is a test if a number is greater than or equal to 10. The number is larger than 10. |
Do the math right it might be a good idea to use excel befoe implimenting into the php page. |
Logical Operators |
Definition | example | pitfalls and requirements | ||
|---|---|---|---|---|---|
| &, And | both tests are true then it responds true |
|
|||
| ||, Or | two statements on of the statements can be true and it will return true | x=6 y=3 (x==5 || y==5) returns false |
|||
| ! and Not | if none of the statements are true then it will return true | x=5 y=1 !(x==y) returns true |
|||
| Reference | http://www.w3schools.com/php/php_operators.asp |
| Definition | example | pitfalls | |
| Conditional Statements | Conditional statements are used to perform different actions based on different conditions. | if($age[3] > 10){$greater = '<b>The number is larger than 10.</b>';} switch ($x) |
Do the math right it might be a good idea to use excel befoe implimenting into the php page. |
| Definition | examples | pitfalls | |
| Loops | They execute a block of code a number of times. The loops can be counted if you want. They are the workhorse of php | $count = 1; foreach ($agearray as $age){
$i=1; |
Make sure to know how many times to loop the file it might stall the browser if loops to many times |
Reference = http://www.w3schools.com/php/php_looping.asp