Re: Sub groups ? - Programming structure...
| From: | Hugh Bothwell | Date: | Tue, 09 Apr 2002 14:34:05 +0000 |
| Subject: | Re: Sub groups ? - Programming structure... | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-92446@lists.php.net to get a copy of this message | ||
"Gordon Stewart" <gordonisnz@yahoo.co.nz> wrote in message
news:20020409133202.15530.qmail@pb1.pair.com...
> Hello, - I'm used (in years gone by) to the Qbasic programme, where i can
> create 'sub' routines, & view each routine on its own - Without reference
/
> Viewing the other code.. (I think its good like that..)..
Yes, I remember the QBasic editor too. Personally,
I found it horribly annoying, but (shrug) to each his own.
I don't know of any such for PHP, but you could probably
manage with a 'folding' text editor.
Note that in PHP (like Pascal) it is possible to define
functions-inside-functions; I haven't seen code that
actually uses this, but it's something to keep in mind.
> 1) Does PHP allow sub-routines, eg - I can send
> values to the routine, & it processes it & does
> whatever it requires & returns to the spot where I
> called it from.
yes, it's called a 'function'.
http://www.php.net/manual/en/functions.php
> 2) For those of you that know Qbasic & know
> what i mean, is/are there any programmes out
> there that can allow you to view / see any
> sub-routines in Perl and/or PHP one at a time,
> & list them ..
As above, don't know any offhand; but it should
be easy enough to write code to return you a
list of functions.