“Knowing others is intelligence; knowing yourself is true wisdom. Mastering others is strength; mastering yourself is true power.”−Lao Tzu

Object Oriented PHP Seminar at UST EdTech Center

I headed for a scheduled seminar at the EdTech center located inside Benavides Library. This seminar was a collaborative effort of two organizations, ISyS and TomasinoWeb, both of which are headed by students from the IS program.logo The seminar was about PHP (PHP Hypertext Preprocessor), a scripting language embedded in HTML. I’m quite acquainted to this as I’ve been researching about this for the past months now. Unluckily, this topic is not included in our curriculum. But still, with the hope of finding a career in Web Development, I find myself utilizing every possible way of getting information about PHP.


The speaker of the event was no less than the UST webmaster himself, Mr. Jun Dolor. We’re quite acquainted with each other as he was the one who taught me and my colleagues last summer, at the TomWeb Summer Training, the Joomla CMS and many other things involving Web Development. The program started with a short prayer and an introduction of the speaker. Then after that, Mr. Dolor proceeded to show us some of his past and current projects. He also encouraged us to collaborate on his publishing about topics like “Building Online Apps using PHP”, “Joomla Templating Made Easy” and many more. These are all available on Google Docs and can be accessed with his permission.


The slide that he presented was entitled Object Oriented PHP. This was quite familiar back in my Java Programming days. He went through discussing familiar terms like instances, object and etc. He made an example out of a car, composing of an engine, a steering wheel, chassis, and so. He defined the term encapsulation and said that specific details of an object need to be kept private. Then he explained that classes can be thought of a blueprint or prototype that defines the variables and methods common to all objects of a certain kind. Developers can use class to create numerous objects repeatedly. An object combines data and instruction code that performs on that data. Each object has its own data, through the code within a class is shared for economy.  He also made clear some OOP terms like instance, which is an object created from a certain class, and instantiate, which is a process of creating a new object.


Mr. Dolor gave us a brief review on how to declare classes, instantiate objects, access attributes and accessing methods. He gave the meaning of a constructor which is a method that is called upon and executed upon creation of object. And its antonym, destructors which is called upon as soon as all references to a particular object is removed or when the object is explicitly destroyed. He made some explanation on static attributes which is also called class variables or class attributes. They can be accessed even without creating an object. On the other hand, they cannot be accessed with an instantiated class object. Attributes can be static by declaring it using the static keyword. They are allocated once regardless of how many objects are created. Then he gave an overview of static method that has similar traits with that of a static attribute.


A glimpse of member visibility followed and an explanation of abstract classes and methods. Abstract class according to Mr. Jun cannot be instantiated. They are meant to be sub classed and they can contain one or more abstract methods. Abstract methods however, are methods defined abstracts which declare the method’s signature. Unfortunately, these methods cannot have implementations. He gave some examples and asked someone from the audience to answer his questions. After these, he explained what is interface. He said that it provides a pure abstract class where all methods are abstract. It also provides a template for subclasses to implement. Interfaces are defined with the interface keyword. Classes that implement an interface should use the implements keyword. A class can subclass at most one class, but can implement several interfaces.


The speaker ended his talk with the explanation of final methods which are of nature, cannot be overridden. In an event a final method is overridden, a fatal error occurs.

Leave a Reply

CommentLuv Enabled
Please leave these two fields as-is: