[richfaces-issues] [JBoss JIRA] Reopened: (RF-8139) Impossible to set a title in rich:page with <f:facet name="pageHeader" >
D'Alton Jean-Adrien (JIRA)
jira-events at lists.jboss.org
Thu Nov 19 06:50:29 EST 2009
[ https://jira.jboss.org/jira/browse/RF-8139?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
D'Alton Jean-Adrien reopened RF-8139:
-------------------------------------
I've always the same problem :-( , I don't understand why it doesn't works in my project : Here i give the full example wich I reproduct the problem in my project, there are 2 files, the template and the page:
The template used
templatetesttitle.xhtml:
<rich:page 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:rich="http://richfaces.org/rich"
xmlns:a4j="http://richfaces.org/a4j" markupType="xhtml"
contentType="text/html" theme="#{prefs.layout.theme}"
width="#{prefs.layout.width}"
sidebarWidth="#{prefs.layout.sidebarWidth}"
sidebarPosition="#{prefs.layout.position}"
oncontextmenu="return false;">
<f:facet name="pageHeader">
<h:panelGroup>
<title><ui:insert name="title" /></title>
<ui:insert name="keywords" />
<ui:insert name="description" />
</h:panelGroup>
</f:facet>
<f:view contentType="text/html">
<!-- safari compatibility -->
<f:facet name="header">
<h:panelGroup>
<h:outputText value="the header" />
</h:panelGroup>
</f:facet>
<f:facet name="sidebar">
<h:panelGroup>
<h:outputText value="the sidebar" />
</h:panelGroup>
</f:facet>
<f:facet name="footer">
<h:panelGroup>
<h:outputLink id="cop" value="/">
<h:outputText value="footerlink" />
</h:outputLink>
</h:panelGroup>
</f:facet>
<ui:insert name="pbody" />
</f:view>
</rich:page>
The page using the template
pagettitletest.xhtml
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:rich="http://richfaces.org/rich"
xmlns:a4j="http://richfaces.org/a4j"
xmlns:ui="http://java.sun.com/jsf/facelets"
template="/templatetesttitle.xhtml"
>
<ui:define name="title">The title of the page</ui:define>
<ui:define name="keywords">
<meta name="keywords" content="some keywords"/>
</ui:define>
<ui:define name="description">
<meta name="description" content="Page description" />
<meta name="date" content="2009-11-19"/>
</ui:define>
<ui:define name="pbody" >
<h1 >Page title test</h1>
blabla
</ui:define>
</ui:composition>
The source in my browser (chrome or ffox ), In first i've always a <title></title> and my title after the richfaces javascript:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html lang="fr" xmlns="http://www.w3.org/1999/xhtml"><head><title></title><link class="component" href="/a4j/s/3_3_2.SR1org/richfaces/renderkit/html/css/basic_both.xcss/DATB/eAF7sqpgb-jyGdIAFrMEaw__.jsf" rel="stylesheet" type="text/css" /><link class="component" href="/a4j/s/3_3_2.SR1org/richfaces/renderkit/html/css/extended_both.xcss/DATB/eAF7sqpgb-jyGdIAFrMEaw__.jsf" media="rich-extended-skinning" rel="stylesheet" type="text/css" /><script type="text/javascript">window.RICH_FACES_EXTENDED_SKINNING_ON=true;</script><script src="/a4j/g/3_3_2.SR1org/richfaces/renderkit/html/scripts/skinning.js.jsf" type="text/javascript"></script><link type="text/css" rel="stylesheet" class="component" href="/a4j/s/3_3_2.SR1org/richfaces/renderkit/html/css/smooth.xcss/DATB/eAF7sqpgb-jyGdIAFrMEaw__.jsf" /><style type="text/css">.rich-page{margin:auto;text-align:left;width:960px;</style>
<title>The title of the page</title>
<meta name="keywords" content="some keywords" />
<meta name="description" content="Page description" />
<meta name="date" content="2009-11-19" /></head><body><table border="0" cellpadding="0" cellspacing="0" class="rich-page "><tr><td class="common_box"><table cellpadding="0" cellspacing="0" class="page_size" height="100%"><thead><tr><th class="header_bg_left" colspan="3"><div class="header_bg_right"><!-- div class="spacer" style="height : 15px"></div --><div class="header_content rich-page-header ">the header</div></div></th></tr></thead><tbody><tr><td class="left_col"><div class="left_strut"><br /></div></td><td class="bg_tabbody" height="100%" width="100%"><table cellpadding="0" cellspacing="0" class="content_body rich-page-content " height="100%" width="100%"><tbody><tr><td class="menu_col rich-page-sidebar "><div class="spacer" style="width:160px"></div>the sidebar</td><td class="content_col rich-page-body "> <!-- safari compatibility -->
<h1>Page title test</h1>
blabla</td></tr></tbody></table></td><td class="right_col"><div class="right_strut"><br /></div></td></tr><tr><td class="footer_bg_left" colspan="3"><div class="footer_bg_right"><div class="footer_bg_content rich-page-footer "><a id="cop" name="cop" href="/">footerlink</a></div></div></td></tr></tbody></table></td></tr></table></body></html>
Thanks
> Impossible to set a title in rich:page with <f:facet name="pageHeader" >
> ------------------------------------------------------------------------
>
> Key: RF-8139
> URL: https://jira.jboss.org/jira/browse/RF-8139
> Project: RichFaces
> Issue Type: Bug
> Affects Versions: 3.2.0.SR1
> Environment: jboss 4.2.2/jdk1.6/richface 3.2.0sr1
> Reporter: D'Alton Jean-Adrien
> Assignee: Nick Belaevski
> Attachments: rf8139.xhtml, rf8139_page.xhtml
>
>
> It is impossible to set title of a page with facet PageHeader : the generated page generate 2 titles wich an empty title is in first position:
> :
> Source of generated page from firefox:
> -----------------------------------------------------
> <html lang="fr" xmlns="http://www.w3.org/1999/xhtml">
> <head>
> <title></title>
> <title>My title for a page</title>
> .....
> .xhtml page :
> ---------------
> <rich:page 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:rich="http://richfaces.org/rich"
> xmlns:a4j="http://richfaces.org/a4j" markupType="xhtml"
> contentType="text/html" theme="#{prefs.layout.theme}"
> width="#{prefs.layout.width}" sidebarWidth="#{prefs.layout.sidebarWidth}"
> sidebarPosition="#{prefs.layout.position}" oncontextmenu="return false;" >
>
> <f:view contentType="text/html" > <!-- safari compatibility -->
>
> <f:facet name="pageHeader">
> <title><ui:insert name="title" /></title>
> </f:facet>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the richfaces-issues
mailing list