Reply to Operator Overloading

Your name:

Reply:


Posted by deciacco on 07/14/06 16:17

I was wondering if there was a way to do operator overlaoding in php
like you can in c++.

In c++ you can do something like:

cout << myobject; -- and have myobject handle the output.

Is there a way to...

echo myobject; -- and be able to have a custom definded method in
myobject do some kind of output?

Any other suggestions?
( I was thinking of having a custom method called echo in myobject so
one could do echo myobject->echo(); This is not as clean....)

Thanks!!

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация