Variable names given to location in the memory.These locations can contain integer,real or character contains.
Rules for variable names—-
A variable name is any combination of 1 to 26 alphabets, digits or underscores.
- This first character in the variable name must be an alphabet or underscore.
- Some valid variable names are:$ss, $s_s, $_1213 etc.
- No commas or blanks are allowed within a variable name.
PHP lets you store numbers and text to those variables, as in these examples:
$pi = 3.1514444; $number_of_jupiters = 1; $name = "rahul kumar"; $fish = "haddock"; $pi,$number_of_jupiters,$name and $fish is PHP variable name.