TN Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 1.
Write the famous quote said by founder of Microsoft, Billgates on Business and entertainment industry.
Answer:
“If your business establishment is not on the internet (online based), then your business will be out of business context”.

Question 2.
What are client server architecture model?
Answer:

  • Single Tier Architecture
  • Two Tier Architecture
  • Multi/Three Tier Architecture.

Question 3.
What is the use of single Tier Architecture?
Answer:

  • The single tier Architecture is used for the server, accessed by client.
  • The client application runs inside the server machine itself.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 4.
What is the use of the Two Tier Architecture?
Answer:

  • The two Tier Architecture is used for the server, accessed by client as two layers interactions.
  • Such as client layer in tire one and server layer in tire two.

Question 5.
What is the use of multi Three Tier Architecture?
Answer:

  • The use of multi/Three Tier Architecture is used for the server, accessed by client through more than one layer interaction.
  • The programmer could decide the count of business logic layers according to the software requirement.

Question 6.
What are the types of web scripting language?
Answer:

  • Web scripting languages are classified into two types, client side and server side scripting language.
  • PHP is completely different from client side scripting language like java script.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 7.
What is web development concept?
Answer:
Web development concept describes in detail about website development and hosting through network (Internet/ Intranet).

Question 8.
What are includes the process of development?
Answer:
The process of development includes web content generation, web page designing, website security and so on.

Question 9.
What are the PHP syntax?
Answer:
Three types of PHP syntax are available they are

  • Default syntax,
  • Short open tags,
  • HTML script embed tags.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 10.
What are default syntax?
Answer:
The default syntax begins with “<?php” and closes with “?>”.

Question 11.
What are short open tags?
Answer:
The short open tags begin with “<?” and closes with “?>”. But Admin user has to enable short style tags settings in php. ini file on the server.

Question 12.
Write the syntax for HTML script embed tags?
Answer:
Syntax:
<script language = “php”> echo “This is HTML script tags”;
</script>

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 13.
What is variables?
Answer:
Variables are the storage location, which can store the values for the later manipulations in the program.

Question 14.
What is the main advantage of the PHP variable declaration?
Answer:
The main advantage of the PHP variable declaration is, it does not requires to specify the data type keyword separately such as int, char, float, double or string etc.,

Question 15.
What is var_dump() system?
Answer:
The var_dump() system define function, returns structured information (type and value) about variable in PHP.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 16.
What is an Array?
Answer:
An Array is a data type which has multiple values in single variable.
Eg: $Marks = array (“89”, “99”, “86”, “78”);

Question 17.
What is PHP an object?
Answer:
PHP object is a data type which contains information about data and function . inside the class.

Question 18.
What is NULL?
Answer:
NULL is a special data type which contains a single value NULL.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 19.
What is string in PHP?
Answer:
String is a collection of characters within the double or single quotes.
Eg: $x = “computer”; ‘
$y = ‘computer’;

Question 20.
What is a Resource?
Answer:

  • Resource is a specific variable, it has a reference to an external resource.
  • These variables hold specific handlers to handle files and database connections in respective PHP program.

Question 21.
What is assignment operator in PHP?
Answer:

  • The default assignment operator is “=”.
  • Assignment operators are performed with numeric values to store a value to a variable.
  • This = operator sets the left side operant value of expression to right side variable.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 22.
What are the use to perform Increment and Decrement operators?
Answer:

  • Increment and Decrement operators are used to perform the task of increasing or decreasing variables value.
  • This operator is mostly used during iterations in the program logics.

Question 23.
What are string operators?
Answer:
Two operators are used to perform string related operations such as concatenation and concatenation assignment.
. – concatenation operator
.= – concatenation assignment operator.

Question 24.
What is URL?
Answer:
URL means uniform resource locator, the address of a specific web page or file on the internet.

Question 25.
What is HTTP?
Answer:
HTTP means Hyper Text Transfer Protocol is the underlying protocol used by the World Wide Web and this protocol defines how messages are formatted and transmitted, and what actions web servers and browsers should take in response to various commands.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 26.
What will be the output of the following PHP code?
1. <?php
2. $one = 1;
3. print(Sone);
4. print $one; .
5. ?>
Output: 11 * (print can be used in PHP with or without parantheses)

Question 27.
What will be the output of the following PHP code?
Answer:
1. <?php
2. Scars = array (“volvo”, “BMW” “TOYOTO”)
3. Print $cars[2];
4. ?>
Output: Toyoto

Question 28.
What will be the output of the following PHP code?
Answer:
1. <?php
2. for ($i = 0; $i<5; $i++)
M
4. for($j = $i; $j>0; $i—)
5. print $i; –
8.}
7. ?>
Output: infinite loop, (No output)

