Re: Cocoon 3.0 components

gelo1234 <[email protected]>
Newsgroups gmane.text.xml.cocoon.user
Message-ID <CAPJaKUoXdP+YWfEVFNGXFCCQ15bL7Kz7BL4KRxAte0qF0PF6HA@mail.gmail.com>
Yes. It works!! Thank you. I thought it was just a dummy example :)
That is what I need :)

Greetings,
Greg



2013/6/20 Francesco Chicchiriccò <[email protected]>

>  On 20/06/2013 15:37, gelo1234 wrote:
>
>
>  Any idea how to get HTTP Header named Host ?
>
>
> Doesn't jexl:cocoon.request.serverName work?
>
>
>   or any other HTTP Header value ? [1]
>
>  tried cocoon.request.header['Host'], cocoon.request.header.host without
> effect
>
> I managed to get only requestURL:
>
> <map:parameter name="host" value="{jexl:cocoon.request.requestURL}"/>
>
>  Greetings,
>  Greg
>
> [1]
> http://docs.oracle.com/javaee/6/api/javax/servlet/http/HttpServletRequest.html
>
>
> 2013/6/20 Francesco Chicchiriccò <[email protected]>
>
>>
>>  and we can use something like: {jexl:cocoon.request.serverName} or
>>> {jext:cocoon.request.header.host} ?
>>>
>>> Is any info available about C3 request object ?
>>>
>>
>>  Basically, you can use JEXL [1] access to HttpServletRequest methods;
>> some examples:
>>
>> {jexl:cocoon.request.contextPath} -> HttpServletRequest#getContextPath()
>>
>> {jexl:cocoon.request.myparam} ->
>> HttpServletRequest#getParameter("myparam")
>>
>> {jexl:cocoon.request.locale.language} ->
>> HttpServletRequest#getLocale()#getLanguage()
>>
>> HTH
>> Regards.
>>
>> [1] http://commons.apache.org/proper/commons-jexl/reference/syntax.html
>>
>> --
>> Francesco Chicchiriccò
>>
>> ASF Member, Apache Syncope PMC chair, Apache Cocoon PMC Member
>> http://people.apache.org/~ilgrosso/
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [email protected]
>> For additional commands, e-mail: [email protected]
>>
>>
>
>
> --
> Francesco Chicchiriccò
>
> ASF Member, Apache Syncope PMC chair, Apache Cocoon PMC Memberhttp://people.apache.org/~ilgrosso/
>
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.