Re: Categories and Sub-categories

This WebDNA talk-list message is from

2003


It keeps the original formatting.
numero = 47300
interpreted = N
texte = Along with what the others said. You will need to have both a category and a subcat field in your database. I've never actually played with the tearoom before (sorry to all the peers whom told me to master it first ;-). But, somewhere in the tearoom system there is probably going to be a database with a category field. Add a subCategory field to that. Then on your results page you will probably find a search. Depending on how your comparisons are set up (sometimes they can be set up in a [text][/text] var or through a form field from the previous page) you will have to specify something like: eqSUBCATEGORYdatarq=[url][__subcat][/url] (not exact var names obviously) when someone clicks on the subcategory. I like to set a text var with a [showif] for this. something like:[showif [the_search]=CAT] [text]--search comparison without a subcat--[/text] [/showif][showif [the_search]=SUB] [text]--search comparison without a subcat and only with a category--[/text] [/showif][search][/search] Then in your admin, you will have to add the ability to edit that new field in your database. The idea is that when you click on the category... you will search with only the category info and when you click on a subcategory, you can search for only the subcategory.HTH, DonovanSuperior Shelving wrote:> Hello, > > We're converting the TeaRoom XML example to fit our store and I > could use some help. > > Does anybody have an example of how to show sub-categories under the > main categories on the same page? What I'd like to do is something > like this: > > There would be the following main categories on the Search.tpl page: > > -Industrial Shelving > -Plastic/Polymer Shelving > -Solid Metal Shelving > -Wire Shelving > > Let's say you clicked on Industrial Shelving. I'd like it then to > display the sub-categories on the same page like so: > > -Industrial Shelving > --Rivet Style Shelving w/wood decking > --Rivet Style Shelving w/Melamine decking > --Rivet Style Shelving w/wire decking > --Rivet Style Shelving w/o decking > -Plastic/Polymer Shelving > -Solid Metal Shelving > -Wire Shelving > > I'd also like to continue in this vain with sub-sub-categories. > Lets say you now clicked on Rivet Style Shelving w/wood decking. I'd > like it to display something like this: > > -Industrial Shelving > --Rivet Style Shelving w/wood decking > ---Single Rivet Units > ---Double Rivet Units > ---Workbenches > ---Individual Single Rivet Shelves > ---Individual Double Rivet Shelves > --Rivet Style Shelving w/Melamine decking > --Rivet Style Shelving w/wire decking > --Rivet Style Shelving w/o decking > -Plastic/Polymer Shelving > -Solid Metal Shelving > -Wire Shelving > > Also, if you were to change your mind and now want plastic shelving, > you'd be able to click that link (or any other, for that matter) and > the list would branch out under that category or sub-category just > like the above example. In other words, all links would remain active > no matter how for down the category tree you'd go. Then once you > clicked on the final sub-sub-category, you'd be taken to the item list > (Results.tpl) page, as in the TeaRoom example. > > Regards, > Marc > > *--*--*--*--*--*--*--*--*--*--*--*--*--*--* > Superior Shelving Systems > P.O. Box 6949 > Tacoma, WA 98406 > > 253-756-8138 > 253-752-1610 fax > > http://www.SuperiorShelving.com > > The Storage Shelving Specialists > Since 1984 > *--*--*--*--*--*--*--*--*--*--*--*--*--*--* > > > ------------------------------------------------------------- > This message is sent to you because you are subscribed to > the mailing list . > To unsubscribe, E-mail to: > To switch to the DIGEST mode, E-mail to > > Web Archive of this list is at: http://webdna.smithmicro.com/ >-- -Donovan Brooke -Administrator of IT / -Assc. Art Director -Creative Services -Epsen Hillmer Graphics-402.342.1169 ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/ Associated Messages, from the most recent to the oldest:

    
  1. Re: Categories and Sub-categories (Donovan 2003)
  2. Re: Categories and Sub-categories (Sales 2003)
  3. Re: Categories and Sub-categories (Sales 2003)
  4. Re: Categories and Sub-categories (Donovan 2003)
  5. Re: Categories and Sub-categories (Donovan 2003)
  6. Re: Categories and Sub-categories (Marko Bernyk 2003)
  7. Re: Categories and Sub-categories (Tim Robinson 2003)
  8. Categories and Sub-categories (Superior Shelving 2003)
