Re: JSON Plugin - my execute method is being called twice
Yes, you can try this. Greetings El mar, 15-03-2011 a las 10:16 -0500, Muneer Malik escribió: > You mean have all your action logic in getJSON? > > > > On Tuesday, March 15, 2011, Rodrigo Esteban Cares Guarda > wrote: > > Hi, > > if you have the method "execute" and "getJSON" in your action class, try > > comment the "execute" method. > > > > Greetings > > > > El mar, 15-03-2011 a las 00:27 -0700, Johannes Geppert escribió: > >> if you are using validation it is normaly that you get two requests. > >> the first request is for validation and the second is the expected request. > >> > >> Johannes > >> > >> -- > >> View this message in context: > >> http://struts.1045723.n5.nabble.com/JSON-Plugin-my-execute-method-is-being-called-twice-tp3635553p3681532.html > >> Sent from the Struts - User mailing list archive at Nabble.com. > >> > >> ----------------- > >> To unsubscribe, e-mail: user-unsubscr...@struts.apache.org > >> For additional commands, e-mail: user-h...@struts.apache.org > >> > > > > -- > > Rodrigo Esteban Cares Guarda > > Egresado Ingeniería Civil Informática > > Universidad Austral de Chile > > 1º GUP Taekwondo WTF > > Fono: (09) 98364117 > > > > > > - > > To unsubscribe, e-mail: user-unsubscr...@struts.apache.org > > For additional commands, e-mail: user-h...@struts.apache.org > > > > > -- Rodrigo Esteban Cares Guarda - To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org
Re: JSON Plugin - my execute method is being called twice
Hi, if you have the method "execute" and "getJSON" in your action class, try comment the "execute" method. Greetings El mar, 15-03-2011 a las 00:27 -0700, Johannes Geppert escribió: > if you are using validation it is normaly that you get two requests. > the first request is for validation and the second is the expected request. > > Johannes > > -- > View this message in context: > http://struts.1045723.n5.nabble.com/JSON-Plugin-my-execute-method-is-being-called-twice-tp3635553p3681532.html > Sent from the Struts - User mailing list archive at Nabble.com. > > - > To unsubscribe, e-mail: user-unsubscr...@struts.apache.org > For additional commands, e-mail: user-h...@struts.apache.org > -- Rodrigo Esteban Cares Guarda Egresado Ingeniería Civil Informática Universidad Austral de Chile 1º GUP Taekwondo WTF Fono: (09) 98364117 - To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org
Re: Can't deploy on server
Thanks to all, i solved this problem creating an ServletContextListener and executing this before all other listeners of my application and put my settings in contextInitialized method like this: public void contextInitialized(ServletContextEvent event) { try { System.setProperty("javax.xml.transform.TransformerFactory","com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl"); System.setProperty("javax.xml.parsers.DocumentBuilderFactory","org.apache.xerces.jaxp.DocumentBuilderFactoryImpl"); System.setProperty("javax.xml.parsers.SAXParserFactory","org.apache.xerces.jaxp.SAXParserFactoryImpl"); } catch (Exception e) { System.out.println(e.getMessage()); } } Thanks for all your help, see you later. :D El jue, 21-10-2010 a las 11:10 +0900, Li Ying escribió: > > Thanks for your answers, i try put next code into web.xml file: > > > > > javax.xml.parsers.DocumentBuilderFactory="org.apache.xerces.jaxp.DocumentBuilderFactoryImpl"/> > > > javax.xml.parsers.SAXParserFactory="org.apache.xerces.jaxp.SAXParserFactoryImpl"/> > > > > > javax.xml.transform.TransformerFactory="org.apache.xalan.processor.TransformerFactoryImpl"/> > > > > but doesn't work, and put a jaxp.properties file into > > > What version of web.xml are you using? > I have read > http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd > but found nothing about tag [system-property]. > > And, if your setting is correct in schema, > are you sure it is applied to system properties BEFORE the XSL error occurs? > > > > > If you want to change system-property, maybe you can try: > (1) add start-up options like [-DpropName=propValue] in command line > which start the web app server. > > OR > > (2) add a ServletContextListener to you web-app, make it get executed > before anything else. > and in method [contextInitialized] of this Listener, you can set > system-property as you want, by Java code > > - > To unsubscribe, e-mail: user-unsubscr...@struts.apache.org > For additional commands, e-mail: user-h...@struts.apache.org > Rodrigo Esteban Cares Guarda Alumno Ingeniería Civil Informática Universidad Austral de Chile 2º GUP Taekwondo WTF Fono: (09) 98364117
Re: Can't deploy on server
Thanks for your answers, i try put next code into web.xml file: but doesn't work, and put a jaxp.properties file into WEB-INF/classes with this code: javax.xml.transform.TransformerFactory=org.apache.xalan.processor.TransformerFactoryImpl javax.xml.parsers.DocumentBuilderFactory=org.apache.xerces.jaxp.DocumentBuilderFactoryImpl javax.xml.parsers.SAXParserFactory=org.apache.xerces.jaxp.SAXParserFactoryImpl but with the same result. Other test i do put the next 3 files into META-INF/services directory with respective content: file javax.xml.transform.TransformerFactory with content: org.apache.xalan.processor.TransformerFactoryImpl file javax.xml.parsers.DocumentBuilderFactory with content: org.apache.xerces.jaxp.DocumentBuilderFactoryImpl file javax.xml.parsers.SAXParserFactory with content: org.apache.xerces.jaxp.SAXParserFactoryImpl Resuming, with 3 attemps i get the same result. Thanks to all. El mié, 20-10-2010 a las 11:53 +0200, Jordi Fernandez escribió: > XML parsers are accessed via factories from Java code. Which concrete > parser will be used is something that will be decided at runtime by the > factory code, which is implemented by the app server. Your app server is > using a concrete implementation by Oracle that is causing the exception. > > Usually, there is a way to tell the app server which concrete XML parser > implementation you want to use. In some cases you can specify that you > want the app server to look first in the WEB-INF/lib of your app before > trying the app server general classpath. In any case, look at the app > server docs for the procedure to override how the xml parser is chosen. > > On 20/10/2010 0:03, Rodrigo Esteban Cares Guarda wrote: > > Hi, > > > > I'm trying to deploy an aplication writed in struts 2 and work perfect > > in my computer but when i put the generated war on the server this can't > > run and output this messages: > > > > 2010-10-19 18:45:07,228 INFO > > org.apache.tiles.impl.BasicTilesContainer.init:116 - Initializing Tiles2 > > container. . . > > 2010-10-19 18:45:07,251 INFO > > org.apache.tiles.impl.BasicTilesContainer.initializeDefinitionsFactory:204 > > - Tiles2 container initialization complete. > > 2010-10-19 18:45:07,252 INFO > > org.apache.tiles.access.TilesAccess.setContainer:95 - Publishing > > TilesContext for context: > > org.apache.catalina.core.ApplicationContextFacade > > 2010-10-19 18:45:07,318 DEBUG > > com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.debug:68 > > - Loading action configurations from: struts-default.xml > > 2010-10-19 18:45:07,325 DEBUG > > com.opensymphony.xwork2.util.FileManager.debug:68 - Creating revision > > for URL: > > jar:file:/usr/local/jakarta-tomcat-5.0.28/webapps/Mavis2/WEB-INF/lib/struts2-core-2.2.1.jar!/struts-default.xml > > > > XSL-1103: (Fatal Error) DOMResult can not be this kind of node. > > 2010-10-19 18:45:07,347 ERROR > > org.apache.struts2.dispatcher.Dispatcher.error:38 - Dispatcher > > initialization failed > > Unable to load configuration. - Class: > > oracle.xml.jaxp.JXTransformerHandler > > File: JXTransformerHandler.java > > Method: endDocument > > Line: 141 - oracle/xml/jaxp/JXTransformerHandler.java:141:-1 > > at > > com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:69) > > at > > org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:371) > > at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:415) > > at > > org.apache.struts2.dispatcher.ng.InitOperations.initDispatcher(InitOperations.java:69) > > at > > org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.init(StrutsPrepareAndExecuteFilter.java:51) > > at > > org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:225) > > at > > org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:308) > > at > > org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:79) > > at > > org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:3698) > > at > > org.apache.catalina.core.StandardContext.start(StandardContext.java:4349) > > at > > org.apache.catalina.core.StandardHostDeployer.start(StandardHostDeployer.java:830) > > at org.apache.catalina.core.StandardHost.start(StandardHost.java:991) > > at > > org.apache.catalina.manager.ManagerServlet.start(ManagerServlet.java:1322) > > at > > org.apache.catalina.manager.HTMLManagerSe
Re: Requesting bug on struts-tiles-plugin
Hi, from http://tiles.apache.org site: Warning! Tiles users that use Tiles 2.1.1 or 2.1.0 version should not install it in a production environment, due to a discovered security problem. Upgrade Tiles. Tiles 2.0.x is not involved in this security bug. El jue, 07-10-2010 a las 23:46 -0400, Martin Gainty escribió: > Good Evening Stephen > > a few weeks ago you mentioned a bug for struts-tiles-plugin? > could you kindly repost the bug and which version of struts that caused the > bug > > thanks, > Martin Gainty > __ > Verzicht und Vertraulichkeitanmerkung/Note de déni et de confidentialité > > Diese Nachricht ist vertraulich. Sollten Sie nicht der vorgesehene Empfaenger > sein, so bitten wir hoeflich um eine Mitteilung. Jede unbefugte Weiterleitung > oder Fertigung einer Kopie ist unzulaessig. Diese Nachricht dient lediglich > dem Austausch von Informationen und entfaltet keine rechtliche > Bindungswirkung. Aufgrund der leichten Manipulierbarkeit von E-Mails koennen > wir keine Haftung fuer den Inhalt uebernehmen. > Ce message est confidentiel et peut être privilégié. Si vous n'êtes pas le > destinataire prévu, nous te demandons avec bonté que pour satisfaire informez > l'expéditeur. N'importe quelle diffusion non autorisée ou la copie de ceci > est interdite. Ce message sert à l'information seulement et n'aura pas > n'importe quel effet légalement obligatoire. Étant donné que les email > peuvent facilement être sujets à la manipulation, nous ne pouvons accepter > aucune responsabilité pour le contenu fourni. > > > -- Rodrigo Esteban Cares Guarda - To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org