Web O-O programming?
Results 1 to 5 of 5

Thread: Web O-O programming?

  1. #1
    Senior Member roswell1329's Avatar
    Join Date
    Jan 2002
    Posts
    670

    Question Web O-O programming?

    I've been reading several texts on the more advanced uses of PHP and object-oriented (O-O) programming, and I'm intrigued. I have never attempted object-oriented programming (I'm mostly a PERL scripter and a procedural PHP programmer, but the O-O style is fascinating and I wanted to attempt a project that used it for my first foray into the style. I would like to create a web-forum for my own website from scratch, and I'm wondering if O-O would be a cleaner way to go for the overall design (rather than a CSS or PHP procedural-style approach)? Basically, I'm thinking that each posting would be an object with several similar attributes (using AO as an example, each post is made up of an avatar, posting, navigation/editing buttons, etc.) and their own methods (again, using AO, each post can be edited, deleted, quoted, duplicated, etc.). This may sound ridiculous to any experienced O-O programmers out there, but I'm still trying to find a really good use of O-O on the web, and a web-forum was the best I could come up with. Thoughts?
    /* You are not expected to understand this. */

  2. #2
    Senior Member
    Join Date
    Jun 2002
    Posts
    165
    yes object oriented programming is definately applicable to web applications like a message or bulletin board. another avenue i would suggest focusing some time on, if you haven't already, is data modeling. oo design and data design almost go hand-in-hand, and no place better than the web. doing so will help to identify proper placement of object properties.

    in most instances a class can be a direct reflection of the storage layout for the data. in other instances it makes more sense to divide the data in different ways physically (to maintain a specific level of normalcy) and logically present it in the way envisioned.

    as far as some projects to get you started; a bbs is an excellent one. the possibilities are really endless: web-based email, messaging, host/network/service management, job search, project management, billing and accounting systems, shopping carts (there's just something repulsive about that phrase)...calendaring, group-calendaring,...,....,....

    but ultimately i would built something that you will want to use on your own and share with others. -or- that you can sell and bring in the dough with.
    -droby10

  3. #3
    Senior Member
    Join Date
    Apr 2002
    Posts
    324
    Roswell >

    if I might point you in the direction of my latest tut
    entitled Web based classes. This is an example of how web based object orientation works (for ASP, but the priciples of scope and instantiation that I discuss are similar in any language. For example - in PHP you would reference the HR class that I discuss via HR -> method rather than HR.method)

    Hope this helps
    \"I may not agree with what you say, but I will defend to the death your right to say it.\"
    Sir Winston Churchill.

  4. #4
    Senior Member roswell1329's Avatar
    Join Date
    Jan 2002
    Posts
    670
    Excellent tutorial ntsa, and great suggestions droby10! Thanks for the help! I'm a bit more confident in tackling my forum page.
    /* You are not expected to understand this. */

  5. #5
    Senior Member
    Join Date
    Mar 2002
    Posts
    502
    Originally posted here by droby10
    yes object oriented programming is definately applicable to web applications like a message or bulletin board. another avenue i would suggest focusing some time on, if you haven't already, is data modeling. oo design and data design almost go hand-in-hand, and no place better than the web. doing so will help to identify proper placement of object properties.

    in most instances a class can be a direct reflection of the storage layout for the data. in other instances it makes more sense to divide the data in different ways physically (to maintain a specific level of normalcy) and logically present it in the way envisioned.

    as far as some projects to get you started; a bbs is an excellent one. the possibilities are really endless: web-based email, messaging, host/network/service management, job search, project management, billing and accounting systems, shopping carts (there's just something repulsive about that phrase)...calendaring, group-calendaring,...,....,....

    but ultimately i would built something that you will want to use on your own and share with others. -or- that you can sell and bring in the dough with.
    Right On! Tottaly agree.
    Bleh.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •