* Thus wrote Comex ([EMAIL PROTECTED]):
> <[EMAIL PROTECTED]>
> Jack Lee:
> > //I have an array a[] like this:
> >
> > <?php
> > $a[]=0;
> >
> > //How to define and use it in a function like this?
> >
> > function myfunc(something)
> > {
> > echo $a[0]; //got error here!!!! Notice: Undefined variable:
> >
> > }
> >
> >>
> > //Thanks for any help.!!!
>
> global $a;
Ouch!
Sometimes I wish global didn't exist
Curt
--
"I used to think I was indecisive, but now I'm not so sure."
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php