users@woodstock.java.net

Re: Woodstock & Facelet : webuijsf:Frame tag problems

From: Dan Labrecque <Dan.Labrecque_at_Sun.COM>
Date: Thu, 10 Jan 2008 11:47:15 -0500

FYI, I've integrated a fix to the Woodstock repository.

Thanks,
Dan

Djohannot wrote:
> Hello Kenneth,
>
> Thanks for your answer. I tried your solution for the page tag, and it works
> fine, thanks, but the frame error is always here. I've decided, for the
> moment, to use the default html frame and frameset tag.
>
> I hope that the developers will see the bad generated code for the frame tag
> (<frame> />)
>
> <frameset id="outerFrameset" title="Sun Java System Application Server 9.1
> Admin Console" rows="83, *" border="1">
> <frame id="sun_frame3" src="/header.jsf" name="header" scrolling="no"
> frameborder="0" marginwidth="0" marginheight="0"> />
> <frameset id="sun_frameSet4" title="TODO" cols="25%, *"
> frameborder="frameborder" border="0">
> <frame id="sun_frame5" src="/peTree.jsf" name="index" scrolling="yes"
> frameborder="0" marginwidth="0" marginheight="0"> />
> <frame id="sun_frame6" src="/homePage.jsf" name="main" scrolling="auto"
> frameborder="0" marginwidth="20" marginheight="10"> />
> </frameset>
> </frameset>
>
>
> David
>
>
> Kenneth Suter wrote:
>
>> Hello David,
>>
>> I have been playing with Facelets and Woodstock a little bit. I haven't
>> used the frameset tag but I don't declare the <?xml... processing
>> instructions explicitly in my .xhtml documents. Rather my documents
>> look like this:
>>
>> <f:view xmlns="http://www.w3.org/1999/xhtml"
>> xmlns:ui="http://java.sun.com/jsf/facelets"
>> xmlns:h="http://java.sun.com/jsf/html"
>> xmlns:f="http://java.sun.com/jsf/core"
>> xmlns:webuijsf="http://www.sun.com/webui/webuijsf">
>> <webuijsf:page>
>> <webuijsf:html>
>> ...
>> </webuijsf:html>
>> </webuijsf:page>
>> </f:view>
>>
>> The page tag seems to render correctly for these documents.
>>
>> -Kenneth
>>
>> David J. wrote:
>>
>>> Hi,
>>> I've create a project with Woodstock and Facelet. I have downloaded
>>> the Woodstock examples, and I'm able to run them.
>>> After that, I have tried to convert the Tree with frame example
>>> (navTree.jsp) in xhtml, but i've met two errors...
>>>
>>> The first problem is with the page tag. Like explains in the java doc,
>>> it add the <!DOCTYPE> attribute, but not in the right place for me,
>>> and throw an *"XML Parsing Error: not well-formed":*
>>>
>>> Result Code:
>>> <?xml version='1.0' encoding='UTF-8' ?>
>>> <html xmlns="http://www.w3.org/1999/xhtml">
>>> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN"
>>> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">
>>> <head>
>>>
>>> Original Code:
>>> <?xml version='1.0' encoding='UTF-8' ?>
>>> <html
>>> xmlns="http://www.w3.org/1999/xhtml"
>>> xmlns:f="http://java.sun.com/jsf/core"
>>> xmlns:h="http://java.sun.com/jsf/html"
>>> xmlns:c="http://java.sun.com/jstl/core"
>>> mlns:ui="http://java.sun.com/jsf/facelets"
>>> xmlns:a4j="http://richfaces.org/a4j"
>>> xmlns:rich="http://richfaces.org/rich"
>>> xmlns:webuijsf="http://www.sun.com/webui/webuijsf >
>>>
>>> <f:view>
>>> <webuijsf:page xhtml="true" frame="true">
>>> ...
>>>
>>> I've decided to declare manually the DocType, and to erase the page
>>> Tag. but then, the second mistake appears...
>>>
>>> The second mistake seems to be a bug from the frame component. Like
>>> explain before, i've erase the page tag, and my code look like this:
>>>
>>> Code:
>>> <?xml version='1.0' encoding='UTF-8' ?>
>>> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0
>>> Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">
>>> <html xmlns="http://www.w3.org/1999/xhtml" .... >
>>> <f:view>
>>>
>>> <f:loadBundle basename="ch.intrack.resources" var="msgs" />
>>> <webuijsf:head title="#{msgs['index_headTitle']}"/>
>>> <!-- Outer frameset containing all components of the page -->
>>> <webuijsf:frameSet id="outerFrameSet" rows="75,*"
>>> frameBorder="true" border="2"
>>> frameSpacing="2">
>>>
>>> <!-- Masthead frame-->
>>> <webuijsf:frame id="mastheadFrame" name="mastheadFrame"
>>> scrolling="no" noResize="true"
>>> marginWidth="0" marginHeight="0"
>>> url="header.jsp" />
>>>
>>> ....
>>>
>>> But when i build and deploy my application, i see the following error
>>> message:
>>>
>>> *XML Parsing Error: mismatched tag. Expected: </frame>.*
>>>
>>> The most strange is the result code:
>>>
>>> </head>
>>> <frameset id="outerFrameSet" rows="75,*" border="2" framespacing="2"
>>> frameBorder="1">
>>> <frame id="mastheadFrame" src="header.jsp" name="mastheadFrame"
>>> scrolling="no" frameborder="0" marginwidth="0" marginheight="0"
>>> noresize="noresize"*> />*
>>>
>>> As you can see in purple, the end of the frame tag
>>> (automatically generated) is wrong.... I've tried to close manually
>>> the tag (<frame></frame>), same result...
>>>
>>> So my questions are:
>>>
>>> - Is is possible to use the page tag on an xhtml page? is it obligatory?
>>> - Has someone an idea on how to resolve the wrong self-closing tag of
>>> the frame?
>>>
>>>
>>>
>>> All proposals are welcome,
>>>
>>> Tanks,
>>>
>>> David Johannot
>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe_at_woodstock.dev.java.net
>> For additional commands, e-mail: users-help_at_woodstock.dev.java.net
>>
>>
>>
>>
>
>