Re: Generate PortletURL object with Struts framework

2013-04-26 Thread Nils-Helge Garli Hegvik
It's been a while since I used it last, but underneath the hood, Struts 2 uses PortletUrl to create urls with the url-tag. So you should be able to use the param tag to add parameters to the url. If that is not suitable, use the PortletRequestAware to get the current PortletRequest injected to your

Re: Pluto embedded in Strstu 2.1.8.1

2011-03-16 Thread Nils-Helge Garli Hegvik
Hi! The Struts2 portlet sample application is set up with the pluto embedded framework. You can take a look at it to replicate the setup. Nils-H On Wed, Mar 16, 2011 at 2:59 PM, Jose Luis Martinez Avial wrote: > Hi, >    I'm looking how I can integrate an external application available > throug

Re: struts2-portlet2-plugin-2.1.8.1 in Liferay 6.0.5 -Post-Redirect-Get aka Redirect after post

2010-12-20 Thread Nils-Helge Garli Hegvik
Did you set the "action-url-redirect" value to "true" in liferay-portlet.xml as described in the mentioned Lifray bug-report (http://issues.liferay.com/browse/LEP-1487)? Nils-H On Mon, Dec 20, 2010 at 1:22 PM, Galina Angelova wrote: > Hello, > > I have migrated a portlet application from Lifray

Re: Alternative UrlRenderer bean

2010-11-15 Thread Nils-Helge Garli Hegvik
You can take a look at how the portlet plugin does this (which was actually why the UrlRenderer bean was created in the first place). In addition to defining the bean, you need to tell Struts to use your renderer: The portlet plugin does it like this: Nils-H On Mon, Nov 15, 2010 at 12:37 PM,

Re: struts2-portlet2-plugin-2.1.8.1 in Liferay 6.0.5 - Post-Redirect-Get aka Redirect after post

2010-10-14 Thread Nils-Helge Garli Hegvik
Maybe this is related (although old): http://issues.liferay.com/browse/LEP-1487 Nils-H On Thu, Oct 14, 2010 at 6:25 PM, Nils-Helge Garli Hegvik wrote: > I believe it is up to the container how the event -> render transition > is implemented. I don't think there's any guarante

Re: struts2-portlet2-plugin-2.1.8.1 in Liferay 6.0.5 - Post-Redirect-Get aka Redirect after post

2010-10-14 Thread Nils-Helge Garli Hegvik
I believe it is up to the container how the event -> render transition is implemented. I don't think there's any guarantee that it's actualy a redirect. If you have several portlets on the page, you could check that the transition is ok by clicking on a an action/link in a different portlet, and se

Re: struts2-portlet2-plugin-2.1.8.1 in Liferay 6.0.5 - Post-Redirect-Get aka Redirect after post

2010-10-14 Thread Nils-Helge Garli Hegvik
Hi, Have you looked at the portlet sample app? It has a few portlet PRG examples. Try deploying it in Liferay and see if it works as expected. Nils-H On Thu, Oct 14, 2010 at 5:52 PM, Alberto Gallardo wrote: >>> couldn't get the Post-Redirect-Get (PRG) working. The >> type="redirectAction"> does

Re: How to pass HTTPRequest between two JSP ?

2010-03-01 Thread Nils-Helge Garli Hegvik
gt; > > > --- En date de : Lun 1.3.10, Nils-Helge Garli Hegvik a > écrit : > >> De: Nils-Helge Garli Hegvik >> Objet: Re: How to pass HTTPRequest between two JSP ? >> À: "Struts Users Mailing List" >> Date: Lundi 1 mars 2010, 11h07 >> In that

Re: How to pass HTTPRequest between two JSP ?

2010-03-01 Thread Nils-Helge Garli Hegvik
n the session. Nils-H On Mon, Mar 1, 2010 at 11:56 AM, Frederik Minatchy wrote: > To go from the first action (the execute method) to the second one > (supprimerIsbn) I use a submit button in the jsp : > >   > > > > > > > --- En date de : Lun 1.3.10, Nils-Helge Ga

Re: How to pass HTTPRequest between two JSP ?

2010-03-01 Thread Nils-Helge Garli Hegvik
n > > > I am sure that the dispatch result is a solution... but perhaps I made a > mistake in the web.xml file. > > For example why in my url I always have something like > > http://localhost:8080/X/x.jsp and not > http://localhost:8080/X/x.action? > >

Re: How to pass HTTPRequest between two JSP ?

2010-03-01 Thread Nils-Helge Garli Hegvik
Either: - Don't do a redirect, but a regular dispatch [1] - Store it in the session Regards, Nils-Helge Garli Hegvik [1] - http://struts.apache.org/2.1.8.1/docs/dispatcher-result.html On Mon, Mar 1, 2010 at 10:40 AM, Frederik Minatchy wrote: > > > --- En date de : Lun 1.3.10,

Re: Custom Window State Struts2 Portlet

2010-02-24 Thread Nils-Helge Garli Hegvik
>From the source [1] (getWindowState method), it appears that only the standard window states are considered when creating the url. Please register a JIRA issue (tests and patch welcome indeed). Regards, Nils-Helge Garli Hegvik [1] - http://svn.apache.org/viewvc/struts/struts2/trunk/plug

Re: Problem with tag

2010-01-18 Thread Nils-Helge Garli Hegvik
Putting it inside tag might also work. Nils-H On Mon, Jan 18, 2010 at 2:12 PM, Dave Newton wrote: > VSGoud wrote: >> >> Facing problem with tag. >> when i fetch the data from one of the columns in a given table, I am able >> to >> view the certain parts of the fetched data in new lines in >>

Re: MySQL + JDBC

2009-12-14 Thread Nils-Helge Garli Hegvik
Have you tried asking over at the MySQL forum? I don't think this is related to Struts 2. Nils-H On Tue, Dec 15, 2009 at 8:26 AM, Todd Grigsby wrote: > > > (Beating head on keyboard...) > "So one more time for the folks at home: Is there anyone out there who has > managed to get MySQL 64-bit to

Re: struts2 web app without jsp pages, is it possible?

2009-12-08 Thread Nils-Helge Garli Hegvik
The developer could still read the same files in the struts action. What's the difference? Nils-H On Tue, Dec 8, 2009 at 3:21 PM, Shital Patil wrote: > Dear All, > > Thanks for your valuable suggestions. > Actually I am failed to convince my PM for using JSP pages in web app. > He said, there ar

Re: JSR286 in Struts2

2009-10-22 Thread Nils-Helge Garli Hegvik
It's in the sandbox (http://svn.apache.org/repos/asf/struts/sandbox/trunk/struts2-portlet2-plugin/). You can also find some information here: http://boss.bekk.no/display/BOSS/Struts+2+Portlet+2.0+Plugin It's exeperimental, and has not been worked on for a while. You're welcome to test it and repor

Re: urgent guys

2009-10-14 Thread Nils-Helge Garli Hegvik
What happens at com.xiusbcgi.ui.struts.action.VoyagerDispatchAction.preExecute(VoyagerDispatchAction.java:178) ? Nils-H On Wed, Oct 14, 2009 at 1:31 PM, swathi reddy wrote: >  Hi  all guys > > can u tell me whare exactly this error is being raised in my project > > I am using struts 1.3.8 > errr

Re: Portlet form action parameters doubles the namespace of actions

2009-10-13 Thread Nils-Helge Garli Hegvik
I noticed your bug report in JIRA and will be looking into it. As for debugging, check out the setup in the sample portlet application. I use it to run portlets embedded in pluto directly in Eclipse. Makes debugging real easy. Nils-H On Fri, Oct 9, 2009 at 10:35 AM, Leonard Broman wrote: > I rec

Re: Problem Using Struts 2.1.8 Portlet Plugin With redirectAction

2009-10-05 Thread Nils-Helge Garli Hegvik
Yes, that was what I meant, and I worked just fine with me, using your web application (on Jetty/pluto). I haven't had time looking any more into it, but I'll keep you updated. Nils-H On Fri, Oct 2, 2009 at 3:40 PM, phillips1021 wrote: > > Nils - I'm not following how to implement your quick fix

Re: Problem Using Struts 2.1.8 Portlet Plugin With redirectAction

2009-10-01 Thread Nils-Helge Garli Hegvik
2.1.8... Nils-H On Thu, Oct 1, 2009 at 7:52 PM, Nils-Helge Garli Hegvik wrote: > It Should work with redirectAction. I'll look into it. > > Nils-H > > On Thu, Oct 1, 2009 at 7:28 PM, phillips1021 wrote: >> >> I changed my struts.xml configuration to u

Re: Problem Using Struts 2.1.8 Portlet Plugin With redirectAction

2009-10-01 Thread Nils-Helge Garli Hegvik
It Should work with redirectAction. I'll look into it. Nils-H On Thu, Oct 1, 2009 at 7:28 PM, phillips1021 wrote: > > I changed my struts.xml configuration to use type chain instead of type > redirectAction > >                 class="com.struts2.tutorial.action.EmployeeAction" method="delete"> >

Re: Wondering that Struts2 is getting die?

2009-09-30 Thread Nils-Helge Garli Hegvik
Now that is an impressive conclusion I didn't catch that, since I was reading the lines instead of between them... Nils-H On Wed, Sep 30, 2009 at 3:25 PM, Martin Gainty wrote: > > if i read between the lines i think hes speaking of the hardcoded xwork > dependency > there are rumours (that

Re: Wondering that Struts2 is getting die?

2009-09-30 Thread Nils-Helge Garli Hegvik
If you check out the dev mailing list, you'll see that there's currently a vote for 2.1.8. That doesn't look like dead to me... Nils-H On Wed, Sep 30, 2009 at 1:12 PM, karaatli wrote: > > Hi all, > Due to out of date struts wiki page, confllunece page & others relating to > struts2 I am question

Re: How to import a struts 2 action into a jsp?

2009-09-24 Thread Nils-Helge Garli Hegvik
Can't you use the s:action tag? Anyway, this might have something to do with filter configuration. Try adding this to the filter definition in web.xml: REQUEST INCLUDE FORWARD Nils-H On Thu, Sep 24, 2009 at 11:18 AM, Per Johansson wrote: > Hi, > > I am new to Struts and want to import a Struts

Re: using struts taglib how to find the lenght of an parameter

2009-09-17 Thread Nils-Helge Garli Hegvik
A simple way to achieve that is to have a property on the form bean that returns the username appropriate for display. Nils-H On Thu, Sep 17, 2009 at 2:35 PM, swathi reddy wrote: >  Hi all > > I am trying to display a user name through tag but before that > I want to check the lenght of the nam

Re: Testing with Spring + Struts 2 + TestNG

2009-09-11 Thread Nils-Helge Garli Hegvik
If it's unit testing you want to do, can't you just test your actions without involving Spring or anything else? I usually just create a unit test where I instantiate my action, set the aproriate dependencies, and then just call the appropriate execute method. Nils-H 2009/9/11 Diego Manilla Suáre

Re: [struts2] disable parameter pass between actions

2009-09-09 Thread Nils-Helge Garli Hegvik
How do you create the url (seeing some code would help...), and which version of S2? If you're using the url-tag, try setting the includeParams attribute to "none". http://struts.apache.org/2.1.6/docs/url.html Nils-H 2009/9/9 Halil Ağın : > Hello List; > > I have 2 urls as below > > /myapp/myac

Re: Strut2 Picture Upload question: Please Help!

2009-09-03 Thread Nils-Helge Garli Hegvik
A form with file input can't be submitted with Ajax. You either have to do some iframe magic or use a flash component. Do a google search for "ajax file upload" to find some options. I've been using SWFUpload [1] for this purpose. Nils-H [1] - http://code.google.com/p/swfupload/ On Thu, Sep 3, 2

Re: Need to disable session interceptor

2009-09-01 Thread Nils-Helge Garli Hegvik
> I am trying to find out why is the session created when I did not create > the session in my code. > > -- > Rajeev > Well, I believe Struts 2 internally does request.getSession(false) to prevent creating sessions when there isn't one... Which interceptor stack are you using? You could also try a

[OT] Re: Need to disable session interceptor

2009-09-01 Thread Nils-Helge Garli Hegvik
Hm... I don't know... Maybe read the documentation? http://jakarta.apache.org/jmeter/usermanual/component_reference.html#HTTP_Cookie_Manager Sorry for pinging you online. Hope that's not too much trouble... Nils-H On Tue, Sep 1, 2009 at 3:23 PM, Martin Gainty wrote: > > Nils- > > doc suggests i

Re: Need to disable session interceptor

2009-09-01 Thread Nils-Helge Garli Hegvik
>From the JMeter FAQ: "How do I ensure each http request for jsp is within one jsessionid ?" http://wiki.apache.org/jakarta-jmeter/JMeterFAQ#head-114aca8407cf0eaff55b7ae5955eda46b1e2cecb Nils-H On Tue, Sep 1, 2009 at 1:15 PM, Dave Newton wrote: > Rajeev Sharma wrote: >> >> I am new to struts2 (I

Re: How to print out method result called into execute() on a JSP page

2009-09-01 Thread Nils-Helge Garli Hegvik
Take a look at this tutorial: http://www.laliluna.de/first-steps-using-struts-tutorial.html There are more tutorials at http://wiki.apache.org/struts/StrutsTutorials Nils-H On Tue, Sep 1, 2009 at 12:34 PM, Hanen Ben Rhouma wrote: >  Hello there, > > I h

Re: Hibernate3+Spring2.5+Struts2

2009-08-20 Thread Nils-Helge Garli Hegvik
On Thu, Aug 20, 2009 at 5:27 PM, Martin Gainty wrote: > > agreed..i would also suggest wrap the code in try catch for the > NullPointerException > > good call wes! > > Martin Gainty Why? Nils-H - To unsubscribe, e-mail: user-u

Re: Hibernate3+Spring2.5+Struts2

2009-08-19 Thread Nils-Helge Garli Hegvik
java.lang.NullPointerException at action.LoginAction.execute(LoginAction.java:31) Looks like you have a NPE at line 31 in LoginAction. What line is that? Which references could have been null? Nils-H On Wed, Aug 19, 2009 at 1:59 PM, Zied Bejaoui wrote: > Thanks for your help, I have fixed

Re: Hibernate3+Spring2.5+Struts2

2009-08-19 Thread Nils-Helge Garli Hegvik
>From your stack trace: SEVERE: Context initialization failed org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Invocation of init method failed; nested exception is org.hib

Re: Struts - 2.1.6 - Prepare Interceptor

2009-08-13 Thread Nils-Helge Garli Hegvik
super.prepare()? Nils-H On Thu, Aug 13, 2009 at 9:51 AM, Kishan Paandy wrote: > > Hi Folks, > > I have a problem as below: > > 1) > public abstract class AbstractBaseAction implements Preparable > { >    public void prepare() >        { >        populateSomething(); >        } > } > > 2) > public

