XSP Request-param through sunrise portal
Hello, I have the default sunrise portal. In the login pipeline I added a XSP-page between the Login page (login.xml) and the sunrise-user.xsl. In the surise-user.xml I have the following code and this parameter works fine. xsl:param name=name/ But in But in my XSP page I cannot request the name field from login.xml. The code is : xsp:logic String myUser = request.getParameter(name); /xsp:logic thanks for any help. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Form encoding problem in cocoon 2.0.4
Hello Charlene, this is configured in the sitemap in the map:serializers/. Simply add an encodingISO-8859-1/encoding. Example: map:serializer name=html src=org.apache.cocoon encodingISO-8859-1/encoding /map:serializer This has the same effect as the xsl:output encoding=/ declaration in the stylesheet, which is used normally, but should not be used in Cocoon. Joerg Yan, Charlene wrote: Joerg, My case was that I called cocoon from another web application. I had to set the encoding of the calling html page to ISO-8859-1. Now I'm using a htnl page generated by Cocoon. The default meta tag is META http-equiv=Content-Type content=text/html; charset=UTF-8. How or where can I change it to ISO-8859-1 from UTF-8? I've changed the encoding of form.xml, simple-page3html.xsl and sitemap.xmap to ISO-8859-1. It didn't help. What is the source code that sets the meta tag? More specifically, I'm using Cocoon 2.1 M2. you can go to http://localhost:8080/cocoon/samples/mail/sendmail/new.html. On this page, the meta is set to UTF-8. I need to have it changed to ISO-8859-1 to have some accented characters encoded correctly. Thanks in advance for any help. Charlene -Original Message- From: Joerg Heinicke [mailto:[EMAIL PROTECTED] Sent: Wednesday, July 02, 2003 1:42 PM To: [EMAIL PROTECTED] Subject: Re: Form encoding problem in cocoon 2.0.4 Sorry, but: please don't do this!! Even if ISO-8859-1 is the correct encoding, you shall not add the META tag by hand. The serializer does it for you. So you will simply set the serializer's encoding to ISO-8859-1. But UTF-8 is a super set of ISO-8859-1, so there should be no problem when using it. The working text inputs show this. Now file inputs: Why do they depend on the form encoding? Shouldn't they simply allow to upload a file? Am I missing something? Joerg Yan, Charlene wrote: I had encoding problems with accented characters too. Put META http-equiv=Content-Type content=text/html; charset=iso-8859-1 in your html. iso-8859-1 is the correct one. HTH. Charlene -Original Message- From: Vitor Rui Moreira [mailto:[EMAIL PROTECTED] Sent: Wednesday, July 02, 2003 1:10 PM To: [EMAIL PROTECTED] Subject: Form encoding problem in cocoon 2.0.4 Hi! I'm having a little problem about form encoding. First of all, let me describe the development environment: - Tomcat 4.1.24 - Cocoon 2.0.4 - RedHat 9 Now, the problem: I've got a webpage, which has a form inside. There are several input fields, mostly of type text. There is also a input field of type file. If i click on the submit button, i'll go other page (a xsp one), which displays the contents of the parameters (passed through request and sitemap). While the values of the input which have the type text are correct, the field which has the file type isn't. The error occurs when i use accents (éèá, etc). I'm using UTF-8 encoding on all pages. My tries to solve the problem: 1) changed the web.xml file of cocoon ($TOMCAT_HOME/webapps/cocoon/WEB-INF/web.xml), which i included the form-encoding parameter to UTF-8 2) on the same file, i've tried to set the container-encoding value to UTF-8 (ok, i'm almost desesperating! ;-)) My opinion: Since the text type works correctly and the file type doesn't, i suspect that the form-encoding is not so right after all... but it's only my opinion, based on my cocoon's ignorance... ;-) Critical features: 1) i just can't upgrade the cocoon engine because i've got legacy applications running on that... at least, i can't change right now... :-( F1 wanted! If anyone could help me, i'd appreciate!! TIA -vrm -- System Development VIRBUS AG Fon +49(0)341-979-7419 Fax +49(0)341-979-7409 [EMAIL PROTECTED] www.virbus.de - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Custom Logic Sheets: Request Parameters in Nested tags
Remove the apostrophes: xsl:variable name=id request:get-parameter name=template-id/ /xsl:variable Joerg Chintalapaty, Sreedhar wrote: Hi, I am trying to develop a tag that would - Get a parameter called template-id from the request - Fetch the template with that template-id from an XML config file Here's is how I am trying to accomplish it: !-- = -- !-- Fetch the template matching tempalte-id in Request -- xsl:template match=gvs:fetch-template !-- Get template-id -- xsl:variable name=id'request:get-parameter name=template-id/'/xsl:variable xsl:variable name=query-template xsl:call-template name=get-template xsl:with-param name=id select=$id/ /xsl:call-template /xsl:variable xsl:value-of select=$query-template/ /xsl:template !-- Get Query Template from queries.xml, given its ID -- xsl:template name=get-template xsl:param name=id/ xsl:variable name=query-template select=document('../control/config/queries.xml')/gvs-site:queries/gvs-site:[EMAIL PROTECTED]/template/ xsl:value-of select=normalize-space($query-template)/ /xsl:template !-- = -- For reasons that I cannot think of, this does NOT work! Interestingly, the following tag (which is essentially the !-- Get template-id -- section of the fetch-template tag) will correctly read the template-id from the request: !-- Get the Template ID from Request -- xsl:template match=gvs:get-it xsl:variable name=id'request:get-parameter name=template-id/'/xsl:variable xsl:copy-of select=$id/ /xsl:template Also, If set the template-id to a static value in the fetch-template tag, it will return the correct template from the XML file. So the questions I have are: 1. How can I get this to work? Are there any other suggested methods? 2. Why does the tag fail as it exists? I'd be grateful for any answers/pointers to the manuals/old threads, etc. :) Thanks, Sreedhar PS: I am using Cocoon 2.0.4 with Tomcat 4.1 and Java 2 SE 1.3.1_07-b02 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: sql transform
There are 2 independent technologies: 1. SQLTransformer http://cocoon.apache.org/2.1/userdocs/transformers/sql-transformer.html 2. ESQL Logicsheet (the XSP) http://cocoon.apache.org/2.1/userdocs/xsp/esql.html They are completely independent and it's possible (I don't know, I never used one of them) that SQLTransformer does not support skip-rows. Joerg Bruno Pierre wrote: Hi I don't understand why tag like sql:skip-rows2/sql:skip-rows are ignored by the sql transform call in the sitemap.xmap by map:transform type=sql map:parameter name=use-connection value=personnel/ /map:transform Does it work only in xsp file? thanks. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Custom Logic Sheets: Request Parameters in Nested tags
Can you provide more details? Sitemap, XML, queries.xml, ... Joerg Chintalapaty, Sreedhar wrote: Joerg, Thanks for your response. I had it without the apostrophes earlier; in both cases, however, the results are identical... :( Sreedhar -Original Message- From: Joerg Heinicke [mailto:[EMAIL PROTECTED] Sent: Mon 7/7/2003 3:53 PM To: [EMAIL PROTECTED] Cc: Subject:Re: Custom Logic Sheets: Request Parameters in Nested tags Remove the apostrophes: xsl:variable name=id request:get-parameter name=template-id/ /xsl:variable Joerg Chintalapaty, Sreedhar wrote: Hi, I am trying to develop a tag that would - Get a parameter called template-id from the request - Fetch the template with that template-id from an XML config file Here's is how I am trying to accomplish it: !-- = -- !-- Fetch the template matching tempalte-id in Request -- xsl:template match=gvs:fetch-template !-- Get template-id -- xsl:variable name=id'request:get-parameter name=template-id/'/xsl:variable xsl:variable name=query-template xsl:call-template name=get-template xsl:with-param name=id select=$id/ /xsl:call-template /xsl:variable xsl:value-of select=$query-template/ /xsl:template !-- Get Query Template from queries.xml, given its ID -- xsl:template name=get-template xsl:param name=id/ xsl:variable name=query-template select=document('../control/config/queries.xml')/gvs-site:queries/gvs-site:[EMAIL PROTECTED]/template/ xsl:value-of select=normalize-space($query-template)/ /xsl:template !-- = -- For reasons that I cannot think of, this does NOT work! Interestingly, the following tag (which is essentially the !-- Get template-id -- section of the fetch-template tag) will correctly read the template-id from the request: !-- Get the Template ID from Request -- xsl:template match=gvs:get-it xsl:variable name=id'request:get-parameter name=template-id/'/xsl:variable xsl:copy-of select=$id/ /xsl:template Also, If set the template-id to a static value in the fetch-template tag, it will return the correct template from the XML file. So the questions I have are: 1. How can I get this to work? Are there any other suggested methods? 2. Why does the tag fail as it exists? I'd be grateful for any answers/pointers to the manuals/old threads, etc. :) Thanks, Sreedhar PS: I am using Cocoon 2.0.4 with Tomcat 4.1 and Java 2 SE 1.3.1_07-b02 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie In Peril
Thanks Nuno, Wow it looks much simpler than what I thought it would be. I have to finish the client side of the site first and then get on to the administator/maintenance side which is definitely going to require this authorisation mechanism. Thankyou. Thankyou. Thankyou! You have saved me a so much time and a lot of stress. Ad. = Adam Flegman - Senior Software Engineer Mobile: (0414) 375 735 Phone: (07) 5547 8530 Facsimile: (07) 5547 8532 Email #1: [EMAIL PROTECTED] Email #2: [EMAIL PROTECTED] __ Do you Yahoo!? SBC Yahoo! DSL - Now only $29.95 per month! http://sbc.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Newbie In Peril
Hi Nuno, I tried to reply a few moments ago but yahoo mail was in an invalid state. I just hope you don't get 4-5 thankyou emails from me. Your solution makes it look so simple. I was thinking it was going to be very very hard and complicated to solve. I am only just begging to understand how powerful the sitemap is. I have to finish the client side of the application first before I can look at the administrator side of the web site. The administration side will definitely need to use the solution you have so generously provided. Thankyou. Thankyou. Thankyou! You have saved me so much time and stress. I hope that one day I will know enough about cocoon to also be able to give something back to new user's of cocoon. Ad. = Adam Flegman - Senior Software Engineer Mobile: (0414) 375 735 Phone: (07) 5547 8530 Facsimile: (07) 5547 8532 Email #1: [EMAIL PROTECTED] Email #2: [EMAIL PROTECTED] __ Do you Yahoo!? SBC Yahoo! DSL - Now only $29.95 per month! http://sbc.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]