A set of php programmer interview questions-php Tutorial

Source: Internet
Author: User
A set of php programmer interview questions
We provide you with a set of php programmer interview questions. Here we provide the notes and questions section. if you need them, please refer to them.

This php interview question includes fill-in questions, short answer questions, design questions and logic questions. among them, the logic question is the most interesting in this php interview question. For more information, see.

I. fill in blank question 1. what language is PHP written? 2. currently, PHP has a maximum version of 3. the full name of LAMP is 4. three annotation methods of PHP 5. what symbols does PHP use to define variables?

II. Short Answer 1. list the eight data types of PHP.

2. there are several methods to load code in PHP and list it. take the Config. PHP file in the same directory as an example?

3. what does = mean in PHP?

4. which access modifiers can be used in PHP Objects? what are the default modifiers?

III. design question 1. $ I = 2. how can I determine whether $ I is an integer by programming? If yes, $ I is output, or "non-integer variable" is output "?

2. $ m = "MY name is php" IS programmed to remove the spaces before and after the strings in $ m and the spaces in the middle, and convert all the spaces to lowercase letters, what are the numbers of letters in $ m and $ m?

3. write a function, as efficient as possible, to retrieve the file extension from a standard url such as: http://bbs.it-home.org/abc/de/fg.php? Id = 1 need to retrieve php or. php

4. $ m = "woxihuanphp", programming implementation: split the string into a single character and store it in an array, and print the array?

5. $ username = "4a_c4_5", programming implementation: Check whether $ username meets the requirements. the user name must start with a letter or underline and can only contain letters, numbers, and underscores?

6. in PHP, heredoc is a special string and its end mark must be?

7. implemented by class programming: the Stu class has two private attributes: name and sex. There are two public methods: SetName () and SetSex () parameters, you can modify two private attributes. Private attributes must be initialized during class instantiation.

8. write a function to calculate the relative path of the two files, for example, $ a = '/a/B/c/d/e. php '; $ B ='/a/B/12/34/c. php '; calculates the relative path of $ B relative to $ .. /.. /c/d add ()

4. Logic 1. I am a man. if your son is my son's father, what am I yours? 2. how many miles does the Port River grow from the Port River to the Harry River, which is 850 miles shorter than the Port River? If ABD is opposite to CBA, then who is the relative relationship between QRT and?

Related Article

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.