diff options
author | xue <> | 2006-02-17 21:14:12 +0000 |
---|---|---|
committer | xue <> | 2006-02-17 21:14:12 +0000 |
commit | cba0c1b472cec22e4ffed2b3b084bea27cd26582 (patch) | |
tree | 9a8f8383a93ebb011757423bfc8b39066cb017ea /framework/Web/UI/WebControls | |
parent | 35836e45fab30dc4c31a4f51e32b551181e7ec86 (diff) |
Fixed #54.
Diffstat (limited to 'framework/Web/UI/WebControls')
-rw-r--r-- | framework/Web/UI/WebControls/TContent.php | 2 | ||||
-rw-r--r-- | framework/Web/UI/WebControls/TContentPlaceHolder.php | 5 |
2 files changed, 3 insertions, 4 deletions
diff --git a/framework/Web/UI/WebControls/TContent.php b/framework/Web/UI/WebControls/TContent.php index f2c6f0ac..0ccc57f8 100644 --- a/framework/Web/UI/WebControls/TContent.php +++ b/framework/Web/UI/WebControls/TContent.php @@ -41,7 +41,7 @@ class TContent extends TControl implements INamingContainer {
if(($id=$this->getID())==='')
throw new TConfigurationException('content_id_required');
- $this->getTemplateControl()->registerContent($this);
+ $this->getTemplateControl()->registerContent($id,$this);
}
}
diff --git a/framework/Web/UI/WebControls/TContentPlaceHolder.php b/framework/Web/UI/WebControls/TContentPlaceHolder.php index a13e85bc..9cf5068c 100644 --- a/framework/Web/UI/WebControls/TContentPlaceHolder.php +++ b/framework/Web/UI/WebControls/TContentPlaceHolder.php @@ -41,9 +41,8 @@ class TContentPlaceHolder extends TControl {
if(($id=$this->getID())==='')
throw new TConfigurationException('contentplaceholder_id_required');
- $loc=$parent->getHasControls()?$parent->getControls()->getCount():0;
- $this->getTemplateControl()->registerContentPlaceHolder($id,$parent,$loc);
- $parent->unregisterObject($id);
+ $this->getTemplateControl()->registerContentPlaceHolder($id,$this);
+ $parent->getControls()->add($this);
}
}
|