Php programmer interview questions (yahoo)

Source: Internet
Author: User
Tags what operator
Php programmer interview questions (yahoo)

  1. $ Num = 10;
  2. Function multiply (){
  3. $ Num = $ num * 10;
  4. }
  5. Multiply ();
  6. Echo $ num;

4. what is the difference between referenced variables and common variables? How to pass a value through reference? Under what circumstances will this happen?

5. which functions can be used to add library code to the current code?

6. what is the difference between foo () and @ foo?

7. how do you debug your PHP program?

8. what operator is =? For example, the following example shows under what circumstances is true when = is used, but false When = is used.

9. how to declare a class named "myclass" without methods and attributes?

10. how to instantiate an object named "myclass?

11. how do you access and set the attributes of a class?

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

13. Which of the following functions can redirect the browser to a new page? 1. redir () 2. header () 3. location () 4. redirect ()

14. Which of the following functions can open a file to read and write the file? 1. fget (); 2. file_open (); 3. fopen (); 4. open_file ();

15. what is the difference between mysql_fetch_row () and mysql_fetch_array?

16. what operations does the following code perform? Explain what happened in each step. $ Date = '2014/1/123'; print ereg_replace ("([0-9] +)/([0-9] +)/([0-9] +) ", \ 2/\ 1/\ 3, $ date );

17. give you a string variable $ string. write a regular expression to remove the html tag.

18. What are the differences between arrays and hashes methods in PHP and Perl?

19. how can I avoid the connectionless features of PHP in PHP?

20. what is the GD library used?

21. point out some methods to input a piece of html code in PHP.

22. is PHP better than Peral? (Discussion)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.