Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

problems with combine 2 contribs


woodde

Recommended Posts

I'm using the Base Price contribution and it works fine. Recently i stumble upon the "Product Listing in Columns 2.2.7"contribution

 

I've tried to combine both but i failed. Anyone combinated both already and can direct me to what to do?

 

code of my product_listing.php file (used before adding the colums contribution)

          case 'PRODUCT_LIST_PRICE':
//Base Price Change
           $lc_align = 'right';
           $lc_text = tep_get_products_display_price($listing['products_id']) . tep_get_products_display_price($listing['products_id'], true) . '<br>';
//Base Price End
           break;

 

this results in:

 

bp_1.jpg

 

note the Price of 21,06 EUR and the Baseprice of 8,49 EUR / m²

 

 

code used in the product_listing_col.php file:

case 'PRODUCT_LIST_PRICE':
			$lc_align = 'right';
			if (tep_not_null($listing[$x]['specials_new_products_price'])) {
				$lc_text = '<br> <s>' .  $currencies->display_price($listing[$x]['products_price'], tep_get_tax_rate($listing[$x]['products_tax_class_id'])) . '</s><br><span class="productSpecialPrice">' . $currencies->display_price($listing[$x]['specials_new_products_price'], tep_get_tax_rate($listing[$x]['products_tax_class_id'])) . '</span> ';
			} 
			else {
				$lc_text = '<br>' . $currencies->display_price($listing[$x]['products_price'], tep_get_tax_rate($listing[$x]['products_tax_class_id'])) . ' <br><br>';
			}
			break;

this results in:

 

bp_2.jpg

 

without baseprice.

 

 

I've tried several ways to include that "old" code but all failed. Anyone have a clue what to do to use this colums contribution with the base price contribution?

Link to comment
Share on other sites

I'm using the Base Price contribution and it works fine. Recently i stumble upon the "Product Listing in Columns 2.2.7"contribution

 

I've tried to combine both but i failed. Anyone combinated both already and can direct me to what to do?

 

code of my product_listing.php file (used before adding the colums contribution)

Perhaps this?

case 'PRODUCT_LIST_PRICE':
			$lc_align = 'right';
			if (tep_not_null($listing[$x]['specials_new_products_price'])) {
				$lc_text = '<br> <s>' .  $currencies->display_price($listing[$x]['products_price'], tep_get_tax_rate($listing[$x]['products_tax_class_id'])) . '</s><br><span class="productSpecialPrice">' . $currencies->display_price($listing[$x]['specials_new_products_price'], tep_get_tax_rate($listing[$x]['products_tax_class_id'])) . '</span> ';
			} 
			else {
				$lc_text = '<br>' . tep_get_products_display_price($listing[$x]['products_id']) . tep_get_products_display_price($listing[$x]['products_id'], true) . '<br>';
			}
			break;

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...