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. any programing language where the user must support the language the script is written in
client-side programing
Hex
statement
include() and require()
2. Predefined constants such as __LINE__ or __FILE__ or __FUNCTION__ or __CLASS__ and __METHOD__
strlen()
^
Magic Constant
curly braces; ${$total}
3. Hyper Text Markup Language
crypt()
defined()
HTML
ceil()
4. Control structure that continue exit - they perform specific statements for a determined number of iterations.
foreach
boolean
loops
urlencode()
5. Variable names can begin with __________
underscores
WYSIWYG
error_reporting (0)
for ($i = 0; $i < count($array); $i++) {statement(s);}
6. searches the subject for matches to a given pattern replaced with the given replacement text
bin2hex()
variable
str_ireplace()
preg_replace()
7. allows you to split strings based on more complex rules
str_word_count()
strip_tags()
floor()
preg_split()
8. says 'if' this then do this 'else' do this or 'while' this do this
control structure
statement
$_REQUEST
urlencode()
9. TRUE or FALSE
boolean
$var++ and $var
indexed array
Error
10. Function used to convert new lines in a variable from a form to <br /> tags so that the data can be formatted correctly.
Notice
nl2br()
is_numeric()
mysql_fetch_array()
11. Returns a string with backslashes in front of the specified characters
define()
addcslashes()
predefined
^
12. leading zero: 0100 or 0567
addslashes()
+= or -= or *= or /=
error_reporting (E_ALL | E_STRICT)
octal
13. Document Type Definitions
wordwrap()
urlencode()
htmlspecialchars()
DTD
14. To create an array
array()
true
foreach
DTD
15. To counter htmlentities()
html_entity_decode()
server-side programing
curly braces
number_format()
16. To merge arrays
$dbc = mysql_connect(hostname, username, password)
GET
array_merge()
variable
17. Returns an array that corresponds to the fetched row of MySQL data and moves the internal data pointer ahead
mysql_fetch_array()
strtok()
the dollar sign $
SEO
18. To set up error reporting
include() and require()
octal
function error_reporting()
echo
19. Besides GET and POST ________ can be used to access data but $_POST and $_GET are more precise and therefore preferable.
indexed array
$_REQUEST
$varname[key]
general
20. $_POST and $_GET are ________ variables.
floor()
string
predefined
int
21. This fatal error arises from memory allocation problem.
Error
sql
rand()
wordwrap()
22. The concatenation operator?
!= inequality
the period; .
Shebang
asort()
23. When used the value can be passed safely through the URL (GET).
urlencode()
include() and require()
WYSIWYG
getrandmax()
24. To close a connection between a database
mysql_close($dbc)
array()
SEO
define()
25. 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
26. container of ordered data elements
trim()
Array
boolean
negative numbers
27. any programing language where the script is parsed on the server
chop()
associative array
server-side programing
client-side programing
28. Operators used to operate and assign
&
integer
AJAX
+= or -= or *= or /=
29. The four main error types are:Notice - Warning - ________ and Error.
html_entity_decode()
preg_match()
integer
Parse error
30. This will not show error reporting - it will be turned off.
error_reporting (0)
predefined variable
statement
array
31. EXtensible Markup Language
HTML
XML
Parse error
mysql_close($dbc)
32. a language in which to make querys to a database with
&
Magic Constant
round() Function
sql
33. To reorganise the array randomly
error_reporting (E_ALL | E_STRICT)
preg_match()
strip_tags()
shuffle()
34. To refer to an element in a multidimensional array list the indices in order of _____ to more precise;
$_REQUEST
ASP
error_reporting (E_ALL)
general
35. Creates a pointer to a file with the declared mode (read - write -etc.).
fopen()
array()
XOR
asort()
36. What You See Is What You Get
AJAX
?>
WYSIWYG
variable
37. To sort the values while maintaining the correlation between each value and its key - in reversed order
bin2hex()
wordwrap()
associative array
arsort()
38. Use ________ to have multiple quotations in one string
strip_tags()
?>
WYSIWYG
the escape character ''
39. To assign array element values to individual variables
!= inequality
list()
AJAX
rsort()
40. Returns a string with backslashes in front of predefined characters
addslashes()
addcslashes()
if/elseif/else and switch statements
drop
41. Search Engine Optimization
$_GET[]
Notice
SEO
wordwrap()
42. Uses two arguments: constant name and constant definition
switch
error_reporting (E_ALL & -E_NOTICE)
define()
decimal
43. Control structures that break exit
if/elseif/else and switch statements
mysql_fetch_array()
array()
<<
44. To refer to an item in an array
$varname[key]
ksort()
crypt()
===
45. equivalence
Array
==
round() Function
crypt()
46. Asynchronous Javascript And XML
error_reporting (E_ALL & -E_NOTICE)
ini_set ('display_errors', 1)
AJAX
0
47. Used to check if a variable has any value (including 0 or FALSE or an empty string).
mysql_fetch_array()
isset()
$dbc = mysql_connect(hostname, username, password)
sort()
48. container of both data and code
Object
strip_tags()
index
control structure
49. The syntax for connecting to a database
ASP
$_REQUEST
$dbc = mysql_connect(hostname, username, password)
round() Function
50. Used to check if a variable has a valid numerical value; strings with numerical values pass.
?>
octal
is_numeric()
round() Function