Zen Cart Logo
Forums / Templates, Stylesheets, Page Layout / Replacing More Info text with a button.

Replacing More Info text with a button.

Views: 870

Results 1 to 6 of 6
19 Jan 2011, 2:59 PM
#1
jeniferous avatar

jeniferous

New Zenner

Join Date:
Oct 2010
Posts:
46
Plugin Contributions:
0

Replacing More Info text with a button.

Hi Guys - i've been trying to replace the more info link on the product listing pages with a button for a while now.

I tried adding:-
// more info in place of buy now
define('MORE_INFO_TEXT','<img src="relative_path/to_your/image.gif" alt="Name of Button" />');

to the tpl_product_info_listing code.

I found this in a really old thread but nothing appears to happen!

The site is https://www.jambaroo.co.uk :)

Thankies

19 Jan 2011, 4:05 PM
#2
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: Replacing More Info text with a button.

This works for me:

define('MORE_INFO_TEXT','<img src="includes/templates/TEMPLATE_NAME/images/moreinfo.gif"></img>');

But in english.php. I don't seem to have a tpl_product_info_listing.php file.

19 Jan 2011, 10:10 PM
#3
ladybugmom avatar

ladybugmom

New Zenner

Join Date:
Nov 2008
Posts:
40
Plugin Contributions:
0

Re: Replacing More Info text with a button.

Replace this code in your template:

. MORE_INFO_TEXT .

with:

. zen_image_button(BUTTON_IMAGE_DESIGN, BUTTONS_IMAGE_DESIGN_ALT) .

Then go to languages/english/button_names.php and add:

 
define('BUTTON_IMAGE_DESIGN','button_design.gif');
define('BUTTON_IMAGE_DESIGN_ALT','design your own');
 

Then upload a button image into: includes/templates/your_theme/buttons/english

That should do it. It works for me. :smile:

24 Jan 2011, 11:30 AM
#4
jeniferous avatar

jeniferous

New Zenner

Join Date:
Oct 2010
Posts:
46
Plugin Contributions:
0

Re: Replacing More Info text with a button.

Tried both suggestions and i get nothing.

When you say "add to your template" which file are you referring to? I tried the code in the English.php and tpl_product_info_display files and neither works.

24 Jan 2011, 11:53 AM
#5
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: Replacing More Info text with a button.

As I said, it works for me, so either there's something different about your site (changes to the product listing template files, for example), or maybe the image you want to appear isn't in includes/templates/custom/images.

24 Jan 2011, 6:28 PM
#6
jeniferous avatar

jeniferous

New Zenner

Join Date:
Oct 2010
Posts:
46
Plugin Contributions:
0

Re: Replacing More Info text with a button.

I've managed to get it to show on the featured/all/new listings but i'm struggling to get it to show on the category listings?? Any ideas?