Question 29.
What will be the output of the PHP code?
Answer:
$x = 5;
echo $x; echo “<br/>”;
echo $x+++$x++;
Output: 5
11

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 30.
What is output?
Answer:
var_dump (0123 = = 123);
var_dump (‘0123’ = = 123);
var_dump (‘0123 = = = 123);
Output: false
true
false

Question 31.
What are basic rules for variable decoration in PHP?
Answer:

  • Variable name must always begin with $ symbol.
  • Variable name can never with a number.
  • Variable name are case-sensitive.

Question 32.
List the PHP supports data types.
Answer:
PHP supports data types are

  1. String
  2. Integer
  3. Float
  4. Boolean
  5. Array
  6. Object
  7. NULL
  8. Resource

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 33.
What is use var_dump() function in PHP?
Answer:

  • The var_dump() function is used to dump information about a variable.
  • This function displays structured information such as type and value of the given variable.
  • Arrays and objects are explored recursively with values indented to show structure.

Question 34.
List the operators in PHP.
Answer:
The operators in PHP are

  1. Arithmetic operators
  2. Assignment operators
  3. Comparison operators .
  4. Increment/Decrement operators
  5. Logic operators
  6. String operators

Question 35.
Write the Arithmetic Operators and its purposes.
Answer:

  1. + – Addition, It performs the process of adding numbers.
  2. – – Subtraction, It performs the process of subtracting numbers.
  3. * – Multiplication, It performs the process of multiplying numbers.
  4. / – Division, It performs the process of dividing numbers.
  5. % – Modules, It performs of finding remainder in division.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 36.
Write the assignment operators and its description.
Answer:

TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor 1

TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor 2

Question 37.
Write the Increment and Decrement operators.
Answer:

TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor 3

Question 38.
Write the logical operators with example.
Answer:

TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor 4

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 39.
What will be the output of the following PHP code?
Answer:
<?php
$x = 10;
$y = 20;
if ($x > $y + $y I = 3)
Print “Hello sir”; else
Print “How are you”;
?>
Output: Hello sir

Question 40.
What will be the output of the following PHP code?
Answer:
<?php
echo 5*9 / 3+9;
?>
Output: 24

Question 41.
What will be the output of the following PHP code?
Answer:
<?php
$a = 1; $b = 3;
$d = $a++ + ++$b;
echo $d; 1
?>
Output: 5

Question 42.
What will be the output of the following PHP code?
Answer:
<?php
$a = 10; $b = 10; if ($a = 5)
$b—;
Print $a; Print $b —;
?>
Output: 59

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 43.
What will be the output of the following PHP code?
Answer:
<?php
$b = 1; $c = 4; $a = 5;
$d = $b + $c = = $a;
Print $d;
?>
Output: 1

Question 44.
What is PHP $ and $$ variable?
Answer:

  • The $ variable is a normal variable with the name var that stores any value like string, integer, float etc.,
  • The $$ variable is a reference variable that stores the value of the $ variable inside it.

Question 45.
How many types of array are there in PHP?
Answer:
There are three types of array in PHP

  • Indexed array
  • Associative array
  • Multidimensional array.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 46.
How is PHP script work?
Answer:

  1. Website or web page is developed by the programmer using PHP script.
  2. Next the entire website codes are moved to web server path in a remote server machine.
  3. From client side, the end user opens a browser, types the URL of the website or webpage and initiates the request to remote server machine over the network.
  4. After receiving the request from client machine the web server tries to compile and interpret the PHP code which is available in remote machine.
  5. Next a response will be generated and sent back to the client machine over the network from web server.
  6. Finally the browser which is installed in the client machine receives the response and displays the output to user.

Question 47.
Write the comparison operators.
Answer:

TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor 5

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 48.
What are the advantages, you should use PHP program language?
Answer:

  1. PHP is an open source software
  2. PHP is a case sensitive language
  3. PHP is a simplicity program language
  4.  PHP is a Efficiency program language
  5. PHP is a Platform Independent program language
  6. PHP is a Flexibility program language
  7.  PHP is a Real-Time access monitoring program language.\

Question 49.
Write a PHP program to print the table of 7.
Answer:
<?php
define (‘a’/7);
Output: 7
14
21
28
35
42
49
56
63
70

Question 50.
Write a PHP program to find factorial number, (for example to find 4).
Answer:
<?php
$num = 4
Sfactorial = 1;
for ($x = $num; $x> = 1; $x –)
{
$factorial = $factorial*$x;
}
echo “Factorial of $num is $factoriai”;
?>
Output: Factorial of 4 is 24.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 50.
What are the common usages of PHP?
Answer:

  1. The common usages of PHP scripts can be used on most of the well- known operating systems like Linux, Unix, Solaris, Microsoft windows, MAC OS and many others.
  2. It also supports most web servers including Apache and IIS.

