RE: Questions for OOP Beginner:

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thanks Hari for taking a shot at an explanation.

I have found some code using mysql queries inside a class, but the code does
not show how it is actually implemented inside a program.  The information I
found is useful in writing my own scripts, but not useful in answering some
of my broader questions.

Thanks,

Gentlemike2


  -----Original Message-----
  From: php-objects@xxxxxxxxxxxxxxx [mailto:php-objects@xxxxxxxxxxxxxxx]On
Behalf Of Hari KT
  Sent: Sunday, March 08, 2009 3:17 PM
  To: php-objects@xxxxxxxxxxxxxxx
  Subject: Re:  Questions for OOP Beginner:


  Hello man ,
  Don't know I may be wrong sometimes, so if so I am sorry

  1) If I need data from another object is it correct or proper to use the
attribute of one object passed to the constructor of another object?For this
, you can extend a class, then why you need to bother about passing to
constructor ?
  Also I dont think passing an abject is not bad ........ :)
  2) Is correct or proper to instantiate a new object inside the class of
another object (either in a public method or inside the constructor
method)?You can do this , bcoz we call the parent class like the same
......... :) Basics of Inheritence .

  3) I read one author who said the results of queries to a mysql database
should be their own objects. Can some one point me to some examples or
explain how they have put this into practice?There is lots of manuals
available in php.net
  Have  a search for mysqli , You can see a lot there ................Hari K
T

  http://www.harikt.com/










  Add more friends to your messenger and enjoy! Go to
http://messenger.yahoo.com/invite/

  [Non-text portions of this message have been removed]


  


[Non-text portions of this message have been removed]


[Index of Archives]     [PHP Home]     [PHP Users]     [PHP Soap]     [Kernel Newbies]     [Yosemite]     [Yosemite Campsites]

  Powered by Linux