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. PHP has two conditional: if and ______.
str_word_count()
crypt()
switch
Notice
2. standard notation
str_word_count()
decimal
0
statement
3. The seven main error reporting constants are: E_NOTICE - E_WARNING - E_PARSE - E_ERROR - E_ALL - _____ - E_DEPRECATED
preg_split()
E_STRICT
array()
array
4. Used to check if a variable has a valid numerical value; strings with numerical values pass.
is_numeric()
single quotes
numbers
asort()
5. This error arises from misusing a function.
rand()
$_REQUEST
error_reporting (E_ALL)
Warning
6. To assign keys to the values in an array
array()
floor()
mysql
nl2br()
7. collection of binary data
if/elseif/else and switch statements
string
boolean
DTD
8. Standard Generalized Markup Language
mysql_fetch_object()
chop()
SGML
general
9. 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 __________.
server-side programing
curly braces; ${$total}
echo
abs()
10. Active Server Pages
Object
htmlspecialchars()
ASP
Error
11. Function used to round down to the lowest integer
getrandmax()
floor()
$_SESSION[]
reassign
12. signed floating-point value
defined()
float
preg_replace()
rsort()
13. What You See Is What You Get
$_REQUEST
WYSIWYG
if/elseif/else and switch statements
+= or -= or *= or /=
14. bitwise AND
general
GET
include() and require()
&
15. returns the number of matches found by a given search string under this format...
preg_match()
curly braces
echo
Constant
16. ____ or key is referred to for a value within an array.
string
Warning
index
$varname[key]
17. Variable names can begin with __________
index
underscores
echo
wordwrap()
18. Used to display errors in a particular script - should be placed at top of script.
19. Creates a pointer to a file with the declared mode (read - write -etc.).
==
fopen()
reassign
the period; .
20. The four main error types are:Notice - Warning - ________ and Error.
Parse error
Hex
==
control structure
21. Use _______ for passwords or pages that would not be bookmarked or pages that require security.
curly braces; ${$total}
POST
statement
string
22. Returns a string with backslashes in front of the specified characters
sort()
general
addcslashes()
rsort()
23. Similar to mysql_fetch_array() - but cannot be accessed by integer offset
statement
mysql_fetch_object()
+
error_reporting (E_ALL & -E_NOTICE)
24. Converts a string of ASCII characters to hexadecimal values
===
bin2hex()
Magic Constant
0
25. Search Engine Optimization
.=
$_REQUEST
SEO
DTD
26. Variable names cannot begin with _______
SEO
WYSIWYG
function
numbers
27. _________ can be used in conditional statements to set precedence
+
sort()
parentheses
associative array
28. To find how many substrings are in a string
ini_set ('display_errors', 1)
strtok()
substr_count()
+
29. To iterate over the keys and values of an array
wordwrap()
1
bin2hex()
foreach loop
30. Tag to begin a php script
===
<?php
true
HTML
31. To sort by the keys while maintaining the correlation between the key and its value
trim()
ksort()
!= inequality
is_numeric()
32. All variables must begin with _________.
the dollar sign $
WYSIWYG
error_reporting (E_ALL & -E_NOTICE)
true
33. To include files - _______ will give errors and _________ will terminate execution().
include() and require()
POST
&
the period; .
34. identity
===
parentheses
mysql_close($dbc)
sql
35. To reorganise the array randomly
double quotes
shuffle()
DTD
curly braces; ${$total}
36. An array of variables passed in the URL
addcslashes()
include() and require()
Notice
$_GET[]
37. An array whose keys are strings; also known as a hash.
date()
substr_count()
1
associative array
38. Used to encrypt values - it is a one-way encryption method
crypt()
$$
foreach loop
Object
39. Tag to end a php script
?>
===
chr()
boolean
40. To declare a constant
==
preg_match()
Notice
define()
41. EXtensible Markup Language
floor()
wordwrap()
XML
chr()
42. To word wrap after a certain amount of characters.
wordwrap()
count()
server-side programing
$_GET[]
43. bitwise right shift
associative array
>>
trim()
substr_count()
44. To get over quotation marks while using arrays
unset()
negative numbers
curly braces
html_entity_decode()
45. a storage location in the computer's memory that has a type & a name and a contents
variable
for ($i = 0; $i < count($array); $i++) {statement(s);}
boolean
bin2hex()
46. Hyper Text Markup Language
int
HTML
decimal
associative array
47. a positive or negative number
indexed array
integer
shuffle()
str_ireplace()
48. Asynchronous Javascript And XML
define()
ini_set ('display_errors', 1)
curly braces
AJAX
49. The output of var_export((float)array());
ceil()
mysql_fetch_array()
0
open source
50. To append elements to an array - this will assign item to the next available index; associative arrays get messy.
list()
error_reporting (E_ALL | E_STRICT)
nl2br()
$array[] = item