0

I am trying to call a form from within another form. I need it to come in as a subform. However, I cannot merely extend it as both forms extend different things that are required.

This is kind of what I was thinking but it doesn't work:

    $subForm3 = new Form_CreateEventInformation();

Basically create a subform3 from the form CreateEventInformation.

4

1 に答える 1

1

あなたの質問は少し漠然としていますが、私はできる限り答えます。

別のフォーム内でフォームを呼び出す:

class Form_WhichNeedsCreateEventInformation
extends Form_BaseClass
{
 public function init()
 { 
  $this->addSubForm(new Form_CreateEventInformation(),'createEventInformationForm');
 }
}

class Form_CreateEventInformation
extends Form_BaseClass
{
 public function init()
 {
 }
}

これがあなたの求めているものだと思いますが、すでに試してみて、うまくいかないことについて言及したようですか?つまり、正確には何が問題なのですか?

これが正しくない場合は、さらに情報を提供してください。より効果的な方法であなたを助けることができるように。:)

于 2010-01-14T01:41:39.253 に答える