You think you can answer few questions about programing languages? How about very specific questions? The following quizzes are made to test your knowledge. As always, i is just for fun and no data will be stored by sanuja.com. Feel free to report any errors. Currently only the PHP, MySQL, CSS and HTML quizzes are up. Expect to see more before September 2013.
PHP and MySQL Quiz
Congratulations - you have completed PHP and MySQL Quiz.
You scored %%SCORE%% out of %%TOTAL%%.
Your performance has been rated as %%RATING%%
Question 1 |
A | Yes, but both websites MUST share the same database files. |
B | No for Windows based servers, but this can be done on a Linux or Unix server. For Windows, each site must have their own install of PHP. |
C | No, each website will get it's own set of PHP databases and the PHP install must be independent of each other. |
D | Yes, as long as each website have the access to the install. |
Question 2 |
A | GB Library |
B | GD Library |
C | PHP-img Library |
D | GU Library |
Question 3 |
mail(V, W, X, Y, X)
A | At position Z |
B | At position X |
C | At position W |
D | At position V |
E | At position Y |
Question 4 |
A | _.php |
B | php.exe |
C | FileName.php |
D | php.ini |
Question 5 |
A | print() |
B | str() |
C | strings() |
D | echo() |
E | command() |
Question 6 |
A | mysqli_affected_rows() |
B | mysqli():affected_rows() |
C | mysql_affected_rows() Hint: Uh... this is the old one! Oops! |
D | mysql():affected_rows() |
Question 7 |
/*
.A | False |
B | True |
Question 8 |
A | No, it can only be installed on Windows Servers with IIS support. |
B | Yes, it can be installed on Unix, Linux, Apple and Windows operating systems. |
C | No, it can be installed on any server, but cannot be installed on non-server units. |
D | No, it can only be installed on Linux servers. |
Question 9 |
A | This is not a valid PHP function. |
B | It is used to pass the information from previous function to the next known as "r". |
C | It is the human-readable information print out. |
D | It prints out the program's out come for input of the next. |
Question 10 |
A | The start and end should have ?php and ? tags |
B | There is no output command for the operation hence the script is useless. |
C | The commenting tags /* and */ are in backwards order. |
D | The "php" at the start should be capitalized to "PHP" |
Question 11 |
A | MySQL database attacks |
B | source code attacks |
C | injections |
D | force loads |
Question 12 |
A | Preloaded Hypertext Programming |
B | Hypertext Preprocessor |
C | Processed Hypertext Prone |
D | Preconfigured Hypertext Programming |
Question 13 |
A | imagesy() |
B | imagesx() |
C | imageswidth() |
D | imagesw() |
Question 14 |
A | False |
B | True |
Question 15 |
A | 1 |
B | 5 |
C | 2 |
D | Unlimited |
Question 16 |
A | C# |
B | Ruby |
C | Java |
D | HTML |
Question 17 |
A | Using a for or a while loops. |
B | function.login() |
C | check.login() |
D | Using a if condition. |
Question 18 |
A | No |
B | Yes |
Question 19 |
A | True, but ONLY for mobile devices. |
B | True, because PHP requires a plugin much like Flash or Java on the client computer. |
C | False, PHP is a server side processing language with no end user plugins. |
D | False, the plugin for PHP will be automatically installed when the client unit access a PHP based site. |
Question 20 |
A | capital letters |
B | mix of simple and capital letters |
C | numbers |
D | white space |
Question 21 |
$LoveJam=fopen("sanuja.txt","r");
A | It opens the file sanuja.text and enters LoveJam as a variable code. |
B | It opens the file sanuja.text in read only mode. |
C | It opens the file sanuja.text and enters LoveJam as a text string. |
D | It opens the file sanuja.text and assign it to variable fopen. |
Question 22 |
$name = "Sanuja Senanayake";
Is it a valid variable name?
A | No, because you cannot use an undefined arbitrary words in variables. PHP won't known what is Sanuja Senanayake. |
B | Yes, but it is a print statement, not a variable. |
C | Yes |
D | No, because you cannot have white space (space) inside a variable name |
Question 23 |
A | MySQL is a free database program. |
B | MySQL was developed and supported by Oracle Corporation. |
C | MySQL can be used on both small and large scale databases. |
D | MySQL can be installed on Windows, Linux and Unix servers. |
E | MySQL cannot support standard SQL. |
Question 24 |
$sanuja=mysqli_connect("I","II","III","IV");
A | host and database |
B | database and host |
C | database and password |
D | host and username |
E | username and password |
Question 25 |
A | VisualBasic |
B | Java |
C | C# |
D | ASP.net |
Question 26 |
$sanuja=mysqli_connect("I","II","III","IV");
A | at I and IV |
B | at I and II |
C | at III and IV |
D | at II and III |
Question 27 |
$cars=array("Volvo","BMW","Toyota");
echo "I like " . $cars[0] . ", " . $cars[1] . " and " . $cars[2] . ".";
A | loop |
B | condition |
C | array |
D | data set |
Question 28 |
A | [...] |
B | $ |
C | € |
D | {...} |
Question 29 |
A | True |
B | False |
Question 30 |
A | False |
B | True |
← |
List |
→ |
1 | 2 | 3 | 4 | 5 |
6 | 7 | 8 | 9 | 10 |
11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 |
21 | 22 | 23 | 24 | 25 |
26 | 27 | 28 | 29 | 30 |
End |
CSS and HTML Quiz
Congratulations - you have completed CSS and HTML Quiz.
You scored %%SCORE%% out of %%TOTAL%%.
Your performance has been rated as %%RATING%%
Question 1 |
A | They are the same. They create a new paragraph. |
B | They are different. The br tag creates a new paragraph while the p tag creates a new line. |
C | They are different. The br tag creates a new line and p tag creates a new paragraph. |
D | They are the same. They move the data to the next line. |
Question 2 |
A | Cascading Style Sheets |
B | Cheat Style Sheets |
C | Computer Style Sheets |
D | Casting Style Sheets |
Question 3 |
A | They are identical and will behave the same. |
B | First one is used to control all elements with id=sanuja. Second one is used to control a single element with class=sanuja |
C | The first one is used to control an element name "sanuja". The second one is an invalid code in CSS. |
D | The second one is no longer in use. All current (as of MAY-2013) versions of CSS use "dot" version |
Question 4 |
A | em |
B | br |
C | ita |
D | ty |
Question 5 |
A | / |
B | & |
C | ? |
D | : |
E | % |
Question 6 |
A | 1 |
B | 4 |
C | 2 |
D | 3 |
Question 7 |
A | True |
B | False |
Question 8 |
A | ...it is a server side programming language. |
B | ...a single style sheet can be loaded for all subsequent pages. |
C | ...it can take over heavy loads off of MySQL databases. |
D | ...it can take over some of the php.ini functions. |
Question 9 |
A | CSS |
B | MySQL |
C | PHP |
D | JavaScript |
E | HTML |
Question 10 |
A | text-wrap:black; |
B | white-space:nowrap; |
C | white-space:blank; |
D | wrap:none; |
Question 11 |
(Without creating a separate style sheet.)
A | .WHAT_EVER_CODE_ELEMENT_TO_BE_MOD .POST_ID {
VARIABLE:ACTION;
} |
B | .WHAT_EVER_CODE_ELEMENT_TO_BE_MOD {
VARIABLE:ACTION;
POST_ID
} |
C | .WHAT_EVER_CODE_ELEMENT_TO_BE_MOD {
POST_ID
VARIABLE:ACTION;
} |
D | .POST_ID .WHAT_EVER_CODE_ELEMENT_TO_BE_MOD {
VARIABLE:ACTION;
} |
Question 12 |
A | Yes |
B | No |
This is a title heading.
Question 13 |
A | always! |
B | primary! |
C | dominate! |
D | important! |
Question 14 |
A | By using the @import url("file_url_here") in one of the .css files. |
B | By saving both files with the same name but one of them as .css and the other as .css2 extinctions. |
C | By using the $css_file("file_url_here') in one of the .css files. |
D | By using functions_css("file_url_here") at the top of the .php file. |
E | You cannot combine two different style sheets. |
Question 15 |
A | Hash Text Markup Language |
B | Hyper Text Markup Language |
C | Hyperlinks and Text Markup Language |
D | Hash Tag Markup Language |
Question 16 |
A | Yes |
B | No |
← |
List |
→ |
1 | 2 | 3 | 4 | 5 |
6 | 7 | 8 | 9 | 10 |
11 | 12 | 13 | 14 | 15 |
16 | End |