Along with what the others said. You will need to have both a category and a subcat field in your database. I've never actually played with the tearoom before (sorry to all the peers whom told me to master it first ;-). But, somewhere in the tearoom system there is probably going to be a database with a category field. Add a subCategory field to that. Then on your results page you will probably find a search. Depending on how your comparisons are set up (sometimes they can be set up in a [text][/text] var or through a form field from the previous page) you will have to specify something like: eqSUBCATEGORYdatarq=[url][__subcat][/url] (not exact var names obviously) when someone clicks on the subcategory. I like to set a text var with a [showif] for this. something like:[showif [the_search]=CAT] [text]--search comparison without a subcat--[/text] [/showif][showif [the_search]=SUB] [text]--search comparison without a subcat and only with a category--[/text] [/showif][search][/search] Then in your admin, you will have to add the ability to edit that new field in your database. The idea is that when you click on the category... you will search with only the category info and when you click on a subcategory, you can search for only the subcategory.HTH, DonovanSuperior Shelving wrote:> Hello, > > We're converting the TeaRoom XML example to fit our store and I > could use some help. > > Does anybody have an example of how to show sub-categories under the > main categories on the same page? What I'd like to do is something > like this: > > There would be the following main categories on the Search.tpl page: > > -Industrial Shelving > -Plastic/Polymer Shelving > -Solid Metal Shelving > -Wire Shelving > > Let's say you clicked on Industrial Shelving. I'd like it then to > display the sub-categories on the same page like so: > > -Industrial Shelving > --Rivet Style Shelving w/wood decking > --Rivet Style Shelving w/Melamine decking > --Rivet Style Shelving w/wire decking > --Rivet Style Shelving w/o decking > -Plastic/Polymer Shelving > -Solid Metal Shelving > -Wire Shelving > > I'd also like to continue in this vain with sub-sub-categories. > Lets say you now clicked on Rivet Style Shelving w/wood decking. I'd > like it to display something like this: > > -Industrial Shelving > --Rivet Style Shelving w/wood decking > ---Single Rivet Units > ---Double Rivet Units > ---Workbenches > ---Individual Single Rivet Shelves > ---Individual Double Rivet Shelves > --Rivet Style Shelving w/Melamine decking > --Rivet Style Shelving w/wire decking > --Rivet Style Shelving w/o decking > -Plastic/Polymer Shelving > -Solid Metal Shelving > -Wire Shelving > > Also, if you were to change your mind and now want plastic shelving, > you'd be able to click that link (or any other, for that matter) and > the list would branch out under that category or sub-category just > like the above example. In other words, all links would remain active > no matter how for down the category tree you'd go. Then once you > clicked on the final sub-sub-category, you'd be taken to the item list > (Results.tpl) page, as in the TeaRoom example. > > Regards, > Marc > > *--*--*--*--*--*--*--*--*--*--*--*--*--*--* > Superior Shelving Systems > P.O. Box 6949 > Tacoma, WA 98406 > > 253-756-8138 > 253-752-1610 fax > > http://www.SuperiorShelving.com > > The Storage Shelving Specialists > Since 1984 > *--*--*--*--*--*--*--*--*--*--*--*--*--*--* > > > ------------------------------------------------------------- > This message is sent to you because you are subscribed to > the mailing list . > To unsubscribe, E-mail to: > To switch to the DIGEST mode, E-mail to > > Web Archive of this list is at: http://webdna.smithmicro.com/ >-- -Donovan Brooke -Administrator of IT / -Assc. Art Director -Creative Services -Epsen Hillmer Graphics-402.342.1169 ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/ Donovan

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

NTbeta18 corrupted? (1997) [LOOKUP] (1997) Processing all html files through WebCat or Typhoon (1998) Javascript and Pull Down menus (1999) [WebDNA] PCI fubar (2012) Banners (1997) Newbie - Search question (1998) Country & Ship-to address & other fields ? (1997) New Mac Emailer... (1997) Pre-flight public flag (1997) NT 4.0/IIS WebCat Installation (1998) PCS Frames (1997) ShowIf Question (1998) shipcost (1997) Summing fields (1997) Online reference (1997) Max Record length restated as maybe bug (1997) WebCat2b13 Mac plugin - [sendmail] and checkboxes (1997) Bug Report, maybe (1997) Bug report in listfiles context ... (2002)