Re: struts2 portlet bug RenderRequest cannot be obtained in event phase

2009-08-07 Thread Nils-Helge Garli Hegvik
t; Thanks, > > Scott > > > > ----- Original Message > From: Nils-Helge Garli Hegvik > To: Struts Users Mailing List > Sent: Friday, August 7, 2009 4:41:53 AM > Subject: Re: struts2 portlet bug RenderRequest cannot be obtained in event   > phase > >> >&g

Re: struts2 portlet bug RenderRequest cannot be obtained in event phase

2009-08-07 Thread Nils-Helge Garli Hegvik
> > I have also noticed that struts form tag breaks the layout of the page. I am > not sure if you have seen this. I will try to find out why (i.e. not > standard html or css issue), otherwise i will use html form. Try using the "simple" theme. Nils-H

Re: struts2 portlet bug RenderRequest cannot be obtained in event phase

2009-08-06 Thread Nils-Helge Garli Hegvik
dex.jsp >       > >   > > initially the portlet executes the index action and the code runs fine. > Afterwards even if i call action index from a form or action editcontent i > get the exception. > > How would i change the above configuration ? > > Thanks again &g

Re: struts2 portlet bug RenderRequest cannot be obtained in event phase

2009-08-06 Thread Nils-Helge Garli Hegvik
The portlet execution life cycle is separated in two: The action/event phase, in which state transitions (typically a form submit) occurs, and then the render phase, where the actual output is rendered. The request object that is available in these two phases are not the same. In the action phase,

