pvollenweider    2004/09/30 15:51:24 CEST

  Modified files:
    src/view/jsp/include main_menu.inc 
  Log:
  - Bug fix for live mode if the home page doesn't exist on current language
  
  Revision  Changes    Path
  1.8       +17 -15    corporate_portal_templates/src/view/jsp/include/main_menu.inc
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/corporate_portal_templates/src/view/jsp/include/main_menu.inc.diff?r1=1.7&r2=1.8&f=h
  
  
  
  Index: main_menu.inc
  ===================================================================
  RCS file: 
/home/cvs/repository/corporate_portal_templates/src/view/jsp/include/main_menu.inc,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- main_menu.inc     29 Sep 2004 14:55:16 -0000      1.7
  +++ main_menu.inc     30 Sep 2004 13:51:24 -0000      1.8
  @@ -31,22 +31,24 @@
   %>
   <table width="<bean:write name="pageWidth" filter="false"/>" border="0" 
cellspacing="0" cellpadding="0" class="maintable">
   <tr>
  -    <td id="menu0" 
class="topmenu<jahia:ifIsHomePage>on</jahia:ifIsHomePage><%=colorSet%>" 
<jahia:ifIsNotHomePage>onmouseover="javascript:topOn<%=colorSet%>('menu0');" 
onmouseout="javascript:topOff('menu0');"</jahia:ifIsNotHomePage>>
  -        <a href="<bean:write name='currentSite' property='homePage.url' 
ignore='true'/>"><bean:write name='currentSite' property='homePage.title' 
filter='false' ignore='true'/></a>
  -        <jahia:ifIsHomePage>
  -            <jahia:ifPagePropertiesRights>
  -                <jahia:pagePropertiesButton title="<img src=\"images/update.gif\" 
width=\"11\" height=\"11\" border=\"0\" alt=\"Update Home\">"/>
  -            </jahia:ifPagePropertiesRights>
  -        </jahia:ifIsHomePage>
  -        <%
  -          // here we add a cross reference, because the home page will be displayed 
on all the pages that use this template.
  -          // and we want to make sure that the pages' HTML cache is flushed when 
the home page title changes.
  -          if (jData.gui().getContentHomePage().getID() != 
jData.params().getPageID()) {
  -              
org.jahia.content.ContentPageXRefManager.getInstance().setPageID(jData.gui().getContentHomePage().getID(),
 jData.params().getPageID());
  -          }
  -        %>
  -    </td>
  +    <logic:present name="currentSite" property="homePage">
  +        <td id="menu0" 
class="topmenu<jahia:ifIsHomePage>on</jahia:ifIsHomePage><%=colorSet%>" 
<jahia:ifIsNotHomePage>onmouseover="javascript:topOn<%=colorSet%>('menu0');" 
onmouseout="javascript:topOff('menu0');"</jahia:ifIsNotHomePage>>
   
  +            <a href="<bean:write name='currentSite' property='homePage.url' 
ignore='true'/>"><bean:write name='currentSite' property='homePage.title' 
filter='false' ignore='true'/></a>
  +            <jahia:ifIsHomePage>
  +                <jahia:ifPagePropertiesRights>
  +                    <jahia:pagePropertiesButton title="<img 
src=\"images/update.gif\" width=\"11\" height=\"11\" border=\"0\" alt=\"Update 
Home\">"/>
  +                </jahia:ifPagePropertiesRights>
  +            </jahia:ifIsHomePage>
  +            <%
  +              // here we add a cross reference, because the home page will be 
displayed on all the pages that use this template.
  +              // and we want to make sure that the pages' HTML cache is flushed 
when the home page title changes.
  +              if (jData.gui().getContentHomePage().getID() != 
jData.params().getPageID()) {
  +                  
org.jahia.content.ContentPageXRefManager.getInstance().setPageID(jData.gui().getContentHomePage().getID(),
 jData.params().getPageID());
  +              }
  +            %>
  +        </td>
  +    </logic:present>
       <content:absoluteContainerList name="topMenu" id="topMenu" pageLevel="1">
           <%
           String homePageTitle = 
TextHtml.text2html(jData.gui().getContentHomePage().getTitle(jData.params()));
  

Reply via email to