Steel Posted May 19, 2004 Posted May 19, 2004 I am currently trying to remove the buy now and add to cart buttons when I have a price of $0.00 listed in the admin and am having little luck. I got the add to cart solved but now need to fix the buy now button. I have removed the add to cart button by changing this code in product_info.php: <td class="main" align="right"><?php echo tep_draw_hidden_field('products_id', $product_info['products_id']) . tep_image_submit('button_in_cart.gif', IMAGE_BUTTON_IN_CART); ?></td> to this code <? if ($product_info['products_price'] > 0) { ?> <td class="main" align="right"><?php echo tep_draw_hidden_field('products_id', $product_info['products_id']) . tep_image_submit('button_in_cart.gif', IMAGE_BUTTON_IN_CART); ?></td><? } ?> <? if ($product_info['products_price'] == 0) { ?> <td class="main" align="right"> </td><? } ?> Now I have been looking at the product_listing.php file at this: case 'PRODUCT_LIST_BUY_NOW': $lc_align = 'center'; $lc_text = '<a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=buy_now&products_id=' . $listing['products_id']) . '">' . tep_image_button('button_buy_now.gif', IMAGE_BUTTON_BUY_NOW) . '</a> '; break; } But cant seem to get it, any suggestions? am I even on the right track or totaly off? I have tried a 2 contribs "free call for prices and hide add to cart" but they are just not what I want or are not working the way I need them. If I could get this one code fixed I would have my problem solved. Thanks Steel
Steel Posted May 20, 2004 Author Posted May 20, 2004 anyone got any ideas? anyone...... Buller......Buller....Buller...... anyone? :)
Steel Posted May 20, 2004 Author Posted May 20, 2004 Or coupld it be in here? case 'PRODUCT_LIST_BUY_NOW': $lc_text = TABLE_HEADING_BUY_NOW; $lc_align = 'center'; break; } if ( ($column_list[$col] != 'PRODUCT_LIST_BUY_NOW') && ($column_list[$col] != 'PRODUCT_LIST_IMAGE') ) { $lc_text = tep_create_sort_heading($HTTP_GET_VARS['sort'], $col+1, $lc_text); }
Recommended Posts
Archived
This topic is now archived and is closed to further replies.