Re: Mixing portlet with regular pages

2009-08-04 Thread Nils-Helge Garli Hegvik
> > probably wise to beg off this particular plugin until all P1 bugs are quashed > Very insightful... > the JSR268 readme and core sample is located at > https://cds.sun.com/is-bin/INTERSHOP.enfinity/WFS/CDS-CDS_JCP-Site/en_US/-/USD/ViewFilteredProducts-SimpleBundleDownload > I'm not sure what

Re: Mixing portlet with regular pages

2009-08-04 Thread Nils-Helge Garli Hegvik
What do you mean by "accessed from a totally different server"? Are you referring to WSRP? There's a bug in the current version that causes some problems when you mix servlet actions and portlet actions in the same app. The next version (hopefully 2.1.8) should have this bug fixed. Nils-H On Tue

Re: HSSFWorkbook - set direction right to left

2009-08-04 Thread Nils-Helge Garli Hegvik
Why don't you try the POI mailing list instead? http://poi.apache.org/mailinglists.html Nils-H On Tue, Aug 4, 2009 at 3:01 PM, Odelya YomTov wrote: > Hi! > > When I export HSSFWorkbook it writes it from left to right > > I would like to right it from right to left > > How can I do it? > > Thanks

Re: struts 2 portlet interceptor issue

