Wednesday, 29 October 2014

web development company in indoreHello Everyone..!!!
This morning i am here with some technical PHP interview questions for PHP developers to improve their web development skills. Solve these questions and prepare for interviews.

PHP Questions :

 

Questions Based on Functions :


Que.1 What will be the output of the following PHP code? 

  1.     echo str_pad("Salad", 5)." is good.";
  2. ?>
a) SaladSaladSaladSaladSalad is good
b) is good SaladSaladSaladSaladSalad
c) is good Salad
d) Salad is good

Que.2  What will be the output of the following PHP code ? 

  1.     function TV($string)
  2.     {
  3.         echo "my favourite TV show is ".$string;
  4.         function b()
  5.         {
  6.             echo " I am here to spoil this code";
  7.         }
  8.     }
  9.     b();
  10. ?>
a) I am here to spoil this code
b) Error
c) my favourite TV show isI am here to spoil this code
d) None of the above

Que.3  What will be the output of the following PHP code ?
 


function uppercase($string)

{

echo ucwords($string);

}

$wow = "uppercase";

$wow("Time to live king size");

?>

a) TIME TO LIVE KING SIZE
b) Time to live king size
c) uppercase
d) Time To Live King Size

Que.4 What will be the output of the following PHP code? 

  1.     echo ucwords("i love my country");
  2. ?>
a) I love my country
b) i love my Country
c) I love my Country
d) I Love My Country

Que.5 What will be the output of the following PHP code? 

  1.     echo hex2bin("48656c6c6f20576f726c6421");
  2. ?>
a) Hello World!
b) welcome to india
c) This is PHP!
d) MCQ questons

Questions Based on Website security using PHP

 

Que.1 Which Apache directive outputs Apache’s server version, server name, port and compile-in modules?

a) ServerSignature
b) ServerName
c) ServerDetails
d) ServerInfo

Que.2  Which directive determines which degree of server details is provided if the ServerSignature directive is enabled?

a) ServerAddons
b) ServerExtra
c) ServerTokens
d) ServerDetails

Que.3 Which directive should we disable to obscure the fact that PHP is being used on our server?

a) show_php
b) expose_php
c) print_php
d) info_php

Que.4 Say I want to change the extension of a PHP file, which of the following statements should I edit to change from .php to .html in the httpd.conf file?

a) AddType application/x-httpd-php .php
b) AddType application/x-httpd-php .asp
c) AddType application/x-httpd-asp .php
d) AddType application/x-httpd-asp .asp

Que.5 The developers of PHP deprecated the safe mode feature as of which PHP version.

a) PHP 5.1.0
b) PHP 5.2.0
c) PHP 5.3.0
d) PHP 5.3.1

Questions Based on File system and PHP


Que.1 The filesize() function returns the file size in ___.

a) bits
b) bytes
c) kilobytes
d) gigabytes

2. Which one of the following PHP function is used to determine a file’s last access time?

a) fileltime()
b) filectime()
c) fileatime()
d) filetime()

3. Which one of the following function is capable of reading a file into an array?

a) file()
b) arrfile()
c) arr_file()
d) file_arr()

4. Which one of the following function is capable of reading a file into a string variable?

a) file_contents()
b) file_get_contents()
c) file_content()
d) file_get_content()

5. Which one of the following function is capable of reading a specific number of characters form a file?

a) fgets()
b) fget()
c) fileget()
d) filegets()

Answersheet of these Questions will be available Tomorrow
 
Want more Questions....??? CLICK THE LINKS BELOW
 

Share your experience or any suggestion with us .. VIA COMMENTS

 


Regards : Web Development Company in Indore








1 comment:


  1. Share or Sell your documents, designs, graphic, 3d models, artworks, photographs, etc., earn money, and get hired worldwide. Register via e-mail or your social media account here:http://www.ehuub.com/login/ by choosing category "GRAPHICS, DESIGN, AND MULTIMEDIA", thank you!

    ReplyDelete

  • RSS
  • Delicious
  • Digg
  • Facebook
  • Twitter
  • Linkedin
  • Youtube