Hie everyone.

Its been a year now using PHP and i think i do understand it now but dont understand what a PHP framework is and what it is used for, how it works, and if its necessary to use it.

please help

Dani AI

Generated

This thread asks what a PHP framework is, how it works, and whether it is necessary. pointed to external resources and argued for building a personal library. Both views are useful: frameworks are a practical choice for many projects, but rolling your own can make sense in specific cases. The note below gives a balanced, modern view and steps to pick an approach.

Frameworks bundle reusable components and conventions so you spend less time on repetitive plumbing. Typical benefits: consistent app structure (often MVC), routing, database layers or ORM, templating, input validation, authentication, CSRF protection, caching and testing helpers. That reduces bugs, speeds team onboarding, and centralizes security fixes and performance improvements that individual projects would otherwise reimplement.

Building your own library is fine for learning and for tiny, single-purpose sites. The trade-offs are maintenance and scaling: you inherit all future bugfixes and feature work. A practical middle ground is to extract commonly used utilities into small, reusable packages and manage them with Composer so they can be shared across projects. Follow PSR standards from PHP-FIG to keep code interoperable and easier for others to understand.

How to choose: match the tool to the project. For low-overhead shared-host projects a lightweight framework may be easiest; for feature-rich web apps consider full-stack frameworks. Try a short prototype in one or two frameworks to measure developer speed and constraints. Check documentation quality, community activity, release cadence and license before committing. For starting points and modern tooling see CodeIgniter, Laravel and Symfony, and use Composer for dependency management (official sites linked here for reference: , Laravel, Symfony, Composer).

Recommended Answers

All 3 Replies

A PHP framework is a web application development platform that helps you to write PHP programs. There are many PHP Frameworks. Popular among them is the Zend Framework. Visit the following link for more info: http://www.phpframeworks.com/

Hie everyone.

Its been a year now using PHP and i think i do understand it now but dont understand what a PHP framework is and what it is used for, how it works, and if its necessary to use it.

please help

My opinion: real php programmers don't use frameworks, they build their own through time. Anytime I need a new widget, I build a class and add it to my library.

I agree with you and I've been thinking deeply how and when I can be able to develop a unique platform to power my applications.

My opinion: real php programmers don't use frameworks, they build their own through time. Anytime I need a new widget, I build a class and add it to my library.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.