Site maintenance: Tuesday 17 Nov, from 10:00 UTC, about 4–6 hours. Details

This cutover relies on some testing that is still incomplete so may be cancelled at short notice

Forums / General Questions / How to Seperate New General Documents from New Products ?

How to Seperate New General Documents from New Products ?

Started by heyits007 on 25 Jul 2011, 5:54 AM · Views: 901

Results 1 to 5 of 5
25 Jul 2011, 5:54 AM
#1
heyits007 avatar

heyits007

Zen Follower

Join Date:
Sep 2010
Posts:
270
Plugin Contributions:
0

How to Seperate New General Documents from New Products ?

Is it possible to Separate New Documents from New Products in the New Products listing option ? When I list new products, it's also listing new Document General items, that I don't want listed along with new products, as they clutter up the actual new products list.

Thanks,
007

26 Jul 2011, 5:03 PM
#2
heyits007 avatar

heyits007

Zen Follower

Join Date:
Sep 2010
Posts:
270
Plugin Contributions:
0

Re: How to Seperate New General Documents from New Products ?

V 1.39h

I gather it might be a limitation of the ZenCart search function, unless it can be switched off to ignore Document General.

Thanks,
007

26 Jul 2011, 5:21 PM
#3
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: How to Seperate New General Documents from New Products ?

You could customize the SELECT statements to exclude the products_type that you do not want included on New Products ...

For example, in the:
/includes/modules/pages/products_new/header_php.php

  $products_new_query_raw = "SELECT p.products_id, p.products_type, pd.products_name, p.products_image, p.products_price,
                                    p.products_tax_class_id, p.products_date_added, m.manufacturers_name, p.products_model,
                                    p.products_quantity, p.products_weight, p.product_is_call,
                                    p.product_is_always_free_shipping, p.products_qty_box_status,
                                    p.master_categories_id
                             FROM " . TABLE_PRODUCTS . " p
                             LEFT JOIN " . TABLE_MANUFACTURERS . " m
                             ON (p.manufacturers_id = m.manufacturers_id), " . TABLE_PRODUCTS_DESCRIPTION . " pd
                             WHERE p.products_status = 1
AND p.products_type != 3
                             AND p.products_id = pd.products_id
                             AND pd.language_id = :languageID " . $display_limit . $order_by;

Add the code in RED to exclude the General Document Products from the New Products page ...

Then, work you way through the code for the New Products Centerbox and Sidebox ...

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

29 Jul 2011, 4:22 PM
#4
heyits007 avatar

heyits007

Zen Follower

Join Date:
Sep 2010
Posts:
270
Plugin Contributions:
0

Re: How to Seperate New General Documents from New Products ?

Ahh ok thanks. I will give it a try. Can I apply this as an override ? rather than editing the original code ?

Thanks,
007

29 Jul 2011, 5:04 PM
#5
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: How to Seperate New General Documents from New Products ?

Not on that particular file ... but you could on the New Products module and New Products sidebox ...

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!