You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Roland Carlsson <ro...@swetravel.se> on 2002/12/17 15:34:56 UTC

logic:present

Hi!
I got a small problem with finding an object in the request-scope.

In an Action I have the following line:

request.setAttribute("rdc_shop_Login_loginById", login);

Then I have a .jsp-page with the following:

<logic:present name="rdc_state_Login_loginById" scope="request">
found a Login
</logic:present>

To verify that I actually got the object in the scope I test later in the page:
<%
    rdc.shop.entity.Login rdc_state_Login_loginById = (rdc.shop.entity.Login) request.getAttribute("rdc_shop_Login_loginById");
    out.println(rdc_state_Login_loginById);
%>

And it outputs: rdc.shop.entity.Login@9fdee 

Why doesn't logic:present find the object?

Thanks in advance
Roland Carlsson


Re: logic:present

Posted by Roland Carlsson <ro...@swetravel.se>.
I'm sorry. I should have told what's where wrong.

rdc_shop_Login_loginById
!=
rdc_state_Login_loginById

One would think that one should see these things but I missed until I look
at my quiestion again.

Regards
Roland

----- Original Message -----
From: "Roland Carlsson" <ro...@swetravel.se>
To: "Struts Users Mailing List" <st...@jakarta.apache.org>
Sent: Tuesday, December 17, 2002 3:55 PM
Subject: Re: logic:present


> Ignore my last please. I must be in need of some sleep or coffe...
>
> Hope that I didn't make anyone work
>
> Thanks
> Roland
>
>
> ----- Original Message -----
> From: "Roland Carlsson" <ro...@swetravel.se>
> To: "Struts Users Mailing List" <st...@jakarta.apache.org>
> Sent: Tuesday, December 17, 2002 3:34 PM
> Subject: logic:present
>
>
> Hi!
> I got a small problem with finding an object in the request-scope.
>
> In an Action I have the following line:
>
> request.setAttribute("rdc_shop_Login_loginById", login);
>
> Then I have a .jsp-page with the following:
>
> <logic:present name="rdc_state_Login_loginById" scope="request">
> found a Login
> </logic:present>
>
> To verify that I actually got the object in the scope I test later in the
> page:
> <%
>     rdc.shop.entity.Login rdc_state_Login_loginById =
> (rdc.shop.entity.Login) request.getAttribute("rdc_shop_Login_loginById");
>     out.println(rdc_state_Login_loginById);
> %>
>
> And it outputs: rdc.shop.entity.Login@9fdee
>
> Why doesn't logic:present find the object?
>
> Thanks in advance
> Roland Carlsson
>
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: logic:present

Posted by Roland Carlsson <ro...@swetravel.se>.
Ignore my last please. I must be in need of some sleep or coffe...

Hope that I didn't make anyone work

Thanks
Roland


----- Original Message -----
From: "Roland Carlsson" <ro...@swetravel.se>
To: "Struts Users Mailing List" <st...@jakarta.apache.org>
Sent: Tuesday, December 17, 2002 3:34 PM
Subject: logic:present


Hi!
I got a small problem with finding an object in the request-scope.

In an Action I have the following line:

request.setAttribute("rdc_shop_Login_loginById", login);

Then I have a .jsp-page with the following:

<logic:present name="rdc_state_Login_loginById" scope="request">
found a Login
</logic:present>

To verify that I actually got the object in the scope I test later in the
page:
<%
    rdc.shop.entity.Login rdc_state_Login_loginById =
(rdc.shop.entity.Login) request.getAttribute("rdc_shop_Login_loginById");
    out.println(rdc_state_Login_loginById);
%>

And it outputs: rdc.shop.entity.Login@9fdee

Why doesn't logic:present find the object?

Thanks in advance
Roland Carlsson



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>