śr., 26 mar 2025 o 09:38 Lidin NT napisał(a):
> Why is ServletActionContext.getRequest() returning null in JSP?
Calling JSPs directly is a Bad Idea
https://struts.apache.org/security/#never-expose-jsp-files-directly
And calling JSPs directly means you skip the whole Action related
machin
s 7 application and facing an issue where userViewUtil is
showing an empty value in JSP. Setup:
I'm using and to create and set values in JSP:
When I try to display the values, they are empty:
Code Details:
UserViewUtilWrapper Class:
This is the method from UserViewUtilWr
Hi all,
I'm working on a Struts 7 application and facing an issue where userViewUtil is
showing an empty value in JSP. Setup:
I'm using and to create and set values in JSP:
When I try to display the values, they are empty:
Code Details:
UserViewUtilWra
> > From: Yaragalla Muralidhar
> > To: Struts Users Mailing List ,
> > Date: 27.08.2015 11:17
> > Subject: How to access a map in jsp
> >
> > Hi,
> > the following is the code in action class
> >
> > //
oaMap.[", it should
be "oaMap["
Regards,
Christoph
Yaragalla Muralidhar schrieb am 27.08.2015
11:17:06:
> From: Yaragalla Muralidhar
> To: Struts Users Mailing List ,
> Date: 27.08.2015 11:17
> Subject: How to access a map in jsp
>
> Hi,
pes=dtService.getAllOrganisumTypes();
oaMap=dtService.getAllSelectedOrganismTypeAntibiotics();
}catch(Exception e){
log.error(e.getMessage(), e);
return "error";
}
return SUCCESS;
}
//_
The following is the code in jsp
checked value=&
>
> I am using struts 1 because of company policy.
>
>
With struts1 you can use JSTL EL, too. The form bean names are available
in EL. And struts1 has it's own tag lib.
regards,
Christoph
This Email was scanned by Sophos Anti Virus
I am using struts 1 because of company policy.
On Monday, December 29, 2014 11:20 PM, Sreekanth S. Nair
wrote:
Sure you can, please if you are using struts2 please read these tutorials
Struts2 Tag lesson
http://www.tutorialspoint.com/struts_2/
or
http://struts.apache.org/docs/tag-re
Sure you can, please if you are using struts2 please read these tutorials
Struts2 Tag lesson
http://www.tutorialspoint.com/struts_2/
or
http://struts.apache.org/docs/tag-reference.html
and a bit of JSP EL
http://www.tutorialspoint.com/jsp/jsp_expression_language.htm
--
Thanks & Regards
Sreek
The following Java scriptlet code in a Struts jsp is working fine.
However, is it possible to change the jsp code so as to remove all the Java
scriptlet codes?
The .jsp code is like this:<%
HttpSession httpSession = request.getSession(true);
MyClient myClient = (MyClient)httpSession.getAttr
ide some solutions
> --Original Message--
> From: Emi Lu
> To: user@struts.apache.org
> ReplyTo: Struts Users Mailing List
> ReplyTo: em...@encs.concordia.ca
> Subject: put ArrayList to s:hidden in jsp?
> Sent: Oct 18, 2012 7:45 PM
>
> Good morning,
>
> Is there a
: Struts Users Mailing List
ReplyTo: em...@encs.concordia.ca
Subject: put ArrayList to s:hidden in jsp?
Sent: Oct 18, 2012 7:45 PM
Good morning,
Is there a way to put hidden ArrayList in JSP please?
For example in a.jsp:
In action java class:
private ArrayListarraylist1 ;
So that
Good morning,
Is there a way to put hidden ArrayList in JSP please?
For example in a.jsp:
In action java class:
private ArrayListarraylist1 ;
So that abean.arraylist1 could be retrieved by action java class.
Thanks a lot!
Emi
Good morning,
Is there a way to put hidden ArrayList in JSP please?
For example in a.jsp:
In action java class:
private ArrayListarraylist1 ;
So that abean.arraylist1 could be retrieved by action java class.
Thanks a lot!
Emi
2012/10/13 J. Garcia :
> Hi,
> If I want to have an additinal attribute, say, in a textfield tag, in a
> JSP, and use it in the freemarker template for the corresponding tag,
> text.ftl:
>
> - can it be done without extending the tag library?
> - how are the additional attributes passed in the JSP?
Hi,
If I want to have an additinal attribute, say, in a textfield tag, in a
JSP, and use it in the freemarker template for the corresponding tag,
text.ftl:
- can it be done without extending the tag library?
- how are the additional attributes passed in the JSP?
- how are they retrieved in the cor
Message-
From: raaja.g [mailto:raaj...@gmail.com]
Sent: Wednesday, March 21, 2012 2:14 AM
To: user@struts.apache.org
Subject: In Struts 1.3 how to display multiple images in jsp from database
Hi,
I am facing problem in displaying multiple images at a time in jsp. I am
able to retrieve the
Hi,
I am facing problem in displaying multiple images at a time in jsp. I am
able to retrieve the images from db and storing them in a list and
forwarding that to jsp in request from Action class. But I am not able to
display those images in jsp. I am not getting an idea how to render those
as OGNL in setting form action.
Best regards,
Sachin
On 27-05-2011 20:30, Dave Newton wrote:
On Fri, May 27, 2011 at 10:40 AM, Sachin Lale wrote:
1. In Jsp while displaying text box and i want this to populate from
ApplicationResource.properties file. I did this be adding getText() method
like
On Fri, May 27, 2011 at 10:40 AM, Sachin Lale wrote:
> 1. In Jsp while displaying text box and i want this to populate from
> ApplicationResource.properties file. I did this be adding getText() method
> like below. Is this the only way?
>
Nope; you can use the "key" tag a
Hi,
I have two questions:
1. In Jsp while displaying text box and i want this to populate from
ApplicationResource.properties file. I did this be adding getText()
method like below. Is this the only way?
2. I want the 'action' property of s:form tag to be populated
dynamically.
From: Dave Newton [mailto:davelnew...@gmail.com]
> Do the templates use the same models as the web layer?
Actually, it would have been good to note that the contact information
is hard-coded. So there is no need for a model. I literally just need
to include a block of html-/css-formatted text.
On Fri, Apr 15, 2011 at 1:03 PM, Biesbrock, Kevin wrote:
> So I have a block of contact information that we would like to appear
> similarly whenever it's displayed. So on our home page, on a printable
> confirmation page, or in a generated email -- it should always appear the
> same. Yesterda
Seems like a JSP-based custom tag would be the easiest, but I don't
actually know what your template requirements are, so it's tough to
say.
What's the use-case?
Dave
On Fri, Apr 15, 2011 at 11:13 AM, Biesbrock, Kevin
wrote:
> There seem to be plenty of documents outlining how to include a jsp
There seem to be plenty of documents outlining how to include a jsp in a
velocity template, but not the other way around. I am having a
difficult time finding information on how to include a Velocity template
in a JSP. I recognized the s:component tag could work, but my templates
are not currentl
Hi
I'm creating a report using jasper report and successfully generated the
report with struts2-jasperreports-plugin, in my web application.
the report is displayed in html format, now i need to embed this report in a
jsp page, but couldn't find a way to do that. Could some one please help me
to a
t in it. Can you help me with this?
>
> -Original Message-
> From: Maurizio Cucchiara [mailto:maurizio.cucchi...@gmail.com]
> Sent: Wednesday, January 12, 2011 3:06 PM
> To: Struts Users Mailing List
> Subject: Re: retaining the values in html:select multiple="true&quo
Mailing List
Subject: Re: retaining the values in html:select multiple="true" in jsp +
collection + struts
Here it the mail content:
Just to confirm, I dont need to place the following
In my pages? It is cool not to see these repeated lines
in all my pages
-Dan
2011/1/12
:13 PM
> To: Struts Users Mailing List; lukasz.len...@gmail.com
> Subject: Re: retaining the values in html:select multiple="true" in jsp +
> collection + struts
>
> Lukasz,
> I'm afraid he is using struts 1.
> Anyway, I think that when user goes back using
hiara [mailto:maurizio.cucchi...@gmail.com]
Sent: Wednesday, January 12, 2011 2:13 PM
To: Struts Users Mailing List; lukasz.len...@gmail.com
Subject: Re: retaining the values in html:select multiple="true" in jsp +
collection + struts
Lukasz,
I'm afraid he is using struts 1.
Anyway, I think that
2011/1/12 Maurizio Cucchiara :
> Lukasz,
> I'm afraid he is using struts 1.
You're right, I missed that out ;-)
Kind reagds
--
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/
Kapituła Javarsovia http://javarsovia.pl
-
To uns
Lukasz,
I'm afraid he is using struts 1.
Anyway, I think that when user goes back using the browser's arrow,
the page is loaded from cache. So It shouldn't be a matter of Struts.
My suggest is that you should find a way to avoid http caching [1] (I
don't know if it works, I usually use header-bas
2011/1/12
> Could some one help me on this please with some example?
Please read a bit about Preparable interface
http://struts.apache.org/2.x/struts2-core/apidocs/com/opensymphony/xwork2/Preparable.html
http://struts.apache.org/2.2.1.1/docs/prepare-interceptor.html
Regards
--
Łukasz
+ 48 606 3
Could some one help me on this please with some example?
Thanks,
Vikram
_
From: Byali, Vikram G.
Sent: Tuesday, January 11, 2011 3:48 PM
To: 'user@struts.apache.org'
Subject: retaining the values in html:select multiple="true" in jsp +
collection + struts
Hi,
I have a multiple selection box in one of the jsp:
Select Level :
Hi,
I have a multiple selection box in one of the jsp:
Select Level :
Hi lunch716:
For more detail information about this issue,
you can read these documents:
http://struts.apache.org/2.2.1/docs/ognl.html
http://struts.apache.org/2.2.1/docs/ognl-basics.html
And in [ognl-basics.html], it says:
"#request['foo'] or #request.foo"
means
"request attribute ['foo'
Hi,
Thanks Li and Maurizio!
Here is the solution.
I really appreciate you guys because I spent a whole day for this problem.
Thanks a lot!
--- Maurizio Cucchiara wrote:
> This would work:
>
>
> Maurizio Cucchiara
>
--
Learn more about breast cancer
This would work:
Maurizio Cucchiara
-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org
try
2010/10/7
> Hi,
>
> When I set a value in my interceptor,I could not get it in a jsp.
> How to do that?
>
>
> ### my interceptor
> public class HogeIntercepter extends AbstractInterceptor {
>
> @Override
> public String intercept(ActionInvocation invocation) throws Exception {
>
Hi,
When I set a value in my interceptor,I could not get it in a jsp.
How to do that?
### my interceptor
public class HogeIntercepter extends AbstractInterceptor {
@Override
public String intercept(ActionInvocation invocation) throws Exception {
HttpServletRequest request = ServletA
ilto:patelsame...@yahoo.com]
>> Sent: Monday, May 24, 2010 11:16 AM
>> To: user@struts.apache.org
>> Subject: Re: XML file reloading in JSP (Caching issue)
>>
>>
>> Thanks for quick reply Brian.!
>>
>> I tried adding new timestamp as parameters which generates new
> Date: Mon, 24 May 2010 08:40:39 -0700
> From: patelsame...@yahoo.com
> To: user@struts.apache.org
> Subject: RE: XML file reloading in JSP (Caching issue)
>
>
> I just did.
>
> No luck. :-(
>
> Thanks for the idea.
>
>
> sandeep.furia wrote:
> >
.com]
> Sent: Monday, May 24, 2010 11:16 AM
> To: user@struts.apache.org
> Subject: Re: XML file reloading in JSP (Caching issue)
>
>
> Thanks for quick reply Brian.!
>
> I tried adding new timestamp as parameters which generates new number
> everytime I visit the pa
how about if you change the location of the xml file, take it out of
web-inf and put it under the context root?
SDF/
-Original Message-
From: XML User [mailto:patelsame...@yahoo.com]
Sent: Monday, May 24, 2010 11:16 AM
To: user@struts.apache.org
Subject: Re: XML file reloading in JSP
aching with http headers setting
>> <%
>> response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
>> response.setHeader("Pragma","no-cache"); //HTTP 1.0
>> response.setDateHeader ("Expires", 0)
s caching at the proxy
> server
> %>
>
> Also tried with adding extra parameters to change the URL request.
>
> But still doen't work.
>
> Anyone has any suggestions, what to do next.
>
> Thanks for your help.
>
> Sorry.., If any typos or explained
work.
Anyone has any suggestions, what to do next.
Thanks for your help.
Sorry.., If any typos or explained in too much detail.
--
View this message in context:
http://old.nabble.com/XML-file-reloading-in-JSP-%28Caching-issue%29-tp28657737p28657737.html
Sent from the Struts - User mailing l
properties in JSP Page?
If yes, then please let me know.
Thanks,
Manoj
Yes.
-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org
Simple
Hi,
Thanks for your reply.
Please let me know how to do it?
Thanks,
Manoj
On Thu, May 20, 2010 at 4:42 PM, Robert Graf-Waczenski wrote:
> Am 20.05.2010 12:50, schrieb Manoj Singh:
>
> Hi,
>>
>> Is it possible to change the value of form bean properties in JSP Page?
>
Am 20.05.2010 12:50, schrieb Manoj Singh:
Hi,
Is it possible to change the value of form bean properties in JSP Page?
If yes, then please let me know.
Thanks,
Manoj
Yes.
-
To unsubscribe, e-mail: user-unsubscr
Hi,
Is it possible to change the value of form bean properties in JSP Page?
If yes, then please let me know.
Thanks,
Manoj
advance
On Fri, May 14, 2010 at 11:33 AM, Upasana Sharma wrote:
> Hi
>
> I have a scenario where i create a temporary dynamic image file from the
> database and try to show it on my jsp.
> The file url shows the image properly, but when in jsp , my browser says
> that "F
Hi
I have a scenario where i create a temporary dynamic image file from the
database and try to show it on my jsp.
The file url shows the image properly, but when in jsp , my browser says
that "Firefox doesn't know how to open this address, because the protocol
(d) isn't asso
Greetings to all,
I have a spring dao class like this
public class RoleDaoImpl extends SimpleJdbcDaoSupport implements RoleDao {
public Role findRoleById(Long id) {
.
and I have added it to spring as
when I am calling a method in this dao
catch (Exception e) {
System.out.println(e.getMessage());
}
return null;
}
I was using doDefault function earlier and was trying to return the
outputstream, but that will not work and it should return null.
Hope this is useful to someone....
--
View
luck & please let me know what your solution is.
Thanks!
-dave
> -Original Message-
> From: Aruna Ponaka [mailto:aruna@gmail.com]
> Sent: Monday, January 04, 2010 5:09 PM
> To: user@struts.apache.org
> Subject: Displaying an image in JSP in struts+tiles project
>
&
.action.MyAction and result success
In struts.xml is I provide reslut name="success" and the jsp, it does not
throw an error but not displaying the image. However in any case it is not
going to MyAction.java. What could i do to rectify this?
Could provide you with required code if ne
Ohh ok, thanks. I googled about that and i found that i can add a variable
or Object to page context with this:
pageContext.setAttribute("obj", obj);
Thanks.
2009/11/9 Musachy Barroso
> That's because creating an object in a scriptlet doesn't mean it will
> be in the page context, you need to
That's because creating an object in a scriptlet doesn't mean it will
be in the page context, you need to actually add it to the context.
musachy
On Mon, Nov 9, 2009 at 1:47 PM, Oscar Calderón wrote:
> Hi to all, this is my first question here. I have a doubt about the use of
> OGNL expressions
Hi to all, this is my first question here. I have a doubt about the use of
OGNL expressions on JSP to access to an object that i declared in a
scriptlet in the same JSP.
I have the following code:
<%
AnObject obj = request.getSession().getAttribute(AnObject.OBJECT_NAME);
%>
gt;"/>..
It displays the data from the bottom 5 struts html properties and not the
correct value from the List,i.e, value of
Can someone please help me out and explain why these things are happening in
my application?
F1 please..
--
Regards
--
View this message in context:
http:
> To: user@struts.apache.org
> Subject: Image not loaded in jsp
>
>
> Hi to all,
>
> I have some query regarding viewing of images in jsp page.
>
> We are using struts with hibernate to develop our application. What we
> do is
> while inserting image ,we inser
rhsana [mailto:rekha.dharsh...@gmail.com]
Sent: Tuesday, October 27, 2009 9:30 AM
To: user@struts.apache.org
Subject: Image not loaded in jsp
Hi to all,
I have some query regarding viewing of images in jsp page.
We are using struts with hibernate to develop our application. What we
do is
Hi to all,
I have some query regarding viewing of images in jsp page.
We are using struts with hibernate to develop our application. What we do is
while inserting image ,we insert the path in the database and have images in
the webapps.the image is not been loaded after uploaded.. once after
you can use OGNL syntax "@cl...@field"
see: http://www.opensymphony.com/ognl/html/LanguageGuide/staticFields.html
On Mon, Sep 7, 2009 at 05:12, Dave Newton wrote:
> Martin Gainty wrote:
>
>> the original solution i sent was OGNL
>>
>
> So why did you write:
>
> >>> yes javap would reveal the 'm
Martin Gainty wrote:
the original solution i sent was OGNL
So why did you write:
>>> yes javap would reveal the 'mangled' name
If there's a back-channel conversation that isn't being posted to the
list it's just confusing to introduce little chunks of it, and there was
never any solution ot
om: newton.d...@yahoo.com
> To: user@struts.apache.org
> Subject: Re: How to access enum in jsp?
>
> Martin Gainty wrote:
> > yes javap would reveal the 'mangled' name
>
> That's not a "mangled" name; that's just OGNL syntax.
>
> Dave
>
>
Martin Gainty wrote:
yes javap would reveal the 'mangled' name
That's not a "mangled" name; that's just OGNL syntax.
Dave
-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h..
alma miatt.
> Date: Sun, 6 Sep 2009 10:10:48 -0700
> Subject: Re: How to access enum in jsp?
> From: bill98...@gmail.com
> To: user@struts.apache.org
>
> Ah ha! So when code the test attribute like this:
>
> test="%{state == @com.yata.yata.actionst
Ah ha! So when code the test attribute like this:
test="%{state == @com.yata.yata.actionst...@list}"
it works. Thanks, Pawel!
- Bill
P.S. That syntax sux :-)
2009/9/6 Paweł Wielgus
> Hi Bill,
> You are comparing string with enum by == operator, so it's always false.
> Also if You see thi
Hi Bill,
You are comparing string with enum by == operator, so it's always false.
Also if You see this value in debug it's the effect of toString() method.
You can access enum like this com.something.actionst...@none
if i remebmer correctly.
Best greetings,
Paweł Wielgus.
2009/9/6 Bill Bohnenber
How do I reference an enum variable in an test attribute?
This is the situation, and the results I get:
1) I have a enum defined as
public enum ActionState
{
NONE, INIT, LIST, ADD, EDIT, DELETE ...
}
2) I have a variable of this type in my action class:
ActionState stat
Duh, it's:
-Original Message-
From: Security Management [mailto:list-subscripti...@secmgmt.com]
Sent: Tuesday, August 18, 2009 1:57 PM
To: 'Struts Users Mailing List'
Subject: List Iterator in JSP
My actions have a method, called getJavascriptIncludes() which return
My actions have a method, called getJavascriptIncludes() which returns a
List object.
I'm iterating like so, in the head:
Here's what's generated: