What is Encapsulation? OOP Concept in PHP in Hindi/Urdu

Опубликовано: 17 Май 2026
на канале: Thakur Pavinder
2,187
47

The OOPs concept of Encapsulation in PHP means, enclosing the internal details of the object to protect from external sources. It describes, combining the class, data variables and member functions that work on data together within a single unit to form an object. Otherwise, its the bundling of properties and behavior in a single class unit.

Advantages of Encapsulation:
1) Data Hiding and Abstraction
2) Data security
3) Reduces complexity
4) Reusability
5) Reliability
6) Increased flexibility


Access Modifiers
Public, Protected,private