osCommerce and osCMax shopping cart software forums

Shopping Cart Software

osCommerce with teeth!

 
 

decimal values

This is a discussion on decimal values within the osCommerce 2.2 Modification Help forums, part of the osCommerce 2.2 Forums category; I want to sell frames. The price must be, for example "2$ per meter". I have to be able to ...


Go Back   osCommerce and osCMax shopping cart software forums > osCommerce 2.2 Forums > osCommerce 2.2 Modification Help

Register FAQ Members List Calendar Mark Forums Read


Free community membership! Fast easy FREE membership
Closed Thread

 

LinkBack Thread Tools
  #1  
Old 06-30-2004, 08:26 AM
Lurker
 
Join Date: Jun 2004
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
andresgr
Default decimal values

I want to sell frames. The price must be, for example "2$ per meter". I have to be able to send "1,3 meters". If i set quantity, in the basket to "1.3" it goes good... but if i put "0.3" it removes the product from the basket!


I've investigated a little bit and found the line:

while (list($key,) = each($this->contents)) {
if ($this->contents[$key]['qty'] < 1) {
unset($this->contents[$key]);
// remove from database
if (tep_session_is_registered('customer_id')) {
tep_db_query("delete from " . TABLE_CUSTOMERS_BASKET . " where customers_id = '" . (int)$customer_id . "' and products_id = '" . tep_db_input($key) . "'");


etc.

If i change the "< 1" to "<=0" it will work?

Also, in the order report, it will not appear "1.3" but "1" (although the calculations are done with 1.3)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Sponsored Links
Advertisement
Closed Thread

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads

Thread Thread Starter Forum Replies Last Post
Deleting products_stock, options, and values in mysql Dubious osCMax v2 Customization/Mods 1 08-24-2006 06:51 PM
How to Add New Order Status Values MikeS osCMax v1.7 Discussion 2 05-18-2005 01:22 AM
Option values scrol KCount osCommerce 2.2 Modification Help 1 09-14-2004 12:02 PM
Options/Values eviternity osCMax v1.7 Discussion 5 08-02-2004 06:55 AM
Can't access login using default values acrylictribesmen osCMax v1.7 Discussion 0 07-04-2004 01:31 AM


All times are GMT -8. The time now is 10:32 AM.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO
http://www.oscmax.com/forums/
Copyright 2008 osCMax