Jump to content

Organise Category's???


Guest naturallyloseweight

Recommended Posts

Guest naturallyloseweight

Hi the categories on the left nav. menu, how do I organise these without having to delete and put them in order manually?

is there a way?

www.loseweightnaturally.co.uk/store

Link to comment
Share on other sites

It depends on how you want them ordered. If you want them in alphabetical order do this:

Open /includes/contents/viewCat.inc.php

Find somewhere @ line 158

$productListQuery = "SELECT ".$glob['dbprefix']."CubeCart_cats_idx.cat_id, ".$glob['dbprefix']."CubeCart_cats_idx.productId, productCode, quantity, description, image, price, name, popularity, sale_price, stock_level, useStockLevel FROM ".$glob['dbprefix']."CubeCart_cats_idx INNER JOIN ".$glob['dbprefix']."CubeCart_inventory ON ".$glob['dbprefix']."CubeCart_cats_idx.productId = ".$glob['dbprefix']."CubeCart_inventory.productId WHERE ".$glob['dbprefix']."CubeCart_cats_idx.cat_id = ".$db->mySQLSafe($_GET['catId']);

Replace it with

$productListQuery = "SELECT ".$glob['dbprefix']."CubeCart_cats_idx.cat_id, ".$glob['dbprefix']."CubeCart_cats_idx.productId, productCode, quantity, description, image, price, name, popularity, sale_price, stock_level, useStockLevel FROM ".$glob['dbprefix']."CubeCart_cats_idx INNER JOIN ".$glob['dbprefix']."CubeCart_inventory ON ".$glob['dbprefix']."CubeCart_cats_idx.productId = ".$glob['dbprefix']."CubeCart_inventory.productId WHERE ".$glob['dbprefix']."CubeCart_cats_idx.cat_id = ".$db->mySQLSafe($_GET['catId'])." ORDER BY name ASC";

If you want them in a custom order, Sir William has a category Order mod at cubecart.org

Link to comment
Share on other sites

  • 1 month later...
Guest degsey69

If you go into cubecart.org and the archived forums there is a free mod which arranges the catergories in alphabetical order.

It does work as i have applied it to my site.

Regards

Degsey :D

Link to comment
Share on other sites

======================================

open includes/boxes/categories.inc.php

======================================

************************************************

** **

** First make a back-up of the origianl file. **

** **

************************************************

About line 35

// query database

$results = $db->select("SELECT cat_name, cat_id FROM ".$glob['dbprefix']."CubeCart_category WHERE cat_father_id = 0");

$resultsForeign = $db->select("SELECT cat_master_id as cat_id, cat_name FROM ".$glob['dbprefix']."CubeCart_cats_lang WHERE cat_lang = '".$lang_folder."'");

REPLACE WITH

// query database

$results = $db->select("SELECT cat_name, cat_id FROM ".$glob['dbprefix']."CubeCart_category WHERE cat_father_id = 0 order by cat_name");

$resultsForeign = $db->select("SELECT cat_master_id as cat_id, cat_name FROM ".$glob['dbprefix']."CubeCart_cats_lang WHERE cat_lang = '".$lang_folder."' order by cat_name");

========================

Save, Close, Upload file

========================

Link to comment
Share on other sites

If you want them in a custom order, Sir William has a category Order mod at cubecart.org

# Advertising of competitors products, related products or services with or without a link is not allowed. We are aware that there are many 3rd party modifications and services which are popular but no direct links may be posted to these in forum posts or signatures. We will only make one exception to this rule in that we will allow members to suggest that they may find the product service they require at www.cubecart.org with a search term.

e.g. “You may find what you are looking for at www.cubecart.org. Search for 'SEO'”

According the the rules, we are unable to mention SPECIFIC mods, but only tell people that a mod is available.

If a rule is to mean something, then EVERYONE needs to follow it.

Otherwise, allow us to also mention specific mods where appropriate. God knows, there have been many times I've wanted to, but was forbidden by 'the rules'.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...