You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Jeff Sexton <js...@odshp.com> on 2003/12/11 19:59:44 UTC

How to allow cacheing?

My cocoon app, under tomcat, places "Pragma: No-cache" in it's response
headers.

How can I remove that on certain responces?  Maybe this is a tomcat
question?


-----
The ODS Companies
Jeff Sexton
Information Services
(503) 228-6554   x1026
http://www.odscompanies.com

This message is intended for the sole use of the individual and entity
to whom it is addressed, and may contain information that is privileged,
confidential and exempt from disclosure under applicable law. If you are
not the intended addressee, nor authorized to receive for the intended
addressee, you are hereby notified that you may not use, copy, disclose
or distribute to anyone the message or any information contained in the
message. If you have received this message in error, please immediately
advise the sender by reply email and delete the message.



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


ESQL : creating dynamic elements ?

Posted by julien bloit <Ju...@ircam.fr>.
I'm building a database request using ESQL. Let's say I have a table with
two columns in the table i'm requesting. This is the xsp snippet I use to
get the results from the request :

<esql:results>
     <esql:row-results>
          <first_table_col_1>
                <esql:get-string column="1"/>
                <xsp:attribute name="first_table_col2">
                    <esql:get-string column="2"/>
                </xsp:attribute>
            </first_table_col_1>
        </esql:row-results>
</esql:results>

This works, but as I want this code to be dynamic in order to be used with
other tables, I need my column element name (the currently static
"<first_table_col_1>" element) to be created with the requested column name.
The same logic would apply for the 'name' attribute in the 'xsp:attribute'
element. I don't know if this is possible, using the esql logicsheet.

any ideas?

Thank you,
Julien


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: How to allow cacheing?

Posted by Jeff Sexton <js...@odshp.com>.
On Fri, 12 Dec 2003, Jorg Heymans wrote:
> wiki entry http://wiki.cocoondev.org/Wiki.jsp?page=DownloadFilesToLocalDisk
> has something about this pragma, maybe you can rip out a working
> solution that suits your need (seems to require 2.1x though).

In searching around I found many, many write-ups on making sure pages are
*not* cached, by adding "Pragma: no-cache" in various ways.  The
interesting thing is that my setup seems to always send a "Pragma:
No-cache" in its responses even though I have done nothing to add that
myself.

I did find something that works though.  I added:

  <xsp:logic>
    response.setHeader( "Cache-Control", "max-age=3600" );
    response.setHeader( "Pragma", "cache" );
  </xsp:logic>

To the specific xsp file in question.  Now I know that "Pragma: cache"
is an invalid header item, but it does in fact get into my response header
and it *replaces* the "Pragma: No-cache"!

I'm sure "Pragma: cache" is almost certainly ignored, but at lease
"Pragma: no-cache" isn't there.  The overall affect is that the page does
in fact get cached on the particular browser the user wants to use.

Success!  For now...


> Jeff Sexton wrote:
>
> > My cocoon app, under tomcat, places "Pragma: No-cache" in it's response
> > headers.
> >
> > How can I remove that on certain responces?  Maybe this is a tomcat
> > question?
> >
> >
> > -----
> > The ODS Companies
> > Jeff Sexton
> > Information Services
> > (503) 228-6554   x1026
> > http://www.odscompanies.com
> >
> > This message is intended for the sole use of the individual and entity
> > to whom it is addressed, and may contain information that is privileged,
> > confidential and exempt from disclosure under applicable law. If you are
> > not the intended addressee, nor authorized to receive for the intended
> > addressee, you are hereby notified that you may not use, copy, disclose
> > or distribute to anyone the message or any information contained in the
> > message. If you have received this message in error, please immediately
> > advise the sender by reply email and delete the message.
> >
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> > For additional commands, e-mail: users-help@cocoon.apache.org
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: How to allow cacheing?

Posted by Jorg Heymans <jh...@domek.be>.
wiki entry http://wiki.cocoondev.org/Wiki.jsp?page=DownloadFilesToLocalDisk
has something about this pragma, maybe you can rip out a working 
solution that suits your need (seems to require 2.1x though).

Jeff Sexton wrote:

> My cocoon app, under tomcat, places "Pragma: No-cache" in it's response
> headers.
> 
> How can I remove that on certain responces?  Maybe this is a tomcat
> question?
> 
> 
> -----
> The ODS Companies
> Jeff Sexton
> Information Services
> (503) 228-6554   x1026
> http://www.odscompanies.com
> 
> This message is intended for the sole use of the individual and entity
> to whom it is addressed, and may contain information that is privileged,
> confidential and exempt from disclosure under applicable law. If you are
> not the intended addressee, nor authorized to receive for the intended
> addressee, you are hereby notified that you may not use, copy, disclose
> or distribute to anyone the message or any information contained in the
> message. If you have received this message in error, please immediately
> advise the sender by reply email and delete the message.
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org