Can this only be done on the tr:document?  Doesn't the trh:head also
produce a doc-type?  Currently we use trh:head, trh:html, and trh:body.
What is the difference?

Also, I would still think that the PPR should work regardless of how or
where or what I set the doc-type to. 


Nate Perkins
480-441-3667
[EMAIL PROTECTED]

>This email message is for the sole use of the intended recipient(s) and
may contain GDC4S
> confidential or privileged information. Any unauthorized review, use,
disclosure or distribution
> is prohibited. If you are not an intended recipient, please contact
the sender by reply email and
> destroy all copies of the original message.
>

-----Original Message-----
From: Andrew Robinson [mailto:[EMAIL PROTECTED] 
Sent: Thursday, August 23, 2007 8:48 AM
To: MyFaces Discussion
Subject: Re: [Trinidad] Upgrading to 1.0.2

You can use IE6 in quirks mode and firefox in standards mode by
subclassing the tr:document renderer.

If a comment appears before the doc type, IE will not go into standards
mode.

Here is some code if you want to do it this way to force only IE into
quirks mode while using tr:document:

public class DocumentRenderer
  extends
 
org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.DocumentRendere
r
{

  /**
   *
   */
  public DocumentRenderer()
  {}

  /**
   * @param type
   */
  public DocumentRenderer(Type type)
  {
    super(type);
  }

  /**
   * @see
org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.DocumentRendere
r#encodeAll(javax.faces.context.FacesContext,
org.apache.myfaces.trinidad.context.RenderingContext,
javax.faces.component.UIComponent,
org.apache.myfaces.trinidad.bean.FacesBean)
   */
  @Override
  protected void encodeAll(FacesContext context, RenderingContext arc,
    UIComponent component, FacesBean bean) throws IOException
  {
    if (Agent.AGENT_IE.equals(arc.getAgent().getAgentName()))
    {
      context.getResponseWriter().write("<!-- force quirks mode -->");
    }
    super.encodeAll(context, arc, component, bean);
  }
}


On 8/23/07, Perkins, Nate-P63196 <[EMAIL PROTECTED]> wrote:
>
>
> I put a lot of time into this problem, albeit a while ago, but I could
not
> find a way to satisfy my requirements for IE6 in standard mode, I
would love
> to be able to, but I have not found a way.  I'll post the general
structure
> and the css and perhaps you can help?
>
> The basic structure is this:
>
> <div id="top_bar">
>     <span>Some necessary banner text</span>
> </div>
> <div id="main_content">
>     Whatever the particular page requires
> </div>
> <div id="bottom_bar">
>     <span>Again, some necessary banner text</span>
> </div>
>
> The requirement is that the top_bar and the bottom_bar are always
visible
> and in the same position (at the top and the bottom, respectively :) )
but
> not covering the main_content while main_content can scroll as
necessary.
>
> Here's the css that I used to accomplish this, this works properly in
> Firefox regardless of the doc-type, but again, in IE6 it only works in
> quirks mode.
>
> body {
> border: 0pt none;
> margin: 0;
> padding 0;
>
> height: 100%;
> max-height: 100%;
>
> width: 100%;
> max-width: 100%;
> overflow: hidden;
> }
>
> * html body {
> padding: 5px 0pt 55px;
> }
>
> #main_content {
> bottom: 30px;
> left: 0px;
> overflow: auto;
> position: fixed;
> right: 0;
> top: 25px;
> }
>
> * html #main_content {
> height: 100%;
> position: relative;
> width: 100%;
> }
>
> #top_bar {
> height: 25px;
>
> position: absolute;left: 0;
> top: 0;
> width: 100%;
> }
>
> #bottom_bar {
>
> height: 25px;
>
> position: absolute;left: 0;
> bottom: 0;
> width: 100%;
> }
>
>
> Nate Perkins
> 480-441-3667
> [EMAIL PROTECTED]
>
> This email message is for the sole use of the intended recipient(s)
and may
> contain GDC4S
>  confidential or privileged information. Any unauthorized review, use,
> disclosure or distribution
>  is prohibited. If you are not an intended recipient, please contact
the
> sender by reply email and
>  destroy all copies of the original message.
>
>
>  ________________________________
>  From: Simon Lessard [mailto:[EMAIL PROTECTED]
> Sent: Thursday, August 23, 2007 8:21 AM
>
> To: MyFaces Discussion
> Subject: Re: [Trinidad] Upgrading to 1.0.2
>
>
> Hello Nate,
>
> So what you're saying is that your application will only ever work in
quirk
> mode? There's always a solution in standard mode as well, sometimes a
bit
> more complicated though.
>
>
> Regards,
>
> ~ Simon
>
>
> On 8/23/07, Perkins, Nate-P63196 <[EMAIL PROTECTED]> wrote:
> > I commented out the jsp:output and that fixed the problem.
> >
> > Unfortunately I can not live with that solution as it is mandatory
for
> > my project's pages.  We have a requirement for a fixed bar on top
and on
> > bottom that do not scroll (while the rest of page obviously does)
and
> > are always visible and the only solution I found required that
doc-type.
> >
> >
> >
> > Nate Perkins
> > 480-441-3667
> > [EMAIL PROTECTED]
> >
> > >This email message is for the sole use of the intended recipient(s)
and
> > may contain GDC4S
> > > confidential or privileged information. Any unauthorized review,
use,
> > disclosure or distribution
> > > is prohibited. If you are not an intended recipient, please
contact
> > the sender by reply email and
> > > destroy all copies of the original message.
> > >
> >
> > -----Original Message-----
> > From: Adam Winer [mailto:[EMAIL PROTECTED]
> > Sent: Wednesday, August 22, 2007 10:57 PM
> > To: MyFaces Discussion
> > Subject: Re: [Trinidad] Upgrading to 1.0.2
> >
> > If you remove the doctype-root-element, doctype-system,
> > and doctype-public off of jsp:output, does the problem
> > go away?  It looks as though that doctype is getting
> > pushed straight into the content stream.  There's code
> > in Trinidad to trim out the doctype (XmlHttpServletResponse
> > and XmlOutput) during an XMLHttp request - don't know
> > why it's not functioning here.
> >
> > -- Adam
> >
> >
> > On 8/22/07, Perkins, Nate-P63196 <[EMAIL PROTECTED]> wrote:
> > > Ok,
> > >
> > > Here's the simplest example I could muster, this results in the
same
> > > problem.  I am deploying to JBoss-4.0.5 using Trinidad 1.0.2 and
using
> > > the RI 1.1
> > >
> > > Test.jspx:
> > >
> > > <?xml version="1.0" encoding="UTF-8"?>
> > > <jsp:root
> > >         xmlns:jsp="http://java.sun.com/JSP/Page";
> > >         version="2.0"
> > >         xmlns:f="http://java.sun.com/jsf/core "
> > >
> xmlns:trh="http://myfaces.apache.org/trinidad/html";
> > >         xmlns:tr="http://myfaces.apache.org/trinidad "
> > >         xmlns:h="http://java.sun.com/jsf/html";>
> > >         <f:view>
> > >                 <trh:html>
> > >                 <jsp:output
> > >                         omit-xml-declaration="false"
> > >                         doctype-root-element="html"
> > >
> > > doctype-system="
> http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";
> > >                         doctype-public="-//W3C//DTD XHTML 1.0
> > > Strict//EN" />
> > >                 <jsp:scriptlet>
> > >         response.addHeader("pragma", "no-store,no-cache");
> > >         response.setHeader("cache-control", "no-cache, no-store,
must
> > > re-validate,max-age=-1");
> > >         response.addHeader ("cache-control", "pre-check=0,
> > > post-check=0");
> > >         response.setDateHeader("expires", 0);
> > >       </jsp:scriptlet>
> > >                 <jsp:directive.page
> > > contentType="text/html;charset=UTF-8" />
> > >                 <trh:head title="Trinidad 1.0.2 PPR Test">
> > >                         <meta
> > >
> http-equiv="Content-Type"
> > >                                 content="text/html;
> charset=UTF-8" />
> > >                         <t:stylesheet
> > > path="#{NMSPanelPageUtil.cssLocation}" />
> > >                 </trh:head>
> > >                 <trh:body>
> > >                         <tr:form id="theForm">
> > >                                 <tr:panelPage>
> > >                                         <!--<jsp:
> directive.include
> > > file="/menu.jspx" />-->
> > >                                         <tr:panelHeader
> text="Partial
> > > Submit Test">
> > >
> <tr:inputText
> > >
> id="input"
> > >
> > > value="#{testBB.input}"
> > >
> label="Input:"
> > >
> > > partialTriggers="partialTestButton" />
> > >
> <tr:commandButton
> > >
> > > id="partialTestButton"
> > >
> text="PPR
> > Test"
> > >
> > > action="#{testBB.action}"
> > >
> > > partialSubmit="true" />
> > >
> <tr:outputText
> > >
> > > id="partialOutput"
> > >
> > > value="#{testBB.output}"
> > >
> > > partialTriggers="partialTestButton" />
> > >
> <tr:commandButton
> > >
> > > id="fullTestButton"
> > >
> text="Full
> > > Submission Test"
> > >
> > > action="#{testBB.action}"/>
> > >
> <tr:outputText
> > >
> > id="fullOutput"
> > >
> > > value="#{testBB.output}"/>
> > >
> </tr:panelHeader>
> > >                                 </tr:panelPage>
> > >                         </tr:form>
> > >                 </trh:body>
> > >                 </trh:html>
> > >         </f:view>
> > > </jsp:root>
> > >
> > > Backing Bean:
> > > import
> org.apache.myfaces.trinidad.context.RequestContext;
> > >
> > > public class TestBb
> > > {
> > >    private RequestContext rc =
> RequestContext.getCurrentInstance();
> > >
> > >    public TestBb()
> > >    {
> > >       setOutput("output");
> > >       setInput("input");
> > >    }
> > >
> > >    public void action()
> > >    {
> > >       setOutput(getInput());
> > >    }
> > >
> > >    public String getOutput()
> > >    {
> > >       return (String) rc.getPageFlowScope().get("output");
> > >    }
> > >
> > >    public void setOutput(String output)
> > >    {
> > >       rc.getPageFlowScope().put("output", output);
> > >    }
> > >
> > >    public String getInput()
> > >    {
> > >       return (String) rc.getPageFlowScope().get("input");
> > >    }
> > >
> > >    public void setInput(String input)
> > >    {
> > >       rc.getPageFlowScope().put("input", input);
> > >    }
> > > }
> > >
> > >
> > > Nate Perkins
> > > 480-441-3667
> > > [EMAIL PROTECTED]
> > >
> > > >This email message is for the sole use of the intended
recipient(s)
> > and
> > > may contain GDC4S
> > > > confidential or privileged information. Any unauthorized review,
> > use,
> > > disclosure or distribution
> > > > is prohibited. If you are not an intended recipient, please
contact
> > > the sender by reply email and
> > > > destroy all copies of the original message.
> > > >
> > >
> > > -----Original Message-----
> > > From: Adam Winer [mailto:[EMAIL PROTECTED]
> > > Sent: Wednesday, August 22, 2007 1:35 PM
> > > To: MyFaces Discussion
> > > Subject: Re: [Trinidad] Upgrading to 1.0.2
> > >
> > > On 8/22/07, Perkins, Nate-P63196 <[EMAIL PROTECTED]> wrote:
> > >
> > > > Hi,
> > > >
> > > > I'm testing my project with 1.0.2 and I am having several
issues.
> > > >
> > > > 1. No PPR activity works, I get a javascript error "Invalid PPR
> > > response"
> > > > any time I try to submit a PPR action
> > >
> > > PPR's been overhauled.  But also tested quite a lot.  I could
> > > really use a testcase.
> > >
> > > > Can anyone give me a clue as to what's wrong and how to fix it?
> > >
> > > Could you use Firebug and look at the responses you're getting
> > > from the server?
> > >
> > > > 2. My skin no longer works, it seems that a few of the selectors
> > have
> > > > changed, namely:
> > > >         a) the panelHeader is rendering with af_messages_header
> > class
> > > >         b) the panelBox has lost its background, it seems like
there
> > > is no
> > > > longer a distinction between panelBox transparent, light, etc.
> > >
> > > I think there was a fix just after 1.0.2 that affected panelBox,
and
> > > perhaps panelHeader as well.  Deleting af:messages works around
> > > it (with the obvious harm), or moving af:messages to the bottom
> > > of the page.  It's fixed in the 1.0.3 nightlies.
> > >
> > > -- Adam
> > >
> > > >
> > > > I looked at the JIRA issues attached to the 1.0.2 release and
did
> > not
> > > see an
> > > > obvious item that applied to either of these discoveries....can
> > anyone
> > > verify
> > > > exactly what it was that changed for each of these?
> > > >
> > > > Nate Perkins
> > > > 480-441-3667
> > > > [EMAIL PROTECTED]
> > > >
> > > > This email message is for the sole use of the intended
recipient(s)
> > > and may
> > > > contain GDC4S
> > > >  confidential or privileged information. Any unauthorized
review,
> > use,
> > > > disclosure or distribution
> > > >  is prohibited. If you are not an intended recipient, please
contact
> > > the
> > > > sender by reply email and
> > > >  destroy all copies of the original message.
> > > >
> > >
> >
>
>

Reply via email to