Permalink
Browse files

API CHANGE Removed LeftAndMain->getLastFormIn(), please use Form->for…

…mHtmlContent() instead

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/trunk@92738 467b73ca-7a2a-4603-9d3b-597d59a354a9
  • Loading branch information...
1 parent 8f82a04 commit 25ba16223a520b1e0a10aea8ffaabf7e69af81df @chillu chillu committed Nov 21, 2009
Showing with 3 additions and 10 deletions.
  1. +2 −1 code/CommentAdmin.php
  2. +0 −4 code/LeftAndMain.php
  3. +1 −5 code/ReportAdmin.php
View
@@ -31,7 +31,8 @@ public function init() {
}
public function showtable($params) {
- return $this->getLastFormIn($this->renderWith('CommentAdmin_right'));
+ $form = $this->getEditForm();
+ return $form->formHtmlContent();
}
public function Section() {
View
@@ -358,10 +358,6 @@ public function getitem() {
if($form) return $form->formHtmlContent();
else return "";
}
- public function getLastFormIn($html) {
- $parts = split('</?form[^>]*>', $html);
- return $parts[sizeof($parts)-2];
- }
//------------------------------------------------------------------------------------------//
// Main UI components
View
@@ -143,11 +143,7 @@ protected function showWithEditForm($params, $editForm) {
if(Director::is_ajax()) {
SSViewer::setOption('rewriteHashlinks', false);
- $result = $this->customise(array(
- 'EditForm' => $editForm
- ))->renderWith($this->getTemplatesWithSuffix('_right'));
-
- return $this->getLastFormIn($result);
+ return $form->formHtmlContent();
}
return array();

0 comments on commit 25ba162

Please sign in to comment.