PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
lets say I want to uniquely identify each object class. Each one will have a mykey ID. In this example
parent::printmykey() will also print 2. I was expecting 1, but I guess as soon as the key is redefined in the child the parent value is lost. Is there a way to get 1 from the parent::printmykey() call?
(hint without redifining the printmykey function)
Note: Using the class name for scope resolution to access the static variable. Using keyword 'self' is a better option, but I don't think that is defined in PHP4. Switch to PHP5 if possible. Much better OOP support.
thank you. I am using php5. I had a small lapse in memory functions. forgot about the static. Maybe is time to take a break.
Soon I will forget my own name