PHP programmer interview questions and answers (basic theory type)

WBOY
Release: 2016-07-25 08:59:21
Original
1021 people have browsed it
This article introduces an interview question for PHP programmers, with detailed answers. It is a basic theoretical content. Friends in need can refer to it.

1. What does PHP mean? Answer: PHP is a server-based scripting language for creating websites. You can use PHP and HTML to generate the website homepage

2. Talk about the advantages and disadvantages of asp, php and jsp? Answer: ASP, the full name of Active Server Pages, is a WEB server-side development environment that can be used to generate and run dynamic, interactive, high-performance WEB service applications. ASP uses the scripting language VB Script (Java script) as its own development language. ​ PHP is a cross-platform server-side embedded scripting language. It borrows a lot of syntax from C, Java and Perl languages, and couples PHP's own features to enable web developers to quickly write dynamically generated pages. It supports currently Most databases. Another point is that PHP is completely free. You don’t need to spend money. You can download it freely from the PHP official site (http://www.php.net). And you have unrestricted access to the source code, and you can even add the features you need. ​ JSP is a new generation website development language launched by Sun Company. It completely solves a common problem of ASP and PHP currently - script-level execution (it is said that PHP4 has also been compiled and run with the support of Zend). Sun Company relies on its own expertise in Java With his extraordinary achievements, Java has a new fruit in addition to Java applications and Java Applets, which is Jsp-Java Server Page. Jsp can complete powerful website programs with the support of Serverlet and JavaBean. ​ All three provide the ability to mix some kind of program code in HTML code and have the program code interpreted and executed by the language engine. But the JSP code is compiled into a Servlet and interpreted and executed by the Java virtual machine. This compilation operation only occurs on the first request for the JSP page. In ASP, PHP, and JSP environments, HTML code is mainly responsible for describing the display style of information, while program code is used to describe processing logic. Ordinary HTML pages only rely on the web server, while ASP, PHP, and JSP pages require additional language engines to analyze and execute program code. The execution results of the program code are re-embedded into the HTML code and then sent to the browser together. ASP, PHP, and JSP are all Web server-oriented technologies, and the client browser does not require any additional software support.

3. Talk about your understanding of mvc? Answer: An application completed by Model, View, and Controller The model sends the functions to be implemented to the controller, and the controller receives the organized functions and passes them to the view;

4. Write the SQL of the names of the ten people with the most posts, using the following table: members(id,username,posts,pass,email) Answer:

SELECT * FROM `members` ORDER BY posts DESC limit 0,10;

5. What is the GD library used for?

Answer: The gd library provides a series of functions for processing images. You can use the GD library to process images or generate images. On websites, the GD library is usually used to generate thumbnails or to add watermarks to images or to generate reports on website data.

6. Please write down the meaning of data type (int char varchar datetime text); What is the difference between varchar and char? Answer: int is a numeric type, char fixed length string, varchar actual length string, datetime date and time type, text text string The field of char is fixed to the length set when creating the table, and varchar is a variable-length character.

The above is the entire content of the PHP interview questions provided in this article. The questions and answers are mostly basic theories. I hope it will be helpful to everyone.



source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!