frustrated Posted November 10, 2006 Share Posted November 10, 2006 Hi, I'm wondering if there is some sort of function that you can pass an object to and it will reset all the properties of that object back to the original defaults values?Does anyone know of anything? Quote Link to comment Share on other sites More sharing options...
Zane Posted November 10, 2006 Share Posted November 10, 2006 just declare a new instance of that objecte.g[code=php:0]$foo = new Foo;$foo->name = "Bar";$foo->displayName();//prints Bar;$foo = new Foo$foo->displayName();//prints nothing at all[/code] Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.