PHP TEST 1 QUESTIONS & ANSWERS
A web application is a type of - Answers -client/server application
When the web server receives an HTTP request for a PHP page, the web server calls
the - Answers -web browser
Which of the following software components generates the HTML that is returned in an
HTTP response? - Answers -Chrome
The HTTP response for a dynamic web page is passed - Answers -from the web server
to the browser
Which of the following is NOT true about MariaDB? - Answers -it is being maintained by
many of the original developers of MySQL.
To deploy a PHP application on your own computer, you copy the application root
directory to - Answers -the htdocs directory of the Apache server
Which HTML tag or element is used to load an external stylesheet? - Answers -link
To run a PHP application that has been deployed on your own computer, you can enter
a URL in the address bar of your browser that - Answers -uses localhost as the domain
name
In HTML, parameters are called - Answers -attributes
The first part of a URL is called the - Answers -protocol
Which of the following is NOT part of an HTTP URL: - Answers -node
When HTML was first developed, Web pages were typically - Answers -static
If a URL specifies a directory that doesn't contain a default page, Apache displays -
Answers -a list of all of the directories in that directory
Which of the following is not a database server that can be used for dynamic Web
pages? - Answers -Python
To view the source code for a web page in a web browser, you can display the View
Source command by - Answers -right-clicking on the page
To make it easier to enter names into your code, NetBeans provides a feature known as
- Answers -auto-completion
, URL stands for - Answers -Uniform Resource Locator
A request and response for a file are made by - Answers -a client and a server
What type of a request does a Web browser typically send to a server? - Answers -
HTTP
What extension of a filename is typically associated with a static Web page? - Answers
-.htm
Which of the following can be used to style a label in an id named data? - Answers -
#data label
Which of the following is software that is a Web server? - Answers -Apache
Which of the following can be displayed if you omit the filename of a URL? - Answers -
all of these
A PHP variable name - Answers -is case-sensitive
The order of precedence for arithmetic expressions causes - Answers -increment
operations to be done first
To round and format the value of a variable named $number to 3 decimal places and
store it in a variable named $number_formatted, you code - Answers -
$number_formatted = number_format($number, 3);
After the code that follows is executed, what will the value of $units_per_store be?
$units = 30;
$stores = 4;
$units_per_store = intdiv($units, $stores); - Answers -7
After the code that follows is executed, what will the value of $units_per_store be?
$units = 30;
$stores = 4;
$units_per_store = $units % $stores; - Answers -2
After the if statement that follows is executed, what will the value of $discount_amount
be?
$discount_amount;
$order_total = 200;
if ($order_total > 200) {
$discount_amount = $order_total * .3;
} else if ($order_total > 100) {
$discount_amount = $order_total * .2;
} else {
A web application is a type of - Answers -client/server application
When the web server receives an HTTP request for a PHP page, the web server calls
the - Answers -web browser
Which of the following software components generates the HTML that is returned in an
HTTP response? - Answers -Chrome
The HTTP response for a dynamic web page is passed - Answers -from the web server
to the browser
Which of the following is NOT true about MariaDB? - Answers -it is being maintained by
many of the original developers of MySQL.
To deploy a PHP application on your own computer, you copy the application root
directory to - Answers -the htdocs directory of the Apache server
Which HTML tag or element is used to load an external stylesheet? - Answers -link
To run a PHP application that has been deployed on your own computer, you can enter
a URL in the address bar of your browser that - Answers -uses localhost as the domain
name
In HTML, parameters are called - Answers -attributes
The first part of a URL is called the - Answers -protocol
Which of the following is NOT part of an HTTP URL: - Answers -node
When HTML was first developed, Web pages were typically - Answers -static
If a URL specifies a directory that doesn't contain a default page, Apache displays -
Answers -a list of all of the directories in that directory
Which of the following is not a database server that can be used for dynamic Web
pages? - Answers -Python
To view the source code for a web page in a web browser, you can display the View
Source command by - Answers -right-clicking on the page
To make it easier to enter names into your code, NetBeans provides a feature known as
- Answers -auto-completion
, URL stands for - Answers -Uniform Resource Locator
A request and response for a file are made by - Answers -a client and a server
What type of a request does a Web browser typically send to a server? - Answers -
HTTP
What extension of a filename is typically associated with a static Web page? - Answers
-.htm
Which of the following can be used to style a label in an id named data? - Answers -
#data label
Which of the following is software that is a Web server? - Answers -Apache
Which of the following can be displayed if you omit the filename of a URL? - Answers -
all of these
A PHP variable name - Answers -is case-sensitive
The order of precedence for arithmetic expressions causes - Answers -increment
operations to be done first
To round and format the value of a variable named $number to 3 decimal places and
store it in a variable named $number_formatted, you code - Answers -
$number_formatted = number_format($number, 3);
After the code that follows is executed, what will the value of $units_per_store be?
$units = 30;
$stores = 4;
$units_per_store = intdiv($units, $stores); - Answers -7
After the code that follows is executed, what will the value of $units_per_store be?
$units = 30;
$stores = 4;
$units_per_store = $units % $stores; - Answers -2
After the if statement that follows is executed, what will the value of $discount_amount
be?
$discount_amount;
$order_total = 200;
if ($order_total > 200) {
$discount_amount = $order_total * .3;
} else if ($order_total > 100) {
$discount_amount = $order_total * .2;
} else {