Topic RSS
This post actually belongs in the "support" forum. (The "How to" forum is for finished instructions on how to do things — not questions)
Anyway, the "grid-view" template doesn't actually show categories, but products themselves.
If you want to change the order of the product images on the grid-view page, then you just need to modify on or around line #34 of the "gridview.php" file where it says:
$wp_query->query('orderby=title&order=asc&cat='.$grid_cat_id.'&showposts='.$mkt_options['mkt_grid_thumbs_per_page'].'&paged='.$paged);The "orderby" value can be changed to different values as described here:
Yes, the storefront homepage template makes more sense. It's the "frontdoor.php" file.
In this case, the line to change is on #14 where it says:
<?php $my_query = new WP_Query('cat='.$mkt_options['product_cat'].'&showposts='.$mkt_options['mkt_newprods_storefront']); You can reference the page:
http://codex.wordpress.org/Cla…..Parameters
for the parameters you can use to modify the "orderby" process. This parameter is currently not shown in the link, so you'd need to add it in yourself.
I hope this helps.
Not sure exactly how to add the "orderby" code, but even if I did this seems to be for posts as it uses parameters such as date which I can't change for a category. Is there any way I can have control over the order and not be dependant on alphabetical order or other parameters I can't change? I need to be able to group 3 categories of a certain type in the rows I choose.
If you're asking if there is a built-in way that you can define the order of categories manually, I don't think there is. Categories in Wordpress don't have a "sort order" like posts do.
A possible work around, is to rename the category name to begin with a number.
Sort of like this:
1) Category name
2) Category Name
3) Category Name
Other than that, I don't know. A coder could go in and hard code so that certain category IDs showed up in a certain order, but nothing I can offer in the way of that code. Sorry.
Sorry, I may have provided bad information initiall on this one.
You may need to alter lines on or around #1681 through #1685 in the "functions.php" file where it says:
// show all category children and grandchildren
$productCats = get_categories('hide_empty=0&child_of='.$cat);
} else {
// show only direct category children
$productCats = get_categories('hide_empty=0&parent='.$cat); Just add in the "orderby" parameter like this:
// show all category children and grandchildren
$productCats = get_categories('orderby=slug&hide_empty=0&child_of='.$cat);
} else {
// show only direct category children
$productCats = get_categories('orderby=slug&hide_empty=0&parent='.$cat);
Make sure to save the file.
This is the Wordpress Codex page for the "orderby" info.
http://codex.wordpress.org/Fun…..categories
I think that's better.
Most Users Ever Online: 40
Currently Online:
21 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Member Stats:
Guest Posters: 428
Members: 2252
Moderators: 1
Admins: 1
Forum Stats:
Groups: 1
Forums: 4
Topics: 2983
Posts: 16042
Newest Members: Allsed, deleteduser, shanm, slidesketch, jimharrison, vmi
Moderators: Market Admin (5051)
Administrators: Market Admin (5051)

Log In
Register
Home
Offline

