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. The three types of loops in PHP are: for - while - ____.
open source
foreach
error_reporting (E_ALL)
floor()
2. To remove all HTML and PHP tags.
HTTP
echo
strtok()
strip_tags()
3. a storage location in the computer's memory that has a type & a name and a contents
nl2br()
+= or -= or *= or /=
getrandmax()
variable
4. To include files - _______ will give errors and _________ will terminate execution().
preg_replace()
ASP
include() and require()
not
5. To counter htmlentities()
trim()
html_entity_decode()
sort()
ksort()
6. Hyper Text Markup Language
chr()
<<
HTML
defined()
7. This fatal error arises from memory allocation problem.
htmlspecialchars()
shuffle()
Error
decimal
8. Use ______ for search engines or catalogued pages or pages that would be bookmarked.
Notice
bin2hex()
not
GET
9. bitwise right shift
superglobal
general
defined()
>>
10. This error refers to a variable with no value.
Notice
predefined
unset()
HTTP
11. To sort values of an array without regard to the keys
arsort()
html_entity_decode()
date()
sort()
12. To sort by the keys while maintaining the correlation between the key and its value
ksort()
crypt()
Hex
round() Function
13. function Function used to create a random number
mysql_fetch_array()
curly braces
rand()
integer
14. searches the subject for matches to a given pattern replaced with the given replacement text
str_word_count()
preg_replace()
Object
mysql_close($dbc)
15. Variable names can begin with __________
error_reporting (0)
htmlspecialchars()
0
underscores
16. Used to find the amount of words in a string.
predefined
str_word_count()
open source
string
17. Control structure that continue exit - they perform specific statements for a determined number of iterations.
loops
if/elseif/else and switch statements
str_word_count()
SGML
18. $_POST and $_GET are ________ variables.
underscores
predefined
string
Parse error
19. 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
20. To sort the values while maintaining the correlation between each value and its key
Constant
switch
true
asort()
21. a language in which to make querys to a database with
array
loops
sql
open source
22. print $_SERVER will _____ work if you use the print function on arrays.
not
preg_match()
for ($i = 0; $i < count($array); $i++) {statement(s);}
$var++ and $var
23. leading zero: 0100 or 0567
sort()
POST
octal
strlen()
24. used to round numeric values.
int
Error
nl2br()
round() Function
25. To assign keys to the values in an array
array()
error_reporting (E_ALL | E_STRICT)
error_reporting (0)
mysql
26. Online applications and resources which are available to the general public with very few restrictions
open source
indexed array
the dollar sign $
switch
27. The output of var_export((float)array());
0
index
associative array
curly braces; ${$total}
28. Hypertext Preprocessor - a server-side programing language used to create webpages
numbers
not
PHP
for ($i = 0; $i < count($array); $i++) {statement(s);}
29. Use _______ for passwords or pages that would not be bookmarked or pages that require security.
+= or -= or *= or /=
string
associative array
POST
30. An array of variables passed with <input /> data
^
addcslashes()
$_POST[]
SGML
31. To word wrap after a certain amount of characters.
variable
htmlspecialchars()
array
wordwrap()
32. The four main error types are:Notice - Warning - ________ and Error.
underscores
Parse error
indexed array
true
33. 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 __________.
superglobal
curly braces; ${$total}
true
Array
34. Use ______ when there are no variables in the string
indexed array
DTD
single quotes
boolean
35. Search Engine Optimization
number_format()
superglobal
SEO
underscores
36. Used to check if a variable has any value (including 0 or FALSE or an empty string).
statement
str_word_count()
the escape character ''
isset()
37. Used to convert certain HTML tags into their entity versions.
ini_set ('display_errors', 1)
trim()
array
htmlspecialchars()
38. An array whose keys are strings; also known as a hash.
$_REQUEST
strtok()
associative array
chop()
39. Used to create a substring (referred to as a token) from a larger string
getrandmax()
strtok()
isset()
octal
40. any programing language where the script is parsed on the server
drop
crypt()
.=
server-side programing
41. Function that contains the highest value that rand() can have randomly
getrandmax()
unset()
XML
octal
42. Function can you use to format a number with commas
floor()
number_format()
count()
==
43. Standard Generalized Markup Language
^
not
POST
SGML
44. identity
&
preg_replace()
===
?>
45. Function used to convert new lines in a variable from a form to <br /> tags so that the data can be formatted correctly.
$_GET[]
nl2br()
error_reporting (E_ALL)
index
46. Asynchronous Javascript And XML
indexed array
nl2br()
AJAX
wordwrap()
47. Alias of rtrim()
reassign
switch
str_word_count()
chop()
48. Leading 0x: 0x13F or 0xA23
Hex
error_reporting (0)
$_SESSION[]
$$
49. EXtensible Markup Language
array
strtok()
XML
define()
50. a line of information that can be stored in a variable or used in a function or statement
null
string
XML
single quotes