Announcement

Collapse
No announcement yet.

Changing View Of Subsections

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Changing View Of Subsections

    I will try and make this sound as uncomplicated as possible:

    Within a section on my store I have subsections.

    Within each of these subsections there are products.

    How can I make the subsections within a section appear in a drop down list as opposed to a regular list of items?

    The best example I could find on what I am rying to achieve is from the website: www.inkmasters.co.uk

    Check out this URL http://www.inkmasters.co.uk/acatalog...artridges.html

    I believe I need to create new act_primary templates for each section.... I need some detailed instructions on what to do to achieve this.

    Any help would be greatly appreciated!

    Amar (tearing my hair out over trying to nail this one!)

    #2
    Hi there

    Within your main section, go to the "Layout" tab and tick "Override Default Settings" in "Location and Arrangement of Section list". This will take out the listing of the subsections.
    Now download the Advance User Guide and look on Page 35 - "Creating a Drop-Down List Containing the Top-Level Sections and Sub Sections".
    You would need to open your "Act_Primary.html" and save it as another file (eg Act_PrimaryCustom.html). Within "Act_PrimaryCustom.html" you need to implement this javascript. Now within the main section under "Layout" where it says "Overall Layout", simply click on "Select" and "Browse" and find "Act_PrimaryCustom.html".

    You should have the drop down list box. The issue with this, is that the javascript shows the main section and subsection so you may need to fiddle around with the script to take out the main section.

    The following code may just show the subsection

    Code:
    function ACT_DropListBox(ar)
    {
    var strIDs = '<SELECT SIZE="1" NAME="ACT_droplstbox" onClick="if(options[selectedIndex].value) window.location.href=(options[selectedIndex].value)">';
    var sel = " SELECTED"
    strIDs += '<OPTION ' + sel + ' VALUE="">Select a Section</OPTION>';
    for (var i=1;i<=ar.length;i++)
      {
       
          if (ar[i].pChild)
            {
            for (var j=1;j<=ar[i].pChild.length;j++)
              {
              strIDs += '<OPTION VALUE="' + ar[i].pChild[j].sURL + '">' + '- ' + ar[i].pChild[j].sName + '</OPTION>';
                {
                if (ar[i].pChild[j].pChild)
                  {
                  for (var k=1;k<=ar[i].pChild[j].pChild.length;k++)
                    {
                    strIDs += '<OPTION VALUE="' + ar[i].pChild[j].pChild[k].sURL + '">' + '- - ' + ar[i].pChild[j].pChild[k].sName + '</OPTION>';
                    }
                  }
                }
              }
            }
          
        
      }
    strIDs+='</SELECT>'
    return strIDs
    }
    //-->
    </SCRIPT>
    Kind Regards
    Nadeem Rasool
    SellerDeck Development

    Comment


      #3
      That Inkmasters site looks like they've hand-coded the drop down lists.
      Norman - www.drillpine.biz
      Edinburgh, U K / Bitez, Turkey

      Comment

      Working...
      X