2009-08-03 Thread Nils-Helge Garli Hegvik
>                 >                         name="sessionScopeHandler"> >                        /jsp/test/test.jsp >                 With this configuration, your sessionScopeHandler will be the only interceptor running for this action. You either need to include the portletDefaultStack or set up

Re: ActionContext.getContext().getSession return null when I test Struts2 action by JUnit.

2009-08-03 Thread Nils-Helge Garli Hegvik
do the test now? How have I to create the ActionContext? > is it a bug? > > > 2009/8/3 Nils-Helge Garli Hegvik > >> Well, if that was a question, then I didn't see it >> >> I would certainly prefer implementing SessionAware, if it's an action &g

Re: ActionContext.getContext().getSession return null when I test Struts2 action by JUnit.

2009-08-03 Thread Nils-Helge Garli Hegvik
th xwork-2.1.2, you get a > NullPointerException, but if you do it with xwork-2.0.5, it works. > > If any know what is happening, I would be extremely grateful. > > > 2009/8/3 Nils-Helge Garli Hegvik > >> He might have found out already, considering this was poste

Re: ActionContext.getContext().getSession return null when I test Struts2 action by JUnit.

2009-08-03 Thread Nils-Helge Garli Hegvik
t; > newbie for Struts2. I cannot understant Struts2 very well, so if you >> > don't mind, pls tell me which testing class I can learn from. >> > >> > Thanks again >> > >> > >> > On Feb 1, 2008 4:31 PM, Nils-Helge Garli Heg

Re: Struts2 portlet bug found

2009-07-21 Thread Nils-Helge Garli Hegvik
erations). To retrieve the application scoped session attribute, you need to do as I suggested in the previous reply, get the raw session and access it directly. Nils-H On Wed, Jul 22, 2009 at 8:50 AM, Nils-Helge Garli Hegvik wrote: > Does it work if you access the session "raw"

Re: Struts2 portlet bug found

