Friday, June 29, 2007

PHP Interview Questions

1. How can we optimize or increase the speed of a mysql select query?

2. How many ways can we get the value of current session id?

3. How can we destroy the session, how can we unset the variable of a session?

4. How can we destroy the cookie?

5. How many ways we can pass the variable through the navigation between the pages?

6. What is the difference between ereg_replace() and eregi_replace()?

7. What are the different functions in sorting an array?

8. How can we know the count/number of elements of an array?

9. What is the PHP predefined variable that tells the What types of images that PHP
supports?

10. How can I know that a variable is a number or not using a JavaScript?

11. List out some tools through which we can draw E-R diagrams for mysql.

12. How can I retrieve values from one database server and store them in other database server using PHP?

13. List out the predefined classes in PHP?

14. How can I make a script that can be bilanguage (supports English, German)?

15. What are the difference between abstract class and interface?

16. How can we send mail using JavaScript?

17. What are the differences between Get and post methods in form submitting, give the
case where we can use get and we can use post methods?

18. Who is the father of PHP and explain the changes in PHP versions?

19. How can we submit a form without a submit button?

20. In how many ways we can retrieve the date in the result set of mysql using PHP?

21. What is the difference between mysql_fetch_object and mysql_fetch_array?

22. What is the difference between $message and $$message?

23. How can we extract string ‘abc.com ‘ from a string ‘http://info@abc.com’ using regular expression of PHP?

24. How can we create a database using PHP and mysql?

25. What are the differences between require and include, include_once?

26. Can we use include (”abc.PHP”) two times in a PHP page “makeit.PHP”?

27. What are the different tables present in mysql, which type of table is generated when we are creating a table in the following syntax: create table employee(eno int(2),ename varchar(10)) ?

28. Functions in IMAP, POP3 AND LDAP?

29. How can I execute a PHP script using command line?

30. Suppose your Zend engine supports the mode Then how can u configure your PHP Zend engine to support mode ?

31. Shopping cart online validation i.e. how can we configure Paypal, etc.?

32. What is meant by nl2br()?

33. Draw the architecture of Zend engine?

34. What are the current versions of apache, PHP, and mysql?

35. What are the reasons for selecting lamp (linux, apache, mysql, PHP) instead of combination of other software programmes, servers and operating systems?

36. How can we encrypt and decrypt a data present in a mysql table using mysql?

37. How can we encrypt the username and password using PHP?

38. What are the features and advantages of object-oriented programming?

39. What are the differences between procedure-oriented languages and object-oriented languages?

40. What is the use of friend function?

41. What are the differences between public, private, protected, static, transient, final and volatile?

42. What are the different types of errors in PHP?

43. What is the functionality of the function strstr and stristr?

44. What are the differences between PHP 3 and PHP 4 and PHP 5?

45. How can we convert asp pages to PHP pages?

46. What is the functionality of the function htmlentities?

47. How can we get second of the current time using date function?

48. How can we convert the time zones using PHP?

49. What is meant by urlencode and urldocode?

50. What is the difference between the functions unlink and unset?

51. How can we register the variables into a session?

52. How can we get the properties (size, type, width, height) of an image using PHP
image functions?

53. How can we get the browser properties using PHP?

54. What is the maximum size of a file that can be uploaded using PHP and how can we change this?

55. How can we increase the execution time of a PHP script?

56. How can we take a backup of a mysql table and how can we restore it. ?

7 comments:

nnn said...

Nice question..and its are good for preparation..if possible plz joint answers with it.

Anonymous said...

Eggs-zactly, is this for interview questions and what to say, or is it a study guide for things to go dig around?

Would be nice to have the answers on the stuff... ya know?!?!?!

Roja said...

For increase speed of select query, there are some factor
like...
-By using Limit in query
-By using Index on table
-By using Primary key

Roja said...

For increase speed of select query, there are some factor
like...
By using Limit in query
By using Index on table
By using Primary key

Mrs. Patel said...

hi,this is really very good questions for the interviews..
thank a lot..

Anonymous said...

Yes...these questions were really useful. Though I saw such interview questions in other sites, these were really helpful. Readers can also try out another couple of such sets at http://www.kanbal.com/index.php?/PHP/php-interview-questions-set-1.html

I found it to be useful. Happy preparations......

web dagger said...

Hey thanks a lot for sharing useful interview questions..... which will be very helpful while attending the interviews.....
glad i found ur site...really a very helpful site.....
by the way check out my collection of php interview questions from here: php interview questions




Get unlimited interview questions on our new improved website...


 Interview Helper Home | Forum | Submit Link | Online Tickets | Freelance Work | Free Games | Jobs