DEV Community

Full Stack Tutorials
Full Stack Tutorials

Posted on • Edited on

3 1

PHP Interview Questions [Core PHP]

Q. What is PHP?

PHP is a server-side scripting language designed for web development but also used as a general-purpose programming language.
Originally created by Rasmus Lerdorf in 1994, the PHP reference implementation is now produced by The PHP Group.

PHP originally stood for Personal Home Page, but it now stands for the recursive acronym PHP: Hypertext Preprocessor.

PHP code may be embedded into HTML code, or it can be used in combination with various web template systems, web content management systems, and web frameworks.

Q. Difference between isset() and empty() in PHP?

isset(): checks if a variable has a value including (False, 0, or empty string), but not NULL. Returns TRUE if var exists; FALSE otherwise.

empty(): function checks if the variable has an empty value empty string , 0, NULL ,or False. Returns FALSE if var has a non-empty and non-zero value."

Q. What is the use of explode and implode functions?

Use of explode() and implode() function
explode(): Convert string to Array
implode(): Convert Array to string

Q. What are PSRs? briefly describe it?

PSRs are PHP Standards Recommendations that aim at standardizing common aspects of PHP Development.

An example of a PSR is PSR-4, This PSR describes a specification for autoloading classes from file paths

Q. What is SQL injection?

The SQL injection is a malicious code injection technique. It exploiting SQL vulnerabilities in Web applications

Read more about - PHP Interviews Questions Answers

Heroku

This site is built on Heroku

Join the ranks of developers at Salesforce, Airbase, DEV, and more who deploy their mission critical applications on Heroku. Sign up today and launch your first app!

Get Started

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay