Hi As a complement to the answers you have had here I wish to ammend the following.
The Run in the example is a function, and because this function is inside a
Class object, it is called a method.
A class is a set of variables (properties) and functions (methods) that you
can create instances of.
I suggest you consult the complete php documentation with user comments and
examples at php.net. Available in many languages. This manual is used by
many -including me- on a daily basis.
Hope this helps
With kind regards
Andy
On Tuesday 27 September 2005 22:29, Lowell Herbert wrote:
> On Sep 27, 2005, at 4:19 PM, Jasper Bryant-Greene wrote:
> > Lowell Herbert wrote:
> >> Thanks for all the responses. I understand that $site is an
> >> instance of the class CSite, and that Run() is a function in that
> >> class. I do not understand what the operater "->" means, and
> >> what meaning the result of the function Run() has to $site.
> >> Clarification anyone?
> >
> > The operator -> in this context ( $site->Run() ) sort of means "the
> > function Run() inside the object $site".
> >
> > The result of the function (if there is one) is thrown away,
> > because you don't assign it to anything. If you did this then it
> > would be assigned to something:
> >
> > $result = $site->Run();
>
> Thank you for your clear explanation!!!
> Lowell
--
Registered Linux User Number 379093
Now listening to [silence]
amaroK::the Coolest Media Player in the known Universe!
Cockroaches and socialites are the only things that can
stay up all night and eat anything.
Herb Caen
--
-- --BEGIN GEEK CODE BLOCK-----
Version: 3.1
GAT/O/>E$ d-(---)>+ s:(+)>: a--(-)>? C++++$(+++) UL++++>++++$ P-(+)>++
L+++>++++$ E---(-)@ W+++>+++$ !N@ o? !K? W--(---) !O !M- V-- PS++(+++)
PE--(-) Y+ PGP++(+++) t+(++) 5-- X++ R*(+)@ !tv b-() DI(+) D+(+++) G(+)
e>++++$@ h++(*) r-->++ y--()>++++
-- ---END GEEK CODE BLOCK------
--
Check out these few php utilities that I released
under the GPL2 and that are meant for use with a
php cli binary:
http://www.vlaamse-kern.com/sas/
--
pgpfMLvuAfYVj.pgp
Description: PGP signature

