What is encapsulation in oop php?
Answer / gokilavani s
Encapsulation is fundamental concepts in object oriented programming
Encapsulation provides three main benifits
Data hiding
Code organization
Code reusability
Php using access modifiers public, protected, private control access to the modified and properties
Public- accessible from anywhere
Protected - accessible within class and subclass
Private - accessible only in the class itself
| Is This Answer Correct ? | 0 Yes | 0 No |
What is the use of stripslashes in php?
How to check if a string contains a character or word in php?
What are the rules to determine the “truth” of any value which is not already of the boolean type?
What is the difference between implode() and explode() in php?
Why php is sometimes called as embedded scripting language?
What are php libraries?
What is trim codeigniter?
How to retrieve values out of an array?
Why php script is not running in browser?
how do we can copy of the content of a web page with the help og the URL and display them onto any other page
class Database { public static $_instance; public static function getInstance() { if(!isset(self::$_instance)) self::$_instance = new Database(DB_SERVER, DB_USER, DB_PASS, DB_NAME); print_r(self::$_instance); return self::$_instance; } } can any one explain "self::$_instance = new Database(DB_SERVER, DB_USER, DB_PASS, DB_NAME);" this line
In what are the ways you can encrypt the password ?