| ||||||||||
Shopping cart software Solutions for online shops and malls | ||||||||||
|
X-Cart Home | FAQ | Forum rules | Calendar | User manuals | Login |
V4 - keeping first level subcategories viewable at all times | ||||
|
|
Thread Tools | Search this Thread |
#11
|
|||||||
|
|||||||
I really like this mod Fernando did and implemented it on a site. Yet, we do have a problem with it in that once a customer gets to the products, no categories at all show up. I wonder if there is a way this could be written to show the subcategories of the root category where the products are located. Any ideas or help appreciated.
Zak Version 4.0.11 |
|||||||
#12
|
|||||||
|
|||||||
@mpj: please post your current status and some lines of code. Perhaps i can help you to solve the poblems.
@all: Is it possible to give out only the 1st category on each time in a new box? |
|||||||
#13
|
|||||||
|
|||||||
Hi,
I'll check to see if the version posted here is up to date. If it isn't, I'll be glad to post the latest version later on.
__________________
Fernando Sorry, I\'m not using x-cart anymore, so I am unable to reply to enquiries about modules. Thank you. |
|||||||
#14
|
|||||||
|
|||||||
fernando
your code works great! i implemented this with another mod and it IS exactly what I was looking for. Had a real problem getting {parentid} and {categoryid} many thanks. - mpj my code is still in beta so as soon as i get bugs out, i'll post and share with everyone.
__________________
X-Cart 4.0.11 {My simple mods} Adding Market list and % save on product detail Quantity input box |
|||||||
#15
|
|||||||
|
|||||||
Fernando's code
hi there! I have implemented Fernando's code too, and like it. I was wondering, though, if I can use that code to make my menu be expanded at all times. I would imagine it's a piece of that code, but I don't know what piece.
|
|||||||
#16
|
|||||||
|
|||||||
hi sonia,
you may want to look at this link http://forum.x-cart.com/viewtopic.php?t=14905&highlight=subcategories hth - mpj
__________________
X-Cart 4.0.11 {My simple mods} Adding Market list and % save on product detail Quantity input box |
|||||||
#17
|
|||||||
|
|||||||
Actually, I did, but I don't want that one because the list is unordered. I want to maintain the POS order I've determined in the software.
|
|||||||
#18
|
|||||||
|
|||||||
Okay, I'm still wrestling with this code, and to top it off my partner and I keep changing our minds as to how to approach the navigation for our site.
At the moment, I am using the famous "Fernando Code", but the sort order is by alphabet. I have tried various changes to the "include/categories.php" page (see http://forum.x-cart.com/viewtopic.php?t=11876&highlight=categories+php), but the subcategory menu continues to list in alphabetical order. I think I need to sort the order in his code somehow, but I don't know how. Here's his code again, added of course to categories.tpl: Code:
I'm thinking there's got to be code I can add to his that will allow me to sort the list by "order_by" (POS) instead. Can anyone help me with this? |
|||||||
#19
|
|||||||
|
|||||||
Hi Sonia,
Unfortunately, Smarty doesn't have an array ordering function (I did look for this one when I wrote the code...). There's two options as I see it: 1: modify categories.php so that the allcategories array is sorted by position (or probably better, create a sorted allcategories array clon and working with it from the .tpl) 2: create a smarty {sortarray} function. Perhaps a more drastic approach, but then again, a good way to contribute to a different project!!
__________________
Fernando Sorry, I\'m not using x-cart anymore, so I am unable to reply to enquiries about modules. Thank you. |
|||||||
#20
|
|||||||
|
|||||||
That would be me as a deer in headlights when it comes to smarty code, so I will have to think of something else for now.
Thanks, Fernando, both for supplying us all with that great code, and for responding now. |
|||||||
|
|||
X-Cart forums © 2001-2020
|