Guys!!!Let’s have some fun...here are some questions 4 u based on php. So ready????Here they are:
1. A script is a
a. Program or sequence of instructions that is interpreted or carried out by processor directly
b. Program or sequence of instruction that is interpreted or carried out by another program
c. Program or sequence of instruction that is interpreted or carried out by web server only
d. None of above
2. When compared to the compiled program, scripts run
a. Faster
b. Slower
c. The execution speed is similar
d. All of above
3. PHP is a widely used ……………. scripting language that is especially suited for web development and can be embedded into html
a. Open source general purpose
b. Proprietary general purpose
c. Open source special purpose
d. Proprietary special purpose
4. Which of the following is not true?
a. PHP can be used to develop web applications.
b. PHP makes a website dynamic.
c. PHP applications cannot be compiled.
d. PHP cannot be embedded into html.
5. Which of the following method sends input to a script via a URL?
a. Get
b. Post
c. Both
d. None
6. Which of the following method is suitable when you need to send larger form submissions?
a. Get
b. Post
c. Both Get and Post
d. There is no direct way for larger form. You need to store them in a file and retrieve
7. The function setcookie( ) is used to
a. Enable or disable cookie support
b. Declare cookie variables
c. Store data in cookie variable
d. All of above
8. mysql_connect( ) does not take following parameter
a. database host
b. user ID
c. password
d. database name
9. Study following steps and determine the correct order
(1) Open a connection to MySql server
(2) Execute the SQL query
(3) Fetch the data from query
(4) Select database
(5) Close Connection
a. 1, 4, 2, 3, 5
b. 4, 1, 2, 3, 5
c. 1, 5, 4, 2, 1
d. 4, 1, 3, 2, 5
10. Which of the following delimiter syntax is PHP's default delimiter syntax
a. <? php ?>
b. <% %>
c. <? ?>
d. <script language="php"> </script>
11. Php supports all four different ways of delimiting. In this context identify the false statement
a. You can use any of the delimiting style
b. You can use different delimiting styles in same page
c. You can use any delimiting style but must use a single style consistently for a page
d. Variables declared in previous blocks are remenbered on later blocks too!
12. Which of following commenting is supported by Php
a. Single line c++ syntax - //
b. Shell syntax - #
c. Both of above
d. None of above
13. Which of following function return 1 when output is successful?
a. echo ( )
b. print ( )
c. both
d. None
14. Which of followng statement is more suitable if you want to output a blend of static text and dynamic information stored within one or several variables?
a. echo ( )
b. print ( )
c. Print f ( )
d. None of above
15. You can define a constant by using the define() function. Once a constant is defined
a. It can never be changed or undefined
b. It can never be changed but can be undefined
c. It can be changed but can not be undefined
d. It can be changed and can be undefined
U can submit ur answers in comments.
1.b
ReplyDelete2.b
3.a
4.c
5.a
6.b
7.b
8.d
9.a
10.a
11.c
12.c
13.b
14.c
15.8
@Teddy-ur 15th answr is unacceptable...
ReplyDeleteso 12 out of 15 are correct...:)
4th is a silly mistake. :D 7th answer is actually b n c. 15th ka guess mar raha hu, a??
ReplyDelete@teddy-yeah its a nd 7th ka mst accurate to c hi h
ReplyDelete