Question 51.
What is Webserver?
Answer:

  1. A Webserver is server software, or hardware dedicated to running said software, that can satisfy World Wide Web client requests.
  2. A web server can, in general, contain one or more websites.

Question 52.
What are the types scripting language?
Answer:
The types of scripting language are Perl, Javascript, VB script, Apple script, Microsoft ASP, JSP, PHP, Python etc.,

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 53.
Difference between Client and Server.
Answer:

Client

 Server

The client is a separate hardware machine which is connected with server in the network.  The server is a high performance hardware machine it could run more than one application concurrently.
It could send the request and receive the response from the server hardware.  Server that the action takes place on a web server.

Question 54.
Give few examples of Web Browser.
Answer:
Web Browsers are Internet Explorer, Mozilla Firefox, Google chrome, Safari, Opera, Konqueror, Lynx etc.,

Question 55.
What is URL?
Answer:

  1. A URL (Uniform Resource Locator), is a reference to a web resource that specifies its location on a computer network and mechanism for retrieving it.
  2. The address of a World Wide Web page.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 56.
Is PHP a case sensitive language?
Answer:
Yes, PHP is a case sensitive language.

Question 57.
How to declare variables in PHP?
Answer:
The variable in PHP begins with a dollar ($) symbol and the assignment activity implemented using “=” operator, finally the statement ends with semicolon The semicolon indicates the end of statement.

Question 58.
Define Client Server Architecture.
Answer:

  1. Client server architecture is a computing model in which the server hosts, delivers and manages most of the resources and services to be consumed by the client.
  2. This type of architecture has one or more client computers connected to a central server over a network or internet connection.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 59.
Define Webserver.
Answer:

  1. A Webserver is server software, or hardware dedicated to running said software, that can satisfy World Wide Web client requests.
  2. A web server can, in general, contain one or more websites.

Question 60.
Write the features of server side scripting language.
Answer:

  1. Server side scripting language is a technique use in web development which involves employing scripts on a web server which produce a response customized for each users request to the website.
  2. Server side scripting is often used to provide a customized interface for the user.
  3. Serverside scripting also enables the website owner to hide the source code that generates the interface.
  4. Scripts can be written in any of a number of server-side scripting languages that are available in the following.
  5. ASP, Active VFP, ASP.NET, Cold Fusion Markup language, GO, Google Apps script, Hack, Haskell, Java Server Page, Java Script, Lasso, Lua, Parser, Perl, PHP, Python, R, Ruby, SMX, TCL, WebDNA, Progress web speed, Bigwig etc.,

Question 61.
Write is the purpose of Web server.
Answer:

  1. A web server is a server software, or hardware dedicated to running said software, that can satisfy World Wide Web client requests.
  2. A web server processes incoming network requests over HTTP and several other related protocols.
  3. The primary function of a Webserver is to store, process arid deliver web pages to clients.
  4. Multiple web server may be used for high traffic website.
  5. The primary function of Webserver is to serve content, a full implementation of HTTP also includes ways of receiving content from clients.
  6. Many generic web servers also support server-side scripting using active server pages or other scripting languages.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 62.
Differentiate Server side and Client Side Scripting language.
Answer:

Server side

 Client side

The server side that runs a scripting language is a web server.  The Client side used to run scripts is usually a browser.
A user’s request is fulfilled by running a script directly on the web server to generate dynamic HTML pages.  The source code is transfered from the web server to the users computer over the internet and run directly in the browser.
This HTML is then sent to the client browser.  The processing takes place on the end users computer.
It is usually used to provide interactive web sites that interface to databases or other data stores on the server.  The scripting language needs to be enable on the client computer.

Question 63.
In how many ways you can embed PHP code in an HTML page?
Answer:

  1. There are two ways to use can embed PHP code in an HTML page.
  2. The first way is to put the HTML outside of your PHP tags. You can even nut it ip the middle if you close and reopen the tags.
  3. The second way to use HTML with PHP is by using PRINT or ECHO. By using this method you can include the HTML inside of the PHP tags. This is a nice quick method if you only have a line or so to do.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 64.
Write short notes on PHP operator.
Answer:
Operator is a symbol which is used to perform mathematical and logical operations in the programming languages.
Different types of operator in PHP are –

  1. Arithmetic operators
  2. Assignment operators
  3. Comparison operators
  4.  Increment/Decrement operators
  5. Logical operators and
  6. String operators.

