Lunarpages Web Hosting
 
Home Register FAQ Members List Calendar Search Today's Posts Mark Forums Read Web Directory

Go Back   Webmaster Forum > Designing and Developing Websites > Programming > PHP / MySQL

PHP / MySQL Discussions and help on PHP and MySQL.

Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old 01-11-2008, 09:43 AM
c4cyber's Avatar
c4cyber c4cyber is offline
WMG Resident Alien
 
Join Date: Nov 2007
Location: asia
Posts: 243
iTrader: (0)
c4cyber is on a distinguished road
Default OOP in PHP

php grew so fast in popularity, and now it has object oriented concepts involved. I've been using php for some 2 years, and i wonder if someone prefers to code in oop way or structred approach is widely accpeted and used?
__________________
Reply With Quote
Sponsored Links
Register and sign in to hide this ad block

  #2 (permalink)  
Old 01-14-2008, 04:31 AM
creek23 creek23 is offline
WMG Deputy Sheriff
 
Join Date: Mar 2007
Posts: 290
iTrader: (0)
creek23 is on a distinguished road
Default

oop was added in PHP 5, which was pre-released much earlier than you thought. there has been a lot og threads discussing such question you have.
Reply With Quote
  #3 (permalink)  
Old 01-18-2008, 02:11 PM
blokey blokey is offline
WMG Resident Alien
 
Join Date: Mar 2007
Posts: 93
iTrader: (0)
blokey is on a distinguished road
Default

Not so. Support for classes and objects has been present since PHP 3, released in 1998.

It was, of course, much improved in version 5.
Reply With Quote
  #4 (permalink)  
Old 01-19-2008, 12:22 AM
creek23 creek23 is offline
WMG Deputy Sheriff
 
Join Date: Mar 2007
Posts: 290
iTrader: (0)
creek23 is on a distinguished road
Default

oh. that was called object-based -- not object-oriented.

Microsoft told the world that VB6 is OOP but OOP programmers call it OBP simply because inheritance is not present in VB6 -- also in PHP3.
Reply With Quote
  #5 (permalink)  
Old 01-22-2008, 12:06 PM
blokey blokey is offline
WMG Resident Alien
 
Join Date: Mar 2007
Posts: 93
iTrader: (0)
blokey is on a distinguished road
Default

Call it what you like, object orientated programming is encapsulating functionality within objects.

PHP3 does support inheritance, btw.
Reply With Quote
  #6 (permalink)  
Old 01-24-2008, 02:14 AM
creek23 creek23 is offline
WMG Deputy Sheriff
 
Join Date: Mar 2007
Posts: 290
iTrader: (0)
creek23 is on a distinguished road
Default

i happen to retrieve a PHP3 manual from:
http://www.polytech.unice.fr/~buffa/.../td5/php/docs/

which states that, indeed, inheritance does exists in PHP3.

althought, one question still remains... WHAT was "IMPROVED" in PHP5?
Reply With Quote
  #7 (permalink)  
Old 01-24-2008, 03:33 AM
creek23 creek23 is offline
WMG Deputy Sheriff
 
Join Date: Mar 2007
Posts: 290
iTrader: (0)
creek23 is on a distinguished road
Default

once again, my memory failed me.

it was actually "polymorphism" which was not present in PHP3.

read this one:
http://www.techsupportalert.com/pdf/t1837.pdf
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

All times are GMT. The time now is 08:26 PM.



Freelance Web Designers
Work At Home Forum
Ad Marketplace
Online Deals and Bargains
Go Daddy $1.99 Domains Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO 3.0.0