> -----Original Message-----
> From: Khalid El-Kary [mailto:[EMAIL PROTECTED]]
> Sent: Saturday, December 07, 2002 6:03 PM
> To: [EMAIL PROTECTED]
> Subject: Re: [PHP] Help on OOP
> 
> hi,
> a function can be defined from inside another function!
> this works here:
> 
> <?php
> 
> function howru()
> {
> function hi()
> {
> echo "hi,";
> }
> hi();echo "how r u";
> }
> 
> howru();
> hi();
> 
> ?>
> 
> this gives the same result:
> 
> <?php
> function hi()
> {
> echo "hi,";
> }
> function howru()
> {
> hi();echo "how r u";
> }
> 
> howru();
> hi();
> 
> ?>
> 
> It seems that even calling the function again from any place works!


So what your saying is that the hi() function's scope in the top example
is not limited to the howru() function.



> 
> Regards,
> Khalid al-kary
> 
> _________________________________________________________________
> Protect your PC - get McAfee.com VirusScan Online
> http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963
> 
> 
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 
> 
> ---
> Incoming mail is certified Virus Free.
> Checked by AVG anti-virus system (http://www.grisoft.com).
> Version: 6.0.426 / Virus Database: 239 - Release Date: 12/2/2002
>

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.426 / Virus Database: 239 - Release Date: 12/2/2002
 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to