Question 65.
Explain client side and server side scripting language.
Answer:
All websites usually run on three components namely the server, the client and the database. To view a website, an individual has to use a browser. The browser can be termed as a client.
The client can use different technologies like mobile phones, laptops, computers, tablets, etc., to view the websites.
The server can run back-end architecture of a website, process requests, send pages to the browser, and so on. Server side scripting is usually done by a web server.

Client side scripting:

  1. Client scripting can be defined as a code that is present in a client’s HTML page.
  2.  It is usually attached to the browser in a language that is compatible with the browser.
  3. The language used for client scripting is Java script, VB script etc., It is the most widely used language for client-side scripting.
  4. Today, client-side scripting is rapidly growing and volving.

Server side scripting:

  1. The server side scripting usually happens on the back-end of a website.
  2. The user does not get access to view, A server side scripting creates a path for the website to the database and all the behind-the scene work.
  3. The commonly used in server scripting are Ruby, PHP, ASP etc.,
  4. Most of the websites today uses both client-side and server-side scripting. Popular sites like Amazon, Google, Facebook etc., make use of both client and server side scripting.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 66.
Discuss in detail about Website development activities.
Answer:
There are numerous steps in the website development activities, some basic Activities are –

  1. Information gathering,
  2. Planning,
  3. Design,
  4. Development,
  5. Testing and Delivery,
  6. Maintenance.

(i) Information Gathering:
It is important that your web designer start off by asking a lot of information from the company and needs in a website. Important information gathering are purpose, goals, Target Audience and content.

(ii) Planning:
During the planning phase, your web designer will also help you decide what technologies should be implemented and discuss any planning your website.

(iii) Design:
As part of the design phase, it is also incorporate elements such as the company logo or colours to help strengthen your company website. The most important to express you likes and dislikes on the side design.

(iv) Development:
(a) The first develop is home page, and followed by a shell for the interior page.
(b) On the technical front, a successful website requires an understanding of front end web development.

(v) Testing and Delivery:
(a) As part of testing, your designer should check to be sure that all of the code written for your website validates. This is helpful when checking for issues such as cross-browser compatibility.
(b) Finally include plugin installation, and web designer final approval, it is time to deliver the site.

(iii) Float:
Float datatypes contains decimal numbers. Eg: $m = 15.25;

(iv) Boolean:
Boolean is a data type which denotes the possible two states, true or false. Eg: $x = true; $y = false;

(v) Array:
Array is data type which has multiple values in single variable. Eg: Subjects = array (“Tamil”, “English”, “Computer Application”);

(vi) Object:
PHP object is a data type which contains information about data function inside the class.

(vii) NULL:
Null is a special data type which contains a single value NULL. Eg: $x = null;

(viii) Resource:
(a) Resource is a specific variable, it has a reference to an external resource.
(b) These variables hold specific handlers to handle files and database connections in respective PHP program.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 67.
Explain the process of Webserver installation.
Answer:
Web server software is available as open source or licensed version in the market.
The open source web servers such as Tomcat Apache, Nginx etc.,
The following are the steps to install and configure Apache Httpd web server and PHP Module in windows server machine.

Step 1 : http://httpd.appache.org/download.cgi download the Httpd Webserver software.

Step 2: User launches the MSI file and clicks next and next button to finish the installation on server machine.

Step 3: To test the installation, use the URL https ://localhost: 130/ (or) https://localhost:130130 Now, screen that display “Its works”

Step 4: Administrator user can start, stop and restart the web server service at any time via windows control panel.

Step 5: Webservers configuration setting file “httpd.conf ” is located in the conf directory. Edit this file and enable the PHP module to run PHP scripting language.

Question 68.
Discuss in detail about PHP data types.
Answer:
PHP scripting language supports 13 primitive data types. PHP supports the following important data types,

  1. String,
  2. Integer,
  3. Float,
  4. Boolean,
  5. Array,
  6. Object,
  7. NULL,
  8. Resource.

(i) String:
String is a collection of characters within the double or single quotes. Eg: $m = “Rajesh”;

(ii) Integer:
Integer datatype contains non decimal number.
Eg: $m = “2675”;

(iii) Float:
Float datatypes contains decimal numbers. Eg: $m = 15.25;

(iv) Boolean:
Boolean is a data type which denotes the possible two states, true or false. Eg: $x = true; $y = false;

(v) Array:
Array is data type which has multiple values in single variable. Eg: Subjects = array (“Tamil”, “English”, “Computer Application”);

(vi) Object:
PHP object is a data type which contains information about data function inside the class.

(vii) NULL:
Null is a special data type which contains a single value NULL. Eg: $x = null;