2009-07-21 Thread Nils-Helge Garli Hegvik
Does it work if you access the session "raw" (get the session and do session.getAttribute("studentId", PortletSession.APPLICATION_SCOPE)? Have you tried deploying to a different portlet container such as jboss portal or just plain pluto? I assume that the resources you're sharing session between ar

Re: Pb displaying image

2009-07-21 Thread Nils-Helge Garli Hegvik
1. You put it in a directory that your webserver serve... or 2. Create a servlet that reads the data from the filesystem and sends back the data in the response. I'd certainly prefer option 1 if possible. Nils-H On Tue, Jul 21, 2009 at 9:31 AM, tutu wrote: > > Thanks for response. > Just one que

Re: Problem with LoginInterceptor

2009-07-20 Thread Nils-Helge Garli Hegvik
You need to include one of the framework interceptor stacks (e.g "defaultStack") in your "defaultLoginStack" stack. As you have configured it, your interceptor is the only one that is being executed, so none of the framework "magic" gets applied. Nils-H On Mon, Jul 20, 2009 at 10:09 AM, mathias-e

Re: Struts w/Ajax with Struts again

2009-07-19 Thread Nils-Helge Garli Hegvik
The form will not be updated unless you refresh the values or the part of the page that displays the values you want to be updated. So you would have to "manually" do this processing some returned updated values in a json result, or by returning the result of a "partial" jsp which re-renders the pa

Re: EJB Injection in Interceptor

2009-07-16 Thread Nils-Helge Garli Hegvik
The short answer - You have to do the lookup yourself. The long answer - There's a similar discussion going on that pretty much covers the topic: http://www.nabble.com/Struts2-Action-Class-and-EJB-Injection-td24497801.html Nils-H On Thu, Jul 16, 2009 at 10:03 PM, Nathan Schulte wrote: > This may

Re: unit testing Struts2 application (with Spring and Hibernate)

2009-07-16 Thread Nils-Helge Garli Hegvik
If it's integration testing you want to do, I've had success embedding Jetty and doing "full" in-container integration testing. Embedding Jetty is really easy, and it's pretty fast too. Although not Struts 2 specific, take a look at this article: http://today.java.net/pub/a/today/2007/04/12/embedde

Re: URL to underlying action

2009-07-16 Thread Nils-Helge Garli Hegvik
Try using the url tag without specifying value or action. Nils-H Den 16. juli. 2009 kl. 13.14 skrev mathias-ewald : Hi, is there a way to create a URL (like ) to the Action that called a JSP file? I would like to reuse some code like forms and other stuff cu mathias -- View this message

Re: Struts2, JQuery and JSON result to create a dynamic ajax website

2009-07-13 Thread Nils-Helge Garli Hegvik
Did you look at the "Excluding properties" example in the json plugin documentation? Nils-H On Mon, Jul 13, 2009 at 9:15 AM, GF wrote: > You're absolutely right, > but there is a "security reason", in real-world application, the > objects i get from business service, are usually JPA entities, and

Re: [OT] Return Hashmap java object from servlet

2009-07-07 Thread Nils-Helge Garli Hegvik
What exactly are you trying to do? Do you want to serialize the hashmap to the client as a Java object, or do you want it converted to xml? What does the consuming end expect? If you really want to produce xml, take a look at one of the many java <-> xml libraries that exists (although, something a

Re: Struts 1.2 in Tomact 5.0 giving ERRORS...

2009-07-03 Thread Nils-Helge Garli Hegvik
Change the classpath to servlet-api? Where? The container should provide all the jsp and servlet jars that you need (with correct versions). You should probably not tamper with the classpath to any of those... Nils-H On Fri, Jul 3, 2009 at 10:40 AM, pasanewa wrote: > > I was using Tomcat 4.1 and

Re: Error when deploying portlets beside a normal Struts2 web app?

2009-06-26 Thread Nils-Helge Garli Hegvik
It should be fixed now in trunk. Let me now if it works or not. Nils-H On Wed, Jun 24, 2009 at 6:01 PM, phillips1021 wrote: > > I added to the Jira bug report another example application that demonstrates > the problem.  The example application is a simple Struts 2 (using 2.1.6) > application tha

Re: Pre setAttribute for a form

2009-06-26 Thread Nils-Helge Garli Hegvik
     public ActionForward execute( >>                        ActionMapping mapping, ActionForm form, >> HttpServletRequest req, >>                        HttpServletResponse res) >>                throws Exception { >>                RedirectHelpForm redirectHelpForm = (RedirectHelpFo

Re: Pre setAttribute for a form

2009-06-24 Thread Nils-Helge Garli Hegvik
> req.setAttribute("RedirectHelpForm",  redirectHelpForm); > > but this is for request rather than session? > > Thanks for the suggesion. > sam > > On Thu, Jun 25, 2009 at 3:09 PM, Nils-Helge Garli > Hegvik wrote: >> Haven't looked very deeply into it, but could

Re: Pre setAttribute for a form

2009-06-24 Thread Nils-Helge Garli Hegvik
Haven't looked very deeply into it, but could it be that you're setting the attribute in the action phase, and trying to access it in the render phase? That won't work. In that case, you have to set it as a session attribute, or set some kind of id as a render parameter and re-fetch the object in t

Re: download link for struts UI Tags?

2009-06-22 Thread Nils-Helge Garli Hegvik
The Struts 2 core already includes the tag libraries. So if you have downloaded struts 2, then you also have the tag libraries you need. Struts distributions can be downloaded here: http://struts.apache.org/downloads.html Nils-H On Mon, Jun 22, 2009 at 10:46 AM, Sam Wun wrote: > Hi, > > Can anyon

Re: Error when deploying portlets beside a normal Struts2 web app?

2009-06-19 Thread Nils-Helge Garli Hegvik
It would be helpful if you could create a sample app and attach it to a JIRA issue. Then I'll have a look at it. Nils-H On Fri, Jun 19, 2009 at 9:52 PM, phillips1021 wrote: > > Nils-H (or anyone else): > > I've duplicated this problem with 2.1.6 and portlets as follows: > > Created a Struts 2 web

Re: how to correctly generate "path" and "type" in structs-config.xml file?

2009-06-19 Thread Nils-Helge Garli Hegvik
This has nothing to do with Struts. You have to put the source file in a folder structure that mirrors your package definition. Nils-H On Fri, Jun 19, 2009 at 6:00 AM, Sam Wun wrote: > Hi, > > I  have an Action java source code with package at the top of the > file. When I put the package line in

Re: download file

2009-06-17 Thread Nils-Helge Garli Hegvik
Take a look at Pawel and Dave's replies once again. Nils-H On Wed, Jun 17, 2009 at 8:55 AM, PEGASUS84 wrote: > > thanks, > now there is a problem in struts.xml: > Can not find a java.io.InputStream with the name [${contentType}] in the > invocation stack. Check the > > > -- > View this message in

Re: download file

2009-06-16 Thread Nils-Helge Garli Hegvik
And where does your input stream come from? On Tue, Jun 16, 2009 at 12:11 PM, PEGASUS84 wrote: > > my action  is this: > public class FileDownload extends ActionSupport { > >       InputStream inputStream; > > >   public void setInputStream(InputStream s){inputStream=s;} >   public InputStream get

Re: download file

2009-06-16 Thread Nils-Helge Garli Hegvik
You can't expect someone else to write your code for you... What have you tried? What errors did you get? You have to at least provide some informatino for us to help you. Nils-H On Tue, Jun 16, 2009 at 11:54 AM, PEGASUS84 wrote: > > sorry, > i don't succeed > i haven't idea > -- > View this mes

Re: white space

2009-06-15 Thread Nils-Helge Garli Hegvik
I'd consider creating a new getter that returns what you want. Nils-H On Mon, Jun 15, 2009 at 12:01 PM, PEGASUS84 wrote: > > good moornig, > > my problem is this: >  i've this select > > listValue="getNome()+getCognome()" theme="simple" > list="getDocentiNONComm()"> > > in listValue i Want to se

Re: [OT]Moving from Struts2 to grails, your thoughts

2009-06-12 Thread Nils-Helge Garli Hegvik
An impressive number of hacks there... Nils-H On Fri, Jun 12, 2009 at 1:48 PM, Martin Gainty wrote: > > Scott- > i think what Pawel is suggesting is there is a 'demonstrable' need for a > Struts Grails plugin > > I have some grails code here so i might decide to tackle this myself..altho i > th

Re: Error when deploying portlets beside a normal Struts2 web app?

2009-06-12 Thread Nils-Helge Garli Hegvik
If you're using portlets, your package must extend "struts-portlet-default" instead of "struts-default". It should be possible to run servlet actions and portlet actions in the same application. Nils-H On Thu, Jun 11, 2009 at 3:52 PM, IainM wrote: > > Hi, > > I have an existing Struts2 (2.1.6) w

Re: opening a popup window from Action Class

2009-06-10 Thread Nils-Helge Garli Hegvik
That's something you have to handle in your view, either with javascript or just a link with the proper target attribute. Nils-H On Thu, Jun 11, 2009 at 8:03 AM, abhishek reddy wrote: > hi every one, > > How to open a popup window from Struts Action Class? > > thanks in advance > -- > Abhishek >

Re: Re [S2] development tool

2009-06-08 Thread Nils-Helge Garli Hegvik
I don't think anyone is _threatened_ by RAD tools. To be a threat, they would have to be better than the alternatives And they're not I have yet to see a RAD (as in point and click programming) tool that is actually more productive taking the entire lifecycle of a development project into c

Re: Doubts about new project (Struts2 good way to do it?)

2009-06-08 Thread Nils-Helge Garli Hegvik
> could you elaborate on how JetSpeed is not JSR-168 compliant? > > thanks, > Martin Gainty You have to start actually reading the posts you're replying to. I said nowhere that JetSpeed is not JSR-168 compliant. And please, keep discussions on the list. Nils-H > > >> Date: Mon, 8 Jun 2009 13:00:

Re: Doubts about new project (Struts2 good way to do it?)

2009-06-08 Thread Nils-Helge Garli Hegvik
Jetspeed2 - No, JSR168 portlets - Yes. You should be aware of the features and limitations of portlets though. It might not necessarily be what you're looking for. I suggest digging a bit deeper into the topic if you're considering using it. Nils-H On Mon, Jun 8, 2009 at 9:05 AM, Francisco Exposi

Re: response.sendRedirect() with Struts2 within a portlet

2009-05-31 Thread Nils-Helge Garli Hegvik
t;                ActionResponse aResponse = > PortletActionContext.getActionResponse(); >                System.out.println("The Action response object is : " + > aResponse); > >                aResponse.sendRedirect("http://www.google.lk";); > >                return SUCCESS; >      

Re: Struts 2 going to hang glassfish

2009-05-31 Thread Nils-Helge Garli Hegvik
I'm sure you realize that for anyone to be able to help, you have to provide some more information... Besides, I'd be surprised if you can't find any trace of anything in your logs. Nils-H On Sun, May 31, 2009 at 6:05 PM, mohsen ahmadian wrote: > Hello to all >  I have a project with Struts 2 ,D

Re: response.sendRedirect() with Struts2 within a portlet

2009-05-31 Thread Nils-Helge Garli Hegvik
You can use the PortletResponseAware to get the portlet response object. Nnils-H On Sun, May 31, 2009 at 10:20 AM, Crishantha Nanayakkara wrote: > > Hi, > > I have a requirement to use a response.sendRedirect() within my Action > class. Basically this action class is used to manipulate a porltet

Re: Error in Jasper printReport

2009-05-28 Thread Nils-Helge Garli Hegvik
Maybe you should try a Jasper mailing list? Nils-H On Fri, May 29, 2009 at 8:19 AM, Ikya Technical wrote: > Hi, > >     Whenever I am giving true in > >                        JasperPrintManager.printReport(jasperPrint, true) > >    it is throwing the error > >                net.sf.jasperreport

Re: how to get productID from the url into action class.

2009-05-28 Thread Nils-Helge Garli Hegvik
009 at 12:41 PM, Prashant Singh wrote: > Hi Nils, > > this is what I have tried to do till today. > > http://www.coderanch.com/t/446930/Struts/transfer-productID-from-url-action > > Sincerely, > Prashant > > > > --- On Thu, 28/5/09, Nils-Helge Garli Hegvik wrote: >

Re: how to get productID from the url into action class.

2009-05-28 Thread Nils-Helge Garli Hegvik
automagically be set from the url to your action. If that doesn't work, then there's something wrong with your setup. Nils-H On Thu, May 28, 2009 at 12:33 PM, Prashant Singh wrote: > Hi Nils, > > can you please illustrate with a code snippet. > > Thanks, > Prashant > > ---

Re: how to get productID from the url into action class.

2009-05-28 Thread Nils-Helge Garli Hegvik
; this is generating a url as follows: > http://localhost:8080/Astralpharma1/astralpharma/astralpharma/showprodsuppliers.action?productID=1 > > I just need to retrieve the productID from the url. thats it > > Please let me know how so I do that in Struts 2 > > Thanks > Prashant > &

Re: how to get productID from the url into action class.

2009-05-28 Thread Nils-Helge Garli Hegvik
When I think of it, that doesn't make any sense either... Isn't the product id set as a property on your action? Nils-H 2009/5/28 Nils-Helge Garli Hegvik : > Um... What exactly are you trying to do here? Do you just need the product id > from the url string, or are you trying to

Re: how to get productID from the url into action class.

2009-05-28 Thread Nils-Helge Garli Hegvik
Um... What exactly are you trying to do here? Do you just need the product id from the url string, or are you trying to fetch something from a different backend? If you just need it from the string, just use indexOf and substring. Nils-H On Thu, May 28, 2009 at 11:41 AM, Prashant Singh wrote: >

Re: how to get productID from the url into action class.

2009-05-28 Thread Nils-Helge Garli Hegvik
Um... What exactly are you trying to do here? Do you just need the product id from the url string, or are you trying to fetch something from a different backend? If you just need it from the string, just use indexOf and substring. Nils-H On Thu, May 28, 2009 at 11:41 AM, Prashant Singh wrote: >

Re: Keep Action Properties over multiple requests

2009-05-25 Thread Nils-Helge Garli Hegvik
Yes, the ScopeInterceptor should be able to handle this case. Nils-H On Mon, May 25, 2009 at 1:02 PM, Richard Sayre wrote: > I have an action that does some server side logic, based on that logic > I want to present the user with a Yes/No message.  If they click yes I > want to save the data the

Re: [Struts 2] Disabled fields are not posted on form submission

2009-05-13 Thread Nils-Helge Garli Hegvik
Are you sure that you really want to disable it? Can you use a hidden field, or hide the field with css, if you're just trying to hide it from the user? Nils-H On Wed, May 13, 2009 at 11:28 AM, Fernandes Celinio wrote: > Hi, > > Disabled fields by W3 specifications will not get posted on form >

Re: unable to get the request parameters

2009-05-12 Thread Nils-Helge Garli Hegvik
rs > > On Tue, May 12, 2009 at 5:00 PM, Murugesh wrote: > >> Thanks Nils-H. >> >> i am not clear. can i have the sample for this? >> >>   On Tue, May 12, 2009 at 4:57 PM, Nils-Helge Garli Hegvik < >> nil...@gmail.com> wrote: >> >>> Yo

Re: unable to get the request parameters

2009-05-12 Thread Nils-Helge Garli Hegvik
loggin r not ). it seems work but after running  interceptor > it backs to actionclass, here i am chking requset parameters  at that am > geeting for all parameters. > > Without interceptor everything working fine. > > > > On Tue, May 12, 2009 at 4:27 PM, Nils-Hel

Re: unable to get the request parameters

2009-05-12 Thread Nils-Helge Garli Hegvik
It would certainly be a lot easier to help if you could show your configuration and code... Nils-H On Tue, May 12, 2009 at 12:54 PM, Murugesh wrote: >  I am doing task on struts2. In that I have to use custom > AutherizationInterceptor. In my custom Interceptor Im checking weather user > is in s

Re: Not able to locate the file stored using Struts 2 file upload interceptor

2009-05-11 Thread Nils-Helge Garli Hegvik
The FileUploadInterceptor doesn't really store the file for you. It just makes it available to your action so you can process it. After the request has finished, the file is deleted. It should all be described here: http://struts.apache.org/2.1.6/docs/file-upload.html Nils-H On Mon, May 11, 2009

Re: Using session object in JSP page

2009-05-10 Thread Nils-Helge Garli Hegvik
That depends on how you want to use it. The tag reference should give you the information you need. http://struts.apache.org/2.1.6/docs/tag-developers-guide.html http://struts.apache.org/2.1.6/docs/ognl.html http://struts.apache.org/2.1.6/docs/tag-syntax.html Nils-H On Mon, May 11, 2009 at 7:57

Re: newbie and hidden field

2009-05-10 Thread Nils-Helge Garli Hegvik
Um... I don't think those are Struts tags. Could this be what you're using? http://www.common-controls.com/en/index.php If yes, then you should ask your question here: http://www.common-controls.com/bbs/?loc=en Nils-H On Mon, May 11, 2009 at 7:32 AM, pam wrote: > Hi, > I am modifying a struts a

Re: Converting from Struts for IBM API to Struts for JSR168

2009-05-07 Thread Nils-Helge Garli Hegvik
I'm not sure how this is related to Struts? If you are looking for using Struts for portlet development, either check the Struts 1 portlet bridge, or use Struts 2 with the portlet plugin. Nils-H On Thu, May 7, 2009 at 11:17 PM, Hermann X Lau wrote: > IBM API has been deprecated for Portal 6.1...

Re: Struts 2 UI Tags and OGNL self reference

2009-05-07 Thread Nils-Helge Garli Hegvik
If I understand your question correctly, are you looking for a reference to the tag itself? If so, why do you need it (I'm not sure it's possible at all)? If you're just looking for the current action, the expression 'top' might be what you're looking for. Nils-H On Thu, May 7, 2009 at 6:27 PM, s

Re: Re: How to forward request in struts 2.1.6?

2009-04-30 Thread Nils-Helge Garli Hegvik
quot;show" ,... > are the default result types. I can manage this. > > my situation is, I need to forward request to action conditionally,ie,depend > on "category" in action class. > > > > > 在2009-04-29,"Nils-Helge Garli Hegvik" 写道: >>

Re: How to develop a Wireframe using Struts UI?

2009-04-30 Thread Nils-Helge Garli Hegvik
Um Maybe start with http://struts.apache.org/2.1.6/docs/tutorials.html and read the docs for the various ui tags? Nils-H On Thu, Apr 30, 2009 at 5:30 PM, kunduruswaroop wrote: > > Please see the UI drawing below and let me know the steps to follow to > develop a wireframe. > http://www.nabbl

Re: How to forward request in struts 2.1.6?

2009-04-29 Thread Nils-Helge Garli Hegvik
Why do you need to do it manually with the request dispatcher? Can't you use any of the available result types? http://struts.apache.org/2.1.6/docs/result-types.html Nils-H 2009/4/29 xnpeng : > from: > > ServletActionContext.getServletContext().getRequestDispatcher("/post/message/"+id).forward(S

Re: file upload

2009-04-28 Thread Nils-Helge Garli Hegvik
Sorry, my copy & paste mistake. That file is of course in the core. Take a look at this: http://struts.apache.org/2.1.6/docs/file-upload.html Nils-H On Tue, Apr 28, 2009 at 7:37 PM, PEGASUS84 wrote: > > no where is ths file > > Nils-Helge Garli wrote: >> >>

Re: file upload

2009-04-28 Thread Nils-Helge Garli Hegvik
Do you have a jar with the org.apache.struts2.dispatcher.multipart.MultiPartRequest class anywhere in your classpath? Nils-H On Tue, Apr 28, 2009 at 7:25 PM, PEGASUS84 wrote: > > please helm me > i must write a code for uploading file in a directory of the server. > i just try some example but i

  1   2   3   4   5   >