Re: [PHP] Object Oriented Programming question

2010-03-12 Thread Rene Veerman
I also agree OOP is not a fad. Its a step up from procedural/including. And it's still evolving. While PHP is able to do polymorphism perfectly without OOP/classes, through "require($plugin/className); $varFunctionName ($p1, $p2, etc);", My newsscraper works very well that way. But if you want inh

Re: [PHP] Object Oriented Programming question

2010-03-12 Thread Ashley Sheridan
On Fri, 2010-03-12 at 06:49 -0800, Andrew Brookins wrote: > On Tue, Jan 19, 2010 at 7:11 AM, Ben Stones wrote: > > Hi, > > > > I've been learning about object oriented programming for the past few weeks > > and I've understood it pretty well, but I have one question. Usually with > > PHP scripts

Re: [PHP] Object Oriented Programming question

2010-03-12 Thread Andrew Brookins
On Tue, Jan 19, 2010 at 7:11 AM, Ben Stones wrote: > Hi, > > I've been learning about object oriented programming for the past few weeks > and I've understood it pretty well, but I have one question. Usually with > PHP scripts I make, all the functionality for a specific page is in the > actual PH

Re: [PHP] Object Oriented Programming question

2010-01-20 Thread tedd
At 11:18 AM -0500 1/20/10, Paul M Foster wrote: On Wed, Jan 20, 2010 at 10:11:18AM -0500, tedd wrote: While I teach OOP, I don't write any OOP for clients. My charge is to do things quickly and OOP requires a considerable amount of analysis before creating a solution. In most cases, I don

RE: [PHP] Object Oriented Programming question

2010-01-20 Thread tedd
At 11:31 AM -0500 1/20/10, Bob McConnell wrote: From: tedd At 10:26 AM -0500 1/19/10, Bob McConnell wrote: Some problems will fit into it, some don't. I teach OOP thinking at the local college and haven't run into a problem that doesn't fit. For example, in my last class I had a woman w

Re: [PHP] Object Oriented Programming question