(viii) Resource:
(a) Resource is a specific variable, it has a reference to an external resource.
(b) These variables hold specific handlers to handle files and database connections in respective PHP program.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 69.
Explain operators in PHP with example.
Answer:
Operators is a symbol which is used to perform mathematical and logical operations in the programming languages. Different types of operator in PHP are –

  1. Arithmetic Operators,
  2. Assignment Operators,
  3. Comparison Operators,
  4. Increment/Decrement operators,
  5. Logical Operators,
  6. String operators.

Arithmetic Operators:
The arithmetic operators in PHP perform general arithmetical operations, such as addition, subtraction, multiplication and division etc., The Arithmetic operators are +, -, *, / and %.

Assignment operators:
(i) Assignment operators are performed with numeric values to store a value to a variable.
(ii) The default assignment operator is “=”. This operator sets the left side opprant value of expression to right side variable.
(iii) The Assignment operators are =,+=,-=,*=,/=,%=.

Comparison operators:
(i) Comparison operators perform an action to compare two values. These values may contain integer or string data types.
(ii) The comparison operators are = =, ===, !=, <>, !==.

(vi) Maintenance:
(a) Most web designers will be working together with you, to update the information on your web site.
(b) Many designers offer maintenance packages at reduced rates, based on how often you anticipate making changes or additions to your web site.

Increment and Decrement operators:
(i) Increment and decrement operators are used to perform the task of increasing or decreasing’variable value. This operator is mostly used during iterations in the program logics.
(ii) The Increment and Decrement operators are
++$x – pre – increment
$x+ + – post – increment
– -$x – pre – decrement
$x post – decrement

Logical operators:
(i) Logical operators are used to combine conditional statements.
(ii) The logical operators are && -> And, || -> Or,! -> Not, XOR -> XOR.

String operators:
(i) Two operators are used to perform string related operations such as concatenation and concatenation assignment.
The string operators are .
. Concatenation
. = Concatenation Assignment.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 70.
Find out the following’web technology details from famous website using free web tools:
http://similarweb.com or http://pub-db.com
(i) Programming details
(ii) Webserver details
(iii) Hosting Country details.
Answer:
I. http://similanveb.com
(i) Programming details – ASP.NET, PHP
Client side – ASP. Net
Serverside -‘PHP
(ii) Webserver details – Nginx (engine x) is a light weight open source web server developed by Igor sysoev.
(iii) Hosting country details – Amazon in united states of America.

II. http://pub-db.com
(i) Programming details:
Serverside – PHP 5.4.16
Clientside – Javascript Markup – HTML 5
(ii) Web server details – Apache 2.4.6, HTTP server is a popular open source web server by Apache software foundation.
(iii) Hosting country details – Linode in Singapore.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Choose the correct answer:

Question 1.
Who was introduced the concept of internet and world wide web (www)?
(a) Berners-Lee
(b) Billgates
(c) Pichai Elango
(d) Martin glow
Answer:
(a) Berners-Lee

Question 2.
Which script language most widely used and recognizable technologies in use on the internet?
(a) TCL
(b) PHP
(c) Ruby
(d) Perl
Answer:
(b) PHP

Question 3.
CGI stands for:
(a) Central Gateway Interface
(b) Cascading Gateway Information
(c) Common Gateway Interface
(d) Common Good Interface
Answer:
(c) Common Gateway Interface

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 4.
CSS stands for:
(a) Cascading Style Sheets
(b) Cascading srever Sheets
(c) Common Style Sheets
(d) Common Server System
Answer:
(a) Cascading Style Sheets

Question 5.
Which of the following apache foundation Webserver software?
(a) Ruby
(b) Httpd
(c) Perl
(d) PHP
Answer:
(b) Httpd

Question 6.
What is default port number for MSI file from Apache foundation?
(a) 130
(b) 150
(c) 130130
(d) Both (a) and (c)
Answer:
(d) Both (a) and (c)

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 7.
Which directory is located httpd.conf Webserver file?
(a) temp
(b) software
(c) conf
(d) config
Answer:
(c) conf

Question 8.
The default PHP syntax begin with:
(a) “<?PhP”
(b) “«?PHP”
(c) “?<PhP”
(d) “?<PHP>”
Answer:
(a) “<?PhP”

Question 9.
The default PHP syntax closes with:
(a) “<?”
(b) “?>”
(c) ?”>”
(d) “?”>
Answer:
(b) “?>”

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 10.
What is called storage location which can store the values for manipulation in the program?
(a) constant
(b) Integer
(c) Variable
(d) Literal
Answer:
(c) Variable

Question 11.
Which symbol is begin with PHP variable?
(a) #
(b) $
(c) *
(d) &
Answer:
(b) $

Question 12.
Which of the following is indicates the end of statement?
(a) ,(comma)
(b) .(full stop)
(c) :(colon)
(d) ;(semicolon)
Answer:
(d) ;(semicolon)

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 13.
How many primitive data types supports PHP scripting language?
(a) 8
(b) 10
(c) 11
(d) 13
Answer:
(d) 13

