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 merge arrays
string
rsort()
array_merge()
mysql_close($dbc)
2. Used to replace a substring with another string - it is not case-sensitive.
negative numbers
str_ireplace()
array
chop()
3. signed integer
strip_tags()
int
null
statement
4. To declare a constant
chop()
htmlentities()
define()
function error_reporting()
5. Hyper Text Transfer Protocol
HTTP
rsort()
underscores
preg_match()
6. An array of variables passed in the URL
foreach
$_GET[]
float
PHP
7. Search Engine Optimization
ASP
SEO
<<
predefined
8. allows you to split strings based on more complex rules
array()
rsort()
the period; .
preg_split()
9. The four main error types are:Notice - Warning - ________ and Error.
$dbc = mysql_connect(hostname, username, password)
true
chop()
Parse error
10. Returns a string with backslashes in front of the specified characters
open source
addcslashes()
array_merge()
Shebang
11. Use ______ when there are no variables in the string
function error_reporting()
boolean
addslashes()
single quotes
12. To sort the values while maintaining the correlation between each value and its key - in reversed order
associative array
preg_split()
arsort()
foreach
13. Variable names cannot begin with _______
sort()
numbers
strtok()
chop()
14. To sort values of an array without regard to the keys
include() and require()
error_reporting (E_ALL & -E_NOTICE)
Error
sort()
15. Control structures that break exit
if/elseif/else and switch statements
list()
ASP
server-side programing
16. Returns a string with backslashes in front of predefined characters
general
addslashes()
$_POST[]
Object
17. All variables must begin with _________.
the dollar sign $
str_ireplace()
strip_tags()
integer
18. used to round numeric values.
decimal
HTML
round() Function
string
19. This fatal error arises from memory allocation problem.
Error
mysql_close($dbc)
sort()
Magic Constant
20. To create an array
urlencode()
array
array()
client-side programing
21. The name of the #! used to designate the location of the PHP binary
Shebang
array_merge()
variable
DTD
22. This will not show error reporting - it will be turned off.
error_reporting (0)
Constant
SGML
==
23. To include files - _______ will give errors and _________ will terminate execution().
abs()
include() and require()
client-side programing
urlencode()
24. Control structure that continue exit - they perform specific statements for a determined number of iterations.
loops
double quotes
$_REQUEST
==
25. The ouput of var_export((bool)"NULL");
nl2br()
true
POST
array
26. does a certain action when called upon
int
function
control structure
$varname[key]
27. A data structure that can hold a number of items of data of the same type eg. a list of names
for ($i = 0; $i < count($array); $i++) {statement(s);}
Notice
array
sort()
28. Standard Generalized Markup Language
include() and require()
SGML
array()
loops
29. This will show all error reporting except for notice errors.
precedence
htmlspecialchars()
error_reporting (E_ALL & -E_NOTICE)
Array
30. The concatenation operator?
E_STRICT
strlen()
the period; .
double quotes
31. standard notation
integer
decimal
$var++ and $var
html_entity_decode()
32. To assign array element values to individual variables
parentheses
htmlentities()
list()
mysql_fetch_object()
33. To refer to an element in a multidimensional array list the indices in order of _____ to more precise;
general
count()
chr()
predefined variable
34. Used to display errors in a particular script - should be placed at top of script.
Warning
: Invalid argument supplied for foreach() in
/var/www/html/basicversity.com/show_quiz.php
on line
183
35. To set up error reporting
foreach loop
function error_reporting()
curly braces; ${$total}
include() and require()
36. a database which is best supported by PHP
array
foreach
mysql
strip_tags()
37. This fatal fatal is caused by a semantic mistake: omission of a semicolon or imbalance of quotations or parentheses or braces.
define()
Parse error
sql
mysql_fetch_object()
38. This will show all errors that fall under E_ALL or E_STRICT - the pipe | is used for 'or' so that errors that fall under either will be shown.
octal
isset()
preg_split()
error_reporting (E_ALL | E_STRICT)
39. To sort by the keys while maintaining the correlation between the key and its value
superglobal
ksort()
1
PHP
40. equivalence
error_reporting (E_ALL | E_STRICT)
==
Parse error
>>
41. collection of binary data
string
POST
strlen()
addslashes()
42. To append elements to an array - this will assign item to the next available index; associative arrays get messy.
$array[] = item
mysql_fetch_array()
count()
error_reporting (E_ALL | E_STRICT)
43. Use ________ to have multiple quotations in one string
the escape character ''
drop
array_merge()
integer
44. The syntax for connecting to a database
$array[] = item
$dbc = mysql_connect(hostname, username, password)
float
server-side programing
45. To refer to an item in an array
mysql_fetch_object()
AJAX
$varname[key]
predefined variable
46. Use ______ when a variable contains any amount of variables; in general.
Array
underscores
double quotes
bin2hex()
47. function Function used to create a random number
associative array
rsort()
rand()
floor()
48. _______ is a comparison operator
for ($i = 0; $i < count($array); $i++) {statement(s);}
!= inequality
crypt()
is_numeric()
49. returns the number of matches found by a given search string under this format...
GET
define()
float
preg_match()
50. The concatenation assignment operator?
.=
abs()
XML
the period; .