Forums / Templates, Stylesheets, Page Layout / replace more info w add to cart button

replace more info w add to cart button

Locked

Views: 1,646

Results 1 to 4 of 4
This thread is locked. New replies are disabled.
1 Jun 2010, 9:54 PM
#1
tx_rustler avatar

tx_rustler

New Zenner

Join Date:
Feb 2010
Location:
Texas - The Republic
Posts:
27
Plugin Contributions:
0

replace more info w add to cart button

When there is more than one product in a category, ZC puts up a list, price on the right and a more info link.

Can the more info link be replaced by an "Add to Cart" button, and yet still have the product title stay linked to the product detail page?

If so how?

Thanks
Jim

Products are zip file downloads only.

WIP web site is
https://www.ernest-education.com/eecdlst/

1 Jun 2010, 10:01 PM
#2
schoolboy avatar

schoolboy

Totally Zenned

Join Date:
Jun 2005
Location:
Cumbria, UK
Posts:
10,327
Plugin Contributions:
0

Re: replace more info w add to cart button

Products are zip file downloads only.

Because the download function is an element of zencart's attributes, the default behaviour will be to change the add to cart, to more info.

I think there is a work-around, but I am not sure of how it is applied in the context of downloadable products...

20 years a Zencart User

2 Jun 2010, 1:24 PM
#3
tx_rustler avatar

tx_rustler

New Zenner

Join Date:
Feb 2010
Location:
Texas - The Republic
Posts:
27
Plugin Contributions:
0

Re: replace more info w add to cart button

schoolboy:

Because the download function is an element of zencart's attributes, the default behaviour will be to change the add to cart, to more info.

I thought the more info link was only placed on pages with more than one product - at least that is the way it shows on my site. If there is only one item in the category, then that item shows with an add to cart button.

With the caveat that I know next to nothing about php ...

The more info link uses the products_id as does the add to cart function. I would assume that when the add to cart is clicked ZC looks up the products_id and at that time determines the attribute. Since the items I am interested in doing this with only have one attribute, I would think it would default to it.

So I guess I am wondering if in the

<td class="productListing-data" align="right"> section is there a way to replace the call for the moreinfo link with the add to cart function?

And just to complicate it even more I only want to do that on certain product category pages.

20 Sep 2010, 5:26 PM
#4
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: replace more info w add to cart button

I recall seeing this discussed recently (possibly by DrByte), but have no idea of what is involved in doing the tweak. Where you see the add to cart for categories with only one product, that is because the listing page is being skipped entirely, going straight to the product info page. So that is irrelevant to getting the listing the way you want.