Question 14.
String is a collection of:
(a) numbers
(b) numeric values
(c) characters
(d) symbols
Answer:
(c) characters

Question 15.
Which data types denote the two possible states?
(a) Integer
(b) Float
(c) Array
(d) Boolean
Answer:
(d) Boolean

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 16.
Which data type has multiple values in single variable?
(a) Integer
(b) Float
(c) Array
(d) Boolean
Answer:
(c) Array

Question 17.
Which function is used to dump information about a variable?
(a) var_dump()
(b) dump()
(c) var_x()
(d) var_dumpx()
Answer:
(a) var_dump()

Question 18.
What is the special data type which contains a single value?
(a) Boolean
(b) Array
(c) NULL
(d) Resource
Answer:
(c) NULL

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 19.
Which operator performs to finding remainder in division?
(a) %(module)
(b) /(division)
(c) \(back slash)
(d) – (minus)
Answer:
(a) %(module)

Question 20.
Which is similar Assignment expression for x + = y?
(a) x + y
(b) x = x + y
(c) x + y = y
(d) y = y + x
Answer:
(b) x = x + y

Question 21.
Which of the following operator is not equal?
(a) ! =
(b) <>
(c) = = =
(d) Both (a) and (b)
Answer:
(d) Both (a) and (b)

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 22.
What is called two operators are used to perform string related operations?
(a) concatenation
(b) concatenation assignment
(c) Both (a) and (b)
(d) assignment
Answer:
(c) Both (a) and (b)

Question 23.
HTTP stands for:
(a) Hyper Text Transfer Protocol
(b) Hyper Text Transmission Protocol
(c) Hyper Text Transfer Preprocessor
(d) Hyper Text Transmission Preprocessor
Answer:
(a) Hyper Text Transfer Protocol

Question 24.
PHP scripts are executed on:
(a) ISP computer
(b) client computer
(c) server computer
(d) depends on PhP scripts
Answer:
(c) server computer

Question 25.
Which of the following statements prints in PhP?
(a) out
(b) write
(c) echo
(d) display
Answer:
(b) write

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 26.
In PHP a variable needs to be declare before assign:
(a) True
(b) False
(c) Depends on website
(d) Depends on server
Answer:
(b) False

Question 27.
What will be the output of the PHP code?
1. <?php
2. $Total = “25”;
3. $more = 10;
4. $Total = $Total + Smore;
5. echo “$Total”;
6. ?>
(a) Error
(b) 2510
(c) 35
(d) 10
Answer:
(c) 35

Question 28.
Which statement will output $x on the screen?
(a) echo “\$x”;
(b) echo “$$x”;
(c) echo “/$x”;
(d) echo “$x”;
Answer:
(a) echo “\$x”;

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 29.
What will be the output of the following PhP code?
1. <?PhP
2. $a = “clue”;
3. $a = “get”;
4. echo “$a”;
5. ?>
(a) get
(b) true
(c) false
(d) clueget
Answer:
(d) clueget

Question 30.
What will be the output of the following PHP code?
1. <? php
2. $a = 5;
3. $b = 5;
4. echo “$a”;($a=$b)
5. ?>
(a) 5==5
(b) error
(c) 1
(d) false
Answer:
(c) 1

Question 31.
Match the following:

(A) CSS  (i) Web server
(B) Java script  (ii) Server side script
(C) ASP  (iii) HTML method
(D) Apache Tomcat  (iv) Client side script

(a) (A) – (iv); (B) – (iii); (C) – (ii); (D) – (i)
(b) (A) – (iv); (B) – (ii); (C) – (i); (D) – (iii)
(c) (A) – (ii); (B) – (i); (C) – (iii); (D) – (iv)
(d) (A) – (ii); (B) – (iv); (C) – (iii); (D) – (i)
Answer:
(a) (A) – (iv); (B) – (iii); (C) – (ii); (D) – (I)

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 32.
Match the following:

(A) Web server  (i) OPP’s
(B) PHP  (ii) Software
(C) client  (iii) Service provider
(D) Server  (iv) Service requester

(a) (A) – (ii); (B) – (iii); (C) – (iv); (D) – (i)
(b) (A) – (ii); (B) – (i); (C) – (iv)- (D) – (iii)
(c) (A) – (iii); (B) – (i); (C) – (iv); (B) – (ii)
(d) (A) – (iii); (B) – (ii); (C) – (i); (D) – (iv)
Answer:
(b) (A) – (ii); (B) – (i); (C) – (iv)- (D) – (iii)

Question 33.
Match the following:

