[mayaa-user:293] Re: Requestスコープに存在するかどうかの判定

t-doi @ ohns.co.jp t-doi @ ohns.co.jp
2006年 10月 6日 (金) 17:13:15 JST


土居です。


>suga です。
>
>On 10/6/06, t-doi @ ohns.co.jp <t-doi @ ohns.co.jp> wrote:
>> HTMLにて、例えば
>> <input id="first_name" type="text" value="" />
>
>念のため、この id は last_name ということで良いでしょうか。
はい。転記ミスでした。すみません。m(__)m


><m:echo m:id="last_name">
>  <m:if test="${customerForm != null}" >
>     <m:attribute name="value" value="${customerForm.getLastName()}" />
>  </m:if>
>  <m:doBody/>
></m:echo>
上記を試してみましたがダメでした。

<m:ifを
<m:if test="${request.getAttribute(&quot;customerForm&quot;) != null}" >
とするとうまく動くようになりました。ありがとうございます。m(__)m

ちなみにダメな場合のエラーは、
ReferenceError: "customerForm" is not defined. in script=
customerForm != null
と表示されます。


mayaa-user メーリングリストの案内