>It seemsit processes until the include, switches over to the included file
to run
>seprately (ie. vars declared here don't seem to propogate up to the
>including page), and then return to processing...
You are right. The page will process until it reaches the include and
then the processing will take place in the included page. So if you want
variables to be available to the included page, you will have to make the
available to the included page. This can be done through the session, and
I think you can do it through the response writer that is available to the
JSP page. I still don't know if I understand your specific problem, but I
hope this can help. You might try looking at the JSP 1.1 spec. It is
available at www.javasoft.com.
Adam
John Minadeo
<jminadeo@NFO To: JRun-Talk
<[EMAIL PROTECTED]>
RCE.com> cc:
Subject: RE: jsp:include, dynamic values
and page recompilation
11/17/00
01:17 AM
Please
respond to
jrun-talk
Adam,
Do you think you could explain the ramifications of using the directive
versus those of the action? I'm having a diificult time understanding what
is really going because of the way I thought it worked.
Let me give a little background on the problem. I have a util.jsp page
which
is to be included in all the pages on the site to provide common functions
and also to load some config data in to the application object if it hasn't
been already. So, basically I have some function and vars in the <%!
declare
blocks but I also have a <% code block that checks for the config data in
the application object and loads it if needed. It then pulls the data from
the session and drops it into a hash table which I make available via the
aforementioned declare block... If I do the directive include it works but
changes I make to the database are not reflected until the page containing
the included file or the included file is re-saved. And if I try the
action,
I am throwing an exception because the hashtable which is declared in the
util.jsp include is not available to the page it was included to. It seems
it processes until the include, switches over to the included file to run
seprately (ie. vars declared here don't seem to propogate up to the
including page), and then return to processing... Though I don't feel very
confident in my guess. I'm I crazy?
Should I be breaking my includes up with var. declares and function
declares
and if so, should the var declares be directive-ly included or with the
action?
Argh. I am missing something aren't I?!?
Thanks for your time and help!
--
John Minadeo
[EMAIL PROTECTED]
--
John Minadeo
[EMAIL PROTECTED]
> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, November 16, 2000 7:44 AM
> To: JRun-Talk
> Subject: Re: jsp:include, dynamic values and page recompilation
>
>
>
> According to the 1.1 version of the JSP specification
> <jsp:include> tag
> includes dynamic or static resource at request time. So,
> this means that
> the page should not be recompiled if JRun follows the
> specification on this
> issue (which I suspect they do).
>
> If you are wanting to add static data you should use <%@ include file
> ="filename" %>. This directive includes the files input at
> compilation
> time, so repeated requests will be faster with this directive
> instead of
> the include action. Repeating: The include directive only
> works with
> static data.
>
> I hope this helps.
>
> Adam
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Your ad could be here. Monies from ads go to support these lists and
provide more resources for the community.
http://www.fusionauthority.com/ads.cfm
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Your ad could be here. Monies from ads go to support these lists and provide more
resources for the community. http://www.fusionauthority.com/ads.cfm
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists