redho home | products | services

Programming Forums


Community for Java, PHP, Perl C, ASP and Python programmers
Saturday 17 November 2018 13:46

Ask your IT question here

Redefining PHP Classes



 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Programming Forums -> PHP programming forum
View previous topic :: View next topic  
Author Message
gilbertsavier
New Programmer


Joined: 02 Jul 2009
Posts: 21
Hello,
Hey there,

I have a class A that uses class B. Class B also uses class A. This is recursive and am wondering if you can redefine PHP classes like in C++.

class A{}

class B{
private $classA;

public function __construct($classA){
$this->classA = $classA;
}

public function someFunc(){ echo 'blah'; }
}

class A{
private $classB;

public function __construct($classB){
$classB->someFunc();
}
}
_________________
Thanks & regards
Lokananth

Live Chat Software By miOOt

Reply with quote
 
Page 1 of 1
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Programming Forums -> PHP programming forum


Dubai Forums - Expat Help | Vegan Forum | Java Programming | 3d Design Resources | 3d Forum | 3D Jobs | 3D Textures | Paris Forum | Europe Forum
Dubai Classifieds | Dubai Property | Jobs in Dubai | Free London Classifieds | Jobs in London UK

High Quality, Custom 3d animation and Web Design solutions Royal Quality Web Hosting Services Vegetarian and Animal Rights news

© 2018 RedHo