SUBJECTS
|
BROWSE
|
CAREER CENTER
|
POPULAR
|
JOIN
|
LOGIN
Business Skills
|
Soft Skills
|
Basic Literacy
|
Certifications
About
|
Help
|
Privacy
|
Terms
|
Email
Search
Test your basic knowledge |
Php Programming Basics
Start Test
Study First
Subject
:
it-skills
Instructions:
Answer 50 questions in 15 minutes.
If you are not ready to take this test, you can
study here
.
Match each statement with the correct term.
Don't refresh. All questions and answers are randomly picked and ordered every time you load a test.
This is a study tool. The 3 wrong answers for each question are randomly chosen from answers to other questions. So, you might find at times the answers obvious, but you will see it re-enforces your understanding as you take the test each time.
1. The seven main SQL (structured query language) functions are alter - create - delete - _______ - insert - select - update
if/elseif/else and switch statements
function
double quotes
drop
2. Predefined constants such as __LINE__ or __FILE__ or __FUNCTION__ or __CLASS__ and __METHOD__
Magic Constant
empty()
sort()
arsort()
3. An array whose keys are numbers.
curly braces; ${$total}
indexed array
Error
HTML
4. Besides GET and POST ________ can be used to access data but $_POST and $_GET are more precise and therefore preferable.
HTML
double quotes
$_REQUEST
control structure
5. The prefix for a dynamic variable - also known as a variable variable
$$
htmlspecialchars()
E_STRICT
parentheses
6. Use _______ for passwords or pages that would not be bookmarked or pages that require security.
numbers
$array[] = item
negative numbers
POST
7. Converts a string of ASCII characters to hexadecimal values
string
getrandmax()
negative numbers
bin2hex()
8. a line of information that can be stored in a variable or used in a function or statement
>>
string
define()
empty()
9. An array of variables passed in the URL
$_GET[]
Array
str_ireplace()
preg_split()
10. To reset an array _______ the array() function to the array
array()
Array
parentheses
reassign
11. returns the number of matches found by a given search string under this format...
general
error_reporting (E_ALL | E_STRICT)
preg_match()
double quotes
12. A conditional or loop is a ________________.
echo
control structure
E_STRICT
predefined
13. leading zero: 0100 or 0567
unset()
$varname[key]
octal
POST
14. PHP has two conditional: if and ______.
.=
string
switch
Notice
15. bitwise AND
Shebang
&
chr()
str_ireplace()
16. $_SERVER is a ________ variable.
predefined
empty()
preg_split()
str_ireplace()
17. To refer to an element in a multidimensional array list the indices in order of _____ to more precise;
general
preg_match()
>>
Hex
18. Hypertext Preprocessor - a server-side programing language used to create webpages
!= inequality
PHP
string
SEO
19. used to round numeric values.
round() Function
function
indexed array
count()
20. To assign array element values to individual variables
GET
list()
HTTP
numbers
21. Hyper Text Markup Language
addslashes()
$_REQUEST
HTML
error_reporting (0)
22. identity
ksort()
===
function
AJAX
23. Used to encrypt values - it is a one-way encryption method
array()
crypt()
statement
ini_set ('display_errors', 1)
24. Use ________ to have multiple quotations in one string
the escape character ''
mysql_close($dbc)
>>
index
25. standard notation
SEO
decimal
Parse error
fopen()
26. Hyper Text Transfer Protocol
precedence
html_entity_decode()
HTTP
addslashes()
27. Used to check if a given variable has an "empty" value - no value or 0 or FALSE.
empty()
if/elseif/else and switch statements
XML
chop()
28. The concatenation assignment operator?
+
boolean
Constant
.=
29. The three types of loops in PHP are: for - while - ____.
foreach
error_reporting (0)
POST
shuffle()
30. To word wrap after a certain amount of characters.
+= or -= or *= or /=
wordwrap()
addcslashes()
$_SESSION[]
31. Used to find the amount of words in a string.
str_word_count()
$dbc = mysql_connect(hostname, username, password)
Hex
server-side programing
32. equivalence
$var++ and $var
list()
==
htmlspecialchars()
33. To assign keys to the values in an array
predefined
switch
$array[] = item
array()
34. Use ______ for search engines or catalogued pages or pages that would be bookmarked.
curly braces; ${$total}
GET
boolean
abs()
35. collection of binary data
&
1
AJAX
string
36. Used to find the length of a string
date()
wordwrap()
strlen()
not
37. To sort the values while maintaining the correlation between each value and its key - in reversed order
wordwrap()
!= inequality
negative numbers
arsort()
38. To merge arrays
echo
array_merge()
list()
statement
39. This will not show error reporting - it will be turned off.
ksort()
strip_tags()
error_reporting (0)
!= inequality
40. To refer to an item in an array
mysql_fetch_array()
$varname[key]
array_merge()
array()
41. a database which is best supported by PHP
array()
<<
single quotes
mysql
42. Used to replace a substring with another string - it is not case-sensitive.
E_STRICT
str_ireplace()
array
strip_tags()
43. Search Engine Optimization
rand()
open source
empty()
SEO
44. To iterate over the values of an array
curly braces; ${$total}
abs()
for ($i = 0; $i < count($array); $i++) {statement(s);}
the dollar sign $
45. says 'if' this then do this 'else' do this or 'while' this do this
function error_reporting()
error_reporting (0)
statement
Parse error
46. Function used to convert new lines in a variable from a form to <br /> tags so that the data can be formatted correctly.
PHP
Constant
nl2br()
!= inequality
47. To set up error reporting
null
decimal
date()
function error_reporting()
48. signed floating-point value
date()
float
urlencode()
Object
49. a storage location in the computer's memory that has a type & a name and a contents
$var++ and $var
variable
Parse error
>>
50. Standard Generalized Markup Language
true
is_numeric()
SGML
number_format()