A sequence of characters, like "Hello world!". It can be any text inside quotes. You can use single or double quotes.
Back
global keyword
Front
used to access a global variable from within a function
Back
array (data type)
Front
stores multiple values in one single variable
Back
variables
Front
containers for storing information
Back
PHP
Front
"PHP: Hypertext Preprocessor," named recursively, is the most common server-side scripting language, allowing a web server to produce a web page "on the fly" based on data provided by the client.
Back
$GLOBALS[index]
Front
PHP also stores all global variables in an array called ______. The index holds the name of the variable. This array is also accessible from within functions and can be used to update global variables directly.
Back
rules for variables
Front
- A variable starts with the $ sign, followed by the name of the variable
- A variable name must start with a letter or the underscore character
- A variable name cannot start with a number
- A variable name can only contain alpha-numeric characters and underscores (A-z, 0-9, and _ )
Variable names are case-sensitive ($age and $AGE are two different variables)
Back
a variable starts with
Front
$ followed by the name of the name of the variable e.g.
<?php$txt = "Hello world!";
$x = 5;
$y = 10.5;?>
Back
<?php
Front
a PHP script starts with
Back
local
global
static
Front
PHP has three different variable scopes:
Back
boolean (data type)
Front
represents a single value of either TRUE or FALSE
Back
float
Front
(floating point number) is a number with a decimal point or a number in exponential form.
Back
.php
Front
the default extension for PHP files is
Back
local scope
Front
A variable declared within a function has a _____ and can only be accessed within that function:
Back
echo and print
Front
the two basic ways to get output in PHP
Back
;
Front
PHP statements end with a
Back
finished up through PHP data types
Front
finished up through PHP data types
Back
print
Front
PHP for "put the following text (or other input) on the screen". has a return value of 1, so it can be used in expressions. an only take one argument. marginally slower than the other basic way to get output.
Back
anywhere
Front
where can a php script be placed in the document?
Back
echo
Front
PHP for "put the following text (or other input) on the screen". has no return value. can take multiple parameters (although such usage is rare). marginally faster than the other basic way to get output.
Back
var_dump() function
Front
this function returns the data type and value
Back
no
Front
In PHP, are keywords (e.g. if, else, while, echo, etc.), classes, functions, and user-defined functions are case-sensitive?
Back
object (data type)
Front
a data type which stores data and information on how to process that data. In PHP, an _____ must be explicitly declared.
Back
yes
Front
are variable names case-sensitive in PHP?
Back
integer (data type)
Front
a non-decimal number between -2,147,483,648 and 2,147,483,647
Back
?>
Front
a PHP script ends with
Back
null
Front
a special data type which can have only one value: ____.
A variable of data type ____ is a variable that has no value assigned to it.
Tip: If a variable is created without a value, it is automatically assigned a value of ____.
Variables can also be emptied by setting the value to ____.
Back
global scope
Front
A variable declared outside a function has a ____________ and can only be accessed outside a function: