by Dinesh Thakur Category: PHP (Hypertext Preprocessor)

PHP has made a big step forward in object-oriented programming with version 5. Since this version, it allows to implement methods in predefined behavior by PHP. These methods are called "magic methods", the __set () and __get () are included.

 
by Dinesh Thakur Category: PHP (Hypertext Preprocessor)

The exception mechanism was introduced in version PHP 5 in addition to its new object-oriented model. Just as in Java, C ++, ActionScript 3, or Visual Basic (to name only these programming languages), exceptions to simplify, personalize and organize the management "errors" in a computer program. Here the word "errors" does not mean "bug", which is an abnormal behavior of the developed application, but "exceptional cases" to treat differently in the program sequence. Let us therefore how the exceptions.



 
by Dinesh Thakur Category: PHP (Hypertext Preprocessor)

In most professional developments, it is necessary to know proper structure of their application in order to facilitate its design and maintenance. The "design patterns", is one of the best solutions to this problem. With the new model object-oriented PHP 5 similar to that of Java, the implementation of design patterns is facilitated. This tutorial focuses on the presentation and implementation of the Singleton pattern, especially used in web applications.

 
by Dinesh Thakur Category: PHP (Hypertext Preprocessor)

Cookies are small files that can be written by a PHP script or other languages, such as JavaScript, on the visitor's computer. The cookie mechanism was invented by Netscape in the bearing purposes to some HTTP protocol weaknesses but also to extend the possibilities of relationship between the client and the website. Their function is storage, for a given period, of information relating to the user (his nickname, his last login date, age, preferences ...).



 
by Dinesh Thakur Category: PHP (Hypertext Preprocessor)

Among the most important concepts of the programming is the concept of variable. Like any language, PHP handles data. For a dynamic site, these data are variables. In addition, they may be of different types, such as text string, as you have used the echo statement in the form of whole or decimal numbers or as true or false boolean values (TRUE or FALSE). These basic types are the most used, but there are others who may be compounds types, such as arrays and objects, or specific types, as resource or NULL. . We will see that the variable part of the mechanisms which make a dynamic application. Let's get into the thick of it.

 
by Dinesh Thakur Category: PHP (Hypertext Preprocessor)

This tutorial follows the one on conditional statements. The loops are a trivial principle of computing that any developer must master. They are, too, some of the control structures. PHP 4 into account, each with its specific characteristics: for (), while (), do-while () and foreach ().

 
by Dinesh Thakur Category: PHP (Hypertext Preprocessor)

PHP integrates another concept of object-oriented programming: abstract classes. This course defines and introduces the concept of abstract classes. We will present what abstract classes, what they are used for development and how to declare and use them. Finally, we will study the particular case of final classes and methods involved in the security of the code object oriented programming.

 
by Dinesh Thakur Category: PHP (Hypertext Preprocessor)

Object-oriented programming (OOP) was integrated into the PHP version 3 in 1998, including basic class and object supportIn 2000, PHP4 added some functionality, but suffered from its non-intuitive handling of references with objects handled like value types.

Finally, in 2004, PHP5 included an extensive rewrite of object handling with the introduction of Zend Engine 2, featuring a comprehensive feature set and increased performance.

But at that time, the PHP object model was far too brief. We could really talk about object oriented programming. PHP Developers are then examined the issue and improved the object model that, since version 5, has nothing to envy to other objects languages like Java or C++.

 
by Dinesh Thakur Category: PHP (Hypertext Preprocessor)

The conditional structure "foreach" when you allowed to browse the contents of a table. With version 5 of PHP, you can now browse an entire object to retrieve its properties.

 
by Dinesh Thakur Category: PHP (Hypertext Preprocessor)

The vast majority of dynamic websites or applications need to reuse parts of identical code in several places of the same page, or in several different pages. This is the case for example libraries of user functions or configuration files. Rather than rewrite each time the code, there are functions (actually language constructs) that can import and execute the code reuse in the page. These are the include () and require ().

 

Page 2 of 4

About Dinesh Thakur

Dinesh ThakurDinesh Thakur holds an B.SC (Computer Science), MCSE, MCDBA, CCNA, CCNP, A+, SCJP certifications. Dinesh authors the hugely popular blog. Where he writes how-to guides around Computer fundamental , computer software, Computer programming, and web apps. For any type of query or something that you think is missing, please feel free to Contact us.



Search Content