(A)”<?”  (i) php variable begins
(B) “?>”  (ii) Statement ends
(C) $  (iii) begin php statement
(D) ;  (iv) Closes php statement

(a) (A) – (iii); (B) – (i); (C) – (ii); (D) – (iv)
(b) (A) – (iv); (B) – (i); (C) – (iii); (D) – (ii)
(c) (A) – (iii); (B) – (iv); (C) – (i); (D) – (ii)
(d) (A) – (iv); (B) – (ii); (C) – (iii); (D) – (i)
Answer:
(c) (A) – (iii); (B) – (iv); (C) – (i); (D) – (ii)

Question 34.
Match the following:

(A) String  (i) Non decimal number
(B) Integer  (ii) Multiple values
(C) Array  (iii) Single values
(D) NULL  (iv) With double Quotes

(a) (A) – (iv); (B) – (i); (C) – (ii); (D) – (iii)
(b) (A) – (iv); (B) – (iii); (C) – (ii); (D) – (i)
(c) (A) – (iii); (B) – (ii); (C) – (i); (D) – (iv)
(d) (A) – (iii); (B) – (i); (C) – (iv); (D) – (ii)
Answer:
(a) (A) – (iv); (B) – (i); (C) – (ii); (D) – (iii)

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 35.
Match the following:

(A) %  (i) Not equal
(B) !=  (ii) Module
(C) ++$x  (iii) Not
(D) !  (iv) Pre increment

(a) (A) – (ii); (B) – (iii); (C) – (iv); (D) – (i)
(b) (A) – (iii); (B) – (ii); (C) – (i); (D) – (iv)
(c) (A) – (iii); {B) – (i); (C) – (iv); (D) – (ii)
(d) (A) – (ii); (B) – (i); (C) – (iv); (D) – (iii)
Answer:
(d) (A) – (ii); (B) – (i); (C) – (iv); (D) – (iii)

Question 36.
Choose the incorrect pair:
(a) PHP – Server side
(b) ASP – client side
(c) IIS – web server
(d) Web server – software
Answer:
(b) ASP – client side

Question 37.
Choose the incorrect pair:
(a) String – character
(b) Float – decimal
(c) Array – multiple
(d) Object – numeric
Answer:
(d) Object – numeric

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 38.
Choose the incorrect pair:
(a) = = – equal
(b) == = – equal to
(c) ! = – not equal
(d) !== – Not identical
Answer:
(b) == = – equal to

Question 39.
Choose the correct pair:
(a) &&- OR
(b) || – AND
(c) ! – NOT
(d) XOR – XR
Answer:
(c) ! – NOT

Question 40.
Choose the correct pair:
(a) URL – directory
(b) HTTP – statement
(c) Server – clients
(d) Browser – hardware
Answer:
(c) Server – clients

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 41.
Choose the incorrect statement:
(a) PHP is a one of the important server side web and general purpose scripting language.
(b) PHP scripting language can be executed via an interpreter.
(c) PHP is an open source community development initiation.
(d) PHP scripting language was developed by microsoft corporation.
Answer:
(d) PHP scripting language was developed by microsoft corporation.

Question 42.
Choose the incorrect statement:
(a) The server is a high performance hardware machine.
(b) The client is a individual software which is connected in the network.
(c) The server is called as service provider.
(d) The client is called as service requester.
Answer:
(b) The client is a individual software which is connected in the network.

Question 43.
Choose the incorrect statement:
(a) Single Tier architecture is used for the user, accessed by database administrator.
(b) The client application runs inside the server machine itself.
(c) Web server is software which is running in server hardware.Answer:
(d) Web server takes the responsibilities for compilation and execution of server side scripting language.
Answer:
(a) Single Tier architecture is used for the user, accessed by database administrator.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 44.
Choose the correct statement:
(a) PHP is fully same client side scripting language like Java script.
(b) PHP also supports OPP’s concepts.
(c) Website development and hosting through software.
(d) The process of development also include computer generation.
Answer:
(b) PHP also supports OPP’s concepts.

Question 45.
Choose the correct statement:
(a) The variable in PHP begins with a * (asterisk) symbol
(b) ,(comma) indicates the PhP end statement.
(c) PHP scripting language supports 13 primitive data types.
(d) String is a collection of characters within single quotes.
Answer:
(c) PHP scripting language supports 13 primitive data types.

