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. To refer to an item in an array
$varname[key]
index
isset()
$_GET[]
2. Used to check if a given variable has an "empty" value - no value or 0 or FALSE.
$dbc = mysql_connect(hostname, username, password)
SGML
<?php
empty()
3. The three types of loops in PHP are: for - while - ____.
array
&
round() Function
foreach
4. To reorganise the array randomly
shuffle()
>>
+
strlen()
5. a positive or negative number
$dbc = mysql_connect(hostname, username, password)
list()
unset()
integer
6. The concatenation assignment operator?
$$
$_REQUEST
mysql
.=
7. The array that stores variables specific to a user's visit
Magic Constant
$_SESSION[]
not
the period; .
8. To assign keys to the values in an array
array()
rsort()
the escape character ''
preg_split()
9. Function used to convert new lines in a variable from a form to <br /> tags so that the data can be formatted correctly.
nl2br()
$_SESSION[]
curly braces
fopen()
10. To determine the amount of elements in an array
fopen()
Object
error_reporting (0)
count()
11. Use ________ to have multiple quotations in one string
str_word_count()
mysql_fetch_array()
the escape character ''
mysql_close($dbc)
12. A conditional or loop is a ________________.
!= inequality
control structure
getrandmax()
==
13. The seven main SQL (structured query language) functions are alter - create - delete - _______ - insert - select - update
precedence
drop
error_reporting (E_ALL | E_STRICT)
&
14. Used to check if a variable has any value (including 0 or FALSE or an empty string).
error_reporting (E_ALL & -E_NOTICE)
unset()
count()
isset()
15. a line of information that can be stored in a variable or used in a function or statement
string
the escape character ''
Parse error
ASP
16. To remove all HTML and PHP tags.
strip_tags()
variable
octal
$array[] = item
17. a database which is best supported by PHP
?>
error_reporting (E_ALL & -E_NOTICE)
mysql
predefined
18. Leading 0x: 0x13F or 0xA23
server-side programing
mysql_fetch_array()
Hex
unset()
19. Alias of rtrim()
html_entity_decode()
chop()
Warning
the dollar sign $
20. What You See Is What You Get
not
$_GET[]
WYSIWYG
numbers
21. EXtensible Markup Language
!= inequality
preg_split()
float
XML
22. To sort values of an array without regard to the keys
mysql
variable
Constant
sort()
23. a language in which to make querys to a database with
sql
XML
indexed array
octal
24. Tag to begin a php script
==
<?php
$_REQUEST
associative array
25. used to round numeric values.
addcslashes()
!= inequality
round() Function
getrandmax()
26. Besides GET and POST ________ can be used to access data but $_POST and $_GET are more precise and therefore preferable.
integer
count()
$_REQUEST
parentheses
27. Uses two arguments: constant name and constant definition
single quotes
1
Hex
define()
28. Returns an array that corresponds to the fetched row of MySQL data and moves the internal data pointer ahead
mysql_fetch_array()
XOR
true
1
29. Search Engine Optimization
foreach
chr()
==
SEO
30. Used to convert certain HTML tags into their entity versions.
server-side programing
$dbc = mysql_connect(hostname, username, password)
shuffle()
htmlspecialchars()
31. Standard Generalized Markup Language
getrandmax()
SGML
precedence
nl2br()
32. To sort values of an array in reversed order
0
rsort()
mysql
Array
33. Use ______ when a variable contains any amount of variables; in general.
double quotes
abs()
rand()
associative array
34. Used to encrypt values - it is a one-way encryption method
reassign
double quotes
crypt()
Error
35. either hasn't yet been set or is assigned NULL value
Parse error
crypt()
>>
null
36. To refer to an element in a multidimensional array list the indices in order of _____ to more precise;
include() and require()
general
function
array_merge()
37. $_SERVER - $_POST - $_GET - $_COOKIE - $_SESSION - $_ENV; special arrays.
$_POST[]
trim()
strip_tags()
superglobal
38. This fatal fatal is caused by a semantic mistake: omission of a semicolon or imbalance of quotations or parentheses or braces.
$_GET[]
shuffle()
Parse error
$array[] = item
39. signed floating-point value
float
AJAX
wordwrap()
not
40. The order of operations.
negative numbers
mysql_fetch_array()
precedence
predefined
41. Variable names can begin with __________
underscores
.=
isset()
error_reporting (0)
42. To sort by the keys while maintaining the correlation between the key and its value
ini_set ('display_errors', 1)
for ($i = 0; $i < count($array); $i++) {statement(s);}
ksort()
asort()
43. To merge arrays
+
unset()
array_merge()
parentheses
44. Used to remove any white space - spaces or newlines or tabs - from the beginning and end of a string - not the middle.
variable
fopen()
trim()
str_word_count()
45. leading zero: 0100 or 0567
==
decimal
octal
not
46. Function used to find the absolute value of a number or numeric variable
==
Hex
parentheses
abs()
47. Control structure that continue exit - they perform specific statements for a determined number of iterations.
parentheses
$var++ and $var
loops
date()
48. bitwise XOR
negative numbers
$$
^
chr()
49. Similar to mysql_fetch_array() - but cannot be accessed by integer offset
array()
echo
mysql_fetch_object()
GET
50. Use ______ for search engines or catalogued pages or pages that would be bookmarked.
abs()
floor()
Object
GET