2010-01-20 Thread J Ravi Menon
Hi Bob, [Couldn't resist jumping into this topic :)] Even if you look at traditional unix (or similar) kernel internals, although they tend to use functional paradigms, they do have a OOP-like flavor. Example: Everything in a unix system is a 'file' (well not really with networking logic, but it

RE: [PHP] Object Oriented Programming question

2010-01-20 Thread Bob McConnell
From: tedd > At 10:26 AM -0500 1/19/10, Bob McConnell wrote: >> Some problems will fit into it, some don't. > > I teach OOP thinking at the local college and haven't run into a > problem that doesn't fit. For example, in my last class I had a woman > who wanted to pick out a blue dress for her

Re: [PHP] Object Oriented Programming question

2010-01-20 Thread Paul M Foster
On Wed, Jan 20, 2010 at 10:11:18AM -0500, tedd wrote: > > While I teach OOP, I don't write any OOP for clients. My charge is to > do things quickly and OOP requires a considerable amount of analysis > before creating a solution. In most cases, I don't have the time. > Besides, I'm more of an agi

Re: [PHP] Object Oriented Programming question

2010-01-20 Thread Kim Madsen
tedd wrote on 20/01/2010 16:11: At 10:26 AM -0500 1/19/10, Bob McConnell wrote: Some problems will fit into it, some don't. I teach OOP thinking at the local college and haven't run into a problem that doesn't fit. For example, in my last class I had a woman who wanted to pick out a blue dre

Re: [PHP] Object Oriented Programming question

2010-01-20 Thread Richard Quadling
2010/1/20 tedd : > Also IMO, one can argue the advantages that OOP and Design Patterns bring to > the table over procedural, but after all is said and done, if you know your > stuff in procedural, OOP is not going to provide you with much that you > don't already have. You also have to consider th

Re: [PHP] Object Oriented Programming question

2010-01-20 Thread Robert Cummings
Jay Blanchard wrote: [snip] My viewpoint may be jaundiced from having programmed in C++, but the polymorphism of PHP seems a little crippled by comparison. [/snip] I wholeheartedly agree, but I figured out how to work with it in PHP to my advantage and the advantage of my team. It'll get better.

RE: [PHP] Object Oriented Programming question

2010-01-20 Thread Jay Blanchard
[snip] My viewpoint may be jaundiced from having programmed in C++, but the polymorphism of PHP seems a little crippled by comparison. [/snip] I wholeheartedly agree, but I figured out how to work with it in PHP to my advantage and the advantage of my team. It'll get better... -- PHP General Mai

Re: [PHP] Object Oriented Programming question

2010-01-20 Thread Paul M Foster
On Wed, Jan 20, 2010 at 06:47:04AM -0600, Jay Blanchard wrote: > [snip] > > Another advantage of OOP that is difficult to > > provide via the procedural paradigm is polymorphism. > > Agreed. Though the advantages of polymorphism are questionable, > depending on your viewpoint. > [/snip] > > In a

RE: [PHP] Object Oriented Programming question

2010-01-20 Thread tedd
At 10:26 AM -0500 1/19/10, Bob McConnell wrote: Some problems will fit into it, some don't. I teach OOP thinking at the local college and haven't run into a problem that doesn't fit. For example, in my last class I had a woman who wanted to pick out a blue dress for her upcoming wedding anni

RE: [PHP] Object Oriented Programming question

2010-01-20 Thread Jay Blanchard
[snip] > Another advantage of OOP that is difficult to > provide via the procedural paradigm is polymorphism. Agreed. Though the advantages of polymorphism are questionable, depending on your viewpoint. [/snip] In a loosely typed language like PHP that advantages of polymorphism far outweigh any

Re: [PHP] Object Oriented Programming question

2010-01-19 Thread Paul M Foster
On Tue, Jan 19, 2010 at 01:12:49PM -0500, Robert Cummings wrote: > > I would have to agree that OOP is not a fad, perhaps over-hyped at > times, but definitely not a fad. The argument about class dependencies > is an invalid argument since functions will also have dependencies on > other functio

Re: [PHP] Object Oriented Programming question

2010-01-19 Thread Robert Cummings
Ashley Sheridan wrote: On Tue, 2010-01-19 at 12:30 -0500, Paul M Foster wrote: On Tue, Jan 19, 2010 at 03:11:56PM +, Ben Stones wrote: Hi, I've been learning about object oriented programming for the past few weeks and I've understood it pretty well, but I have one question. Usually with

Re: [PHP] Object Oriented Programming question

2010-01-19 Thread Paul M Foster
On Tue, Jan 19, 2010 at 05:44:56PM +, Ashley Sheridan wrote: > > Oh, and your flame suit failed because you forgot the quotation marks around > the attribute values, and you didn't close the tag :p Dang! I *thought* it felt awfully warm in here. Paul -- Paul M. Foster -- PHP General M

Re: [PHP] Object Oriented Programming question

2010-01-19 Thread Ashley Sheridan
On Tue, 2010-01-19 at 12:30 -0500, Paul M Foster wrote: > On Tue, Jan 19, 2010 at 03:11:56PM +, Ben Stones wrote: > > > Hi, > > > > I've been learning about object oriented programming for the past few weeks > > and I've understood it pretty well, but I have one question. Usually with > > PH

Re: [PHP] Object Oriented Programming question

2010-01-19 Thread Paul M Foster
On Tue, Jan 19, 2010 at 03:11:56PM +, Ben Stones wrote: > Hi, > > I've been learning about object oriented programming for the past few weeks > and I've understood it pretty well, but I have one question. Usually with > PHP scripts I make, all the functionality for a specific page is in the >

Re: [PHP] Object Oriented Programming question

2010-01-19 Thread Ashley Sheridan
On Tue, 2010-01-19 at 15:11 +, Ben Stones wrote: > Hi, > > I've been learning about object oriented programming for the past few weeks > and I've understood it pretty well, but I have one question. Usually with > PHP scripts I make, all the functionality for a specific page is in the > actual

Re: [PHP] Object Oriented Programming question

2010-01-19 Thread Floyd Resler
Ben, I use a combination of procedural and OOP in my scripts. It depends on my needs. As an example, I use OOP for gathering order information. I created a class which gathers all the order information allowing me to easily access any piece of data in the order. I could do this with

RE: [PHP] Object Oriented Programming question

2010-01-19 Thread Bob McConnell
From: Ben Stones > I've been learning about object oriented programming for the past few weeks > and I've understood it pretty well, but I have one question. Usually with > PHP scripts I make, all the functionality for a specific page is in the > actual PHP file, and I'd use PHP functions in a sep

[PHP] Object Oriented Programming question

2010-01-19 Thread Ben Stones
Hi, I've been learning about object oriented programming for the past few weeks and I've understood it pretty well, but I have one question. Usually with PHP scripts I make, all the functionality for a specific page is in the actual PHP file, and I'd use PHP functions in a separate directory which