SUBJECTS
|
BROWSE
|
CAREER CENTER
|
POPULAR
|
JOIN
|
LOGIN
Business Skills
|
Soft Skills
|
Basic Literacy
|
Certifications
About
|
Help
|
Privacy
|
Terms
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. $_POST Data sent using POST found is sent to _______
predefined variable
the period; .
Array
foreach loop
2. Leading 0x: 0x13F or 0xA23
boolean
Hex
isset()
array
3. _______ is a comparison operator
?>
1
!= inequality
Array
4. To sort values of an array without regard to the keys
wordwrap()
.=
sort()
decimal
5. Used to convert certain HTML tags into their entity versions.
sort()
decimal
chr()
htmlspecialchars()
6. The seven main error reporting constants are: E_NOTICE - E_WARNING - E_PARSE - E_ERROR - E_ALL - _____ - E_DEPRECATED
control structure
E_STRICT
index
count()
7. To iterate over the values of an array
&
strlen()
chr()
for ($i = 0; $i < count($array); $i++) {statement(s);}
8. The concatenation assignment operator?
.=
not
count()
Parse error
9. The name of the #! used to designate the location of the PHP binary
Shebang
foreach
rand()
$var++ and $var
10. To remove all HTML and PHP tags.
for ($i = 0; $i < count($array); $i++) {statement(s);}
strip_tags()
echo
function error_reporting()
11. bitwise right shift
Array
switch
boolean
>>
12. leading zero: 0100 or 0567
octal
reassign
boolean
curly braces
13. _________ can be used in conditional statements to set precedence
str_word_count()
0
parentheses
client-side programing
14. Creates a pointer to a file with the declared mode (read - write -etc.).
round() Function
negative numbers
fopen()
underscores
15. When used the value can be passed safely through the URL (GET).
ceil()
underscores
define()
urlencode()
16. To refer to an element in a multidimensional array list the indices in order of _____ to more precise;
curly braces
general
Object
the dollar sign $
17. To reset an array _______ the array() function to the array
unset()
<?php
Parse error
reassign
18. a storage location in the computer's memory that has a type & a name and a contents
predefined
variable
parentheses
WYSIWYG
19. Uses two arguments: constant name and constant definition
define()
integer
string
defined()
20. any programing language where the user must support the language the script is written in
list()
strlen()
client-side programing
!= inequality
21. The three types of loops in PHP are: for - while - ____.
foreach loop
empty()
foreach
rand()
22. Function used to round down to the lowest integer
floor()
DTD
include() and require()
mysql
23. This fatal fatal is caused by a semantic mistake: omission of a semicolon or imbalance of quotations or parentheses or braces.
boolean
Constant
Parse error
control structure
24. An array of variables passed in the URL
superglobal
^
the escape character ''
$_GET[]
25. bitwise left shift
<<
function
array()
$_SESSION[]
26. Use _______ for passwords or pages that would not be bookmarked or pages that require security.
error_reporting (E_ALL & -E_NOTICE)
POST
Constant
array_merge()
27. says 'if' this then do this 'else' do this or 'while' this do this
statement
ceil()
parentheses
shuffle()
28. Variable names cannot begin with _______
array
SGML
foreach loop
numbers
29. Hypertext Preprocessor - a server-side programing language used to create webpages
PHP
trim()
null
fopen()
30. To find how many substrings are in a string
array()
urlencode()
single quotes
substr_count()
31. The prefix for a dynamic variable - also known as a variable variable
single quotes
Constant
$$
mysql_close($dbc)
32. Document Type Definitions
ASP
DTD
foreach loop
array_merge()
33. bitwise XOR
^
round() Function
Constant
drop
34. Returns a string with backslashes in front of the specified characters
Shebang
single quotes
preg_split()
addcslashes()
35. To merge arrays
addslashes()
ini_set ('display_errors', 1)
defined()
array_merge()
36. Predefined constants such as __LINE__ or __FILE__ or __FUNCTION__ or __CLASS__ and __METHOD__
Magic Constant
$_GET[]
abs()
<?php
37. allows you to split strings based on more complex rules
parentheses
<<
error_reporting (E_ALL | E_STRICT)
preg_split()
38. either hasn't yet been set or is assigned NULL value
null
unset()
empty()
DTD
39. Active Server Pages
ASP
!= inequality
sql
floor()
40. Returns a character from a specified ASCII value
mysql_close($dbc)
mysql_fetch_array()
chr()
curly braces
41. Control structures that break exit
PHP
rsort()
not
if/elseif/else and switch statements
42. This error refers to a variable with no value.
strip_tags()
+
Notice
true
43. To put a dollar sign before a variable like $10 where 10 is the variable's value - you can escape the first dollar sign; $$cost; or you can use __________.
curly braces; ${$total}
shuffle()
mysql_fetch_array()
if/elseif/else and switch statements
44. addition
associative array
is_numeric()
+
===
45. Returns a string with backslashes in front of predefined characters
Hex
associative array
addslashes()
switch
46. To get time data
date()
nl2br()
Notice
defined()
47. Used to find the amount of words in a string.
reassign
associative array
str_word_count()
unset()
48. A conditional or loop is a ________________.
urlencode()
html_entity_decode()
control structure
statement
49. The array that stores variables specific to a user's visit
list()
sort()
$_SESSION[]
asort()
50. Besides GET and POST ________ can be used to access data but $_POST and $_GET are more precise and therefore preferable.
ceil()
<?php
$_REQUEST
htmlentities()