Question 46.
Assertion (A):
In 1990’s British scientist Tim Berners-Lee introduced the concept of internet and World Wide Web (www).
Reason (R):
These concepts required a new set of programming languages over the network communication and also recently called as web scripting, language.
(a) Both A and R are true, and R is the correct explanation for A
(b) Both A and R are true, But R is not the correct explanation for A.
(c) A is true, But R is false.
(d) A is false, But R is true.
Answer:
(a) Both A and R are true, and R is the correct explanation for A.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 47.
Assertion (A):
The main objective of internet implies that an application is shared by more than one hardware either it could be server or client machine.
Reason (R):
Internet was emerging in the computer network field.
(a) Both A and R are true, and R is the correct explanation for A.
(b) Both A and R are true, but R is not the correct explanation for A.
(c) A is true, But R is false.
(d) A is false, But R is true.
Answer:
(b) Both A and R are true, but R is not the correct explanation for A.

Question 48.
Assertion (A):
Webserver is software which is running in server hardware.
Reason (R):
The architecture is used for the server, accessed by Data Base Administrator.
(a) Both A and R are true, and R is the correct explanation for A.
(b) Both A and R are true,but R is not the correct explanation for A.
(c) A is true, But R is false.
(d) A is false, But R is true.
Answer:
(c) A is true, But R is false.

Question 49.
Assertion (A):
PHP script language is not supports Object Oriented Programming (OOP’s) concepts.
Reason (R):
Webserver software is available as open source or licensed version in the market.
(a) Both A and R are true, and R is the correct explanation for A.
(b) Both A and R are true, and R is not the correct explanation for A.
(c) A is true, But R is false.
(d) A is false, But R is true.
Answer:
(d) A is false, But R is true.

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 50.
Assertion (A):
PHP scripts can be written inside of HTML code and save the file with extension of HTML.
Reason (R):
The embeded PHP file get executed by the Java interpreter.
(a) Both A and R are true.
(b) Both A and R are False.
(c) A is true, But R is false.
(d) A is false, But R is true.
Answer:
(b) Both A and R are False.

Question 51.
Pick the odd one out.
(a) Ruby
(b) PHP
(c) ASP
(d) CGI
Answer:
(d) CGI

Question 52.
Pick the odd one out.
(a) String
(b) Integer
(c) Open
(d) Float
Answer:
(c) Open

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 53.
Pick the odd one out.
(a) %
(b) *
(c) +
(d) S
Answer:
(d) S

Question 54.
Pick the odd one out.
(a) ! =
(b) & &
(c) ||
(d) !
Answer:
(a) ! =

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 55.
Pick the odd one out.
(a) /* */
(b) “<?”
(c) #
(d) ||
Answer:
(b) “<?”

Question 56.
What does PHP stand for?
(a) Personal Home Page
(b) Hypertext Preprocessor
(c) Pretext Hypertext Processor
(d) Pre-processor Home Page
Answer:
(b) Hypertext Preprocessor

Question 57.
What does PHP files have a default file extension?
(a) .html
(b) .xml
(c) .php
(d) .ph
Answer:
(c) .php

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 58.
A PHP script should start with ……….. and end with ………
(a) <php>
(b) < ? php ? >
(c) < ? ? >
(d) < ?php? >
Answer:
(c) < ? ? >

Question 59.
Which of the following must be installed on your computer so as to run PHP script?
(a) Adobe
(b) windows
(c) Apache
(d) IIS
Answer:
(c) Apache

Question 60.
We can use ……………… to comment a single line?
(i) /?
(ii) //
(iii) #
(iv) /**/
(a) Only (ii)
(b) (i), (iii) and (iv)
(c) (ii), (iii) and (iv)
(d) Both (ii) and (iv)
Answer:
(c) (ii), (iii) and (iv)

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 61.
Which of the following PHP statement/statements will store 41 in variable num?
(a) Both (i) and (ii)
(b) All of the mentioned.
(c) Only (iii)
(d) Only (i)
(e) $num=41
Answer:
(e) $num=41

Question 62.
What will be the output of the following PHP code?
<?php
$num = 1;
$numl = 2;
print $num . “+”. $numl;
?>
(a) 3
(b) 1+2
(c) 1.+.2
(d) Error
Answer:
(b) 1+2

Question 63.
Which of the following PHP statements will output Hello World on the screen?
(a) echo (“Hello World”);
(b) print (“Hello World”);
(c) printf (“Hello World”);
(d) sprintf (“Hello World”);
Answer:
(b) print (“Hello World”);

Samacheer Kalvi TN State Board 12th Computer Applications Important Questions Chapter 4 Introduction to Hypertext Pre-Processor

Question 64.
Which statement will output $x on the screen?
(a) echo “\$x”;
(b) echo “$$x”;
(c) echo “/$x”;
(d) echo “$x;
Answer:
(a) echo “\$x”;

Question 65.
Which of the below symbols is a newline character?
(a) \r
(b) \n
(c) /n
(d) /r
Answer:
(b) \n

TN Board 12th Computer Applications Important Questions