On Mon, 2002-11-25 at 10:57, Dan Field wrote:
> is it doable?
well I found a way. It's a bit of a hack but FYI heres how it works:
function Form() {
// a slight hack which allows us to overload
// constructors by the number of args
$name = "Form".func_num_args();
At 11:57 25.11.2002, Dan Field said:
[snip]
>is it doable?
>
>class myClass {
> var $myInt;
>
> // default constructor
> function myClass() {
> }
>
> // overloaded constructor
> function myClass($newInt) {
>
is it doable?
ie
class myClass {
var $myInt;
// default constructor
function myClass() {
}
// overloaded constructor
function myClass($newInt) {
$this->myInt = $newInt;
}
}
--
Dan Field
Systems Development Offi
3 matches
Mail list logo