forrest-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject [JIRA] Commented: (FOR-127) Tab Menu behaviour
Date Fri, 11 Mar 2005 16:33:18 GMT
The following comment has been added to this issue:

     Author: Cyriaque Dupoirieux
    Created: Fri, 11 Mar 2005 10:32 AM
Ok, I try your example this morning and I have the same result in 0.7-dev.

All I can say is :
- The tabs point on an indexfile which is not used in site.xml
- in tabutil.xsl, the value of $matching-id variable is empty when you click on a tab.
- whereas it is well valued when you click on link corresponding to a tab.

I think that the <xsl:value-of select="$site//*[starts-with(@href, $path)]/@tab"/> to
define $matching-id is good on my opinion, but I don't understand why it does not work that
case ?
Is it because the indexfile specified in tabs.xml does not appear in site.xml ?

(Can someone link - or merge - the following FOR (FOR-128) which describes the same problem)

View this comment:

View the issue:

Here is an overview of the issue:
        Key: FOR-127
    Summary: Tab Menu behaviour
       Type: Bug

     Status: Unassigned
   Priority: Major

    Project: Forrest
             Core operations

   Reporter: Warrell Harries

    Created: Mon, 29 Mar 2004 12:56 PM
    Updated: Fri, 11 Mar 2005 10:32 AM
Environment: Any

For the following site.xml :-

<site label="Hill Crest" href="" xmlns="" tab="home">

<children label="Childrens Services" href="children/" tab="children">
	<bartons label="The Bartons" href="bartons.html" description="Bartons"/>
	<pentwyn label="Pentwyn" href="pentwyn.html" description="Pentwyn" />
	<slinfold label="Slinfold" href="slinfold.html" description="Slinfold" />
	<leyton label="Leyton" href="leyton.html" description="Leyton" />
	<norwood label="Norwood" href="norwood.html" description="Norwood" />
	<kingsbromley label="Kings Bromley" href="kingsbromley.html" description="KB" />

<disability label="Learning Disability Services" href="disability/" tab="disability">
	<penge label="Penge" href="penge.html" description="Penge"/>
	<penge label="Vernon" href="vernon.html" description="Vernon"/>
	<penge label="Beach Road" href="beachroad.html" description="BR"/>
	<penge label="Keston" href="keston.html" description="Keston"/>

<foster label="Fostercare" href="foster/" tab="foster">

<education label="Education" href="education/" tab="education">

<referral label="Referral" href="referral/" tab="referral">

<recruitment label="Recruitment " href="recruitment/" tab="recruitment">
</recruitment >


and the following tabs.xml

<tabs software="MyProj"

  <tab id="home" label="Home" dir="" indexfile="index.html"/>
  <tab id="children" label="Children's Services" dir="children" indexfile="index.html"/>
  <tab id="disability" label="Learning Disability Services" dir="disability" indexfile="index.html"/>
  <tab id="foster" label="Fostercare" dir="foster" indexfile="index.html"/>
  <tab id="education" label="Education" dir="education" indexfile="index.html"/>
  <tab id="referral" label="Referral" dir="referral" indexfile="index.html"/>
  <tab id="recruitment" label="Recruitment" dir="recruitment" indexfile="index.html"/>


The tabs are not selected when clicked. i fixed this by changing the
tab2menu.xsl template to this :-

<xsl:template match="tab" mode="level1">
      <xsl:when test="@id and @id = $matching-id">
        <xsl:call-template name="selected"/>
      <xsl:when test="not(@id) and @dir = $longest-dir or @href = $longest-dir or @dir
= $longest-dir ">
        <xsl:call-template name="selected"/>
        <xsl:call-template name="not-selected"/>

The long test is not correct because it assumes an id is not being used and therefore does
not check the directory.

It would be much better if forrest had a single way of defining tabs and menus

This message is automatically generated by JIRA.

If you think it was sent incorrectly contact one of the administrators:

If you want more information on JIRA, or have a bug to report see:

View raw message