close ad
WARNING: Do Not Install the DREAMWEAVER CC 2017 or 2018 Update »
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Powerstore 2 major bug

Thread began 8/04/2010 3:50 pm by warrenphillips25336771 | Last modified 8/04/2010 6:34 pm by Jason Byrnes | 470 views | 3 replies |

warrenphillips25336771Beta Tester

Powerstore 2 major bug

Hi

Got powerstore 2 running for 2 of my clients, problem is at checkout when updating the quantity, you can put decimals and the cart will add the decimal, so for example a client wants to buy a fireplace, he can update the quantity with 1.5 and it will calculate one full set and half a set, is there a way to rectify this as this should not be allowed to happen. Check on site woodburnstoves(.)co(.)uk add a product on cart page put in 1.5 and see the result

Sign in to reply to this post

Jason ByrnesWebAssist

in the WA_eCart/WA_Store_Cart_PHP.php file, find the folloowing:

php:
if (isset($_POST[$this->CartName."_Quantity_list_".$n])) {

      $itemQuantity = floatval($_POST[$this->CartName."_Quantity_list_".$n]);
    }
    if (isset($_POST[$this->CartName."_Quantity_".$n])) {
      $itemQuantity = floatval($_POST[$this->CartName."_Quantity_".$n]);
    }
    if (isset($_POST[$this->CartName."_Quantity_check_".$n])) {
      $itemQuantity = floatval($_POST[$this->CartName."_Quantity_check_".$n]);
    }




and change it to:

php:
if (isset($_POST[$this->CartName."_Quantity_list_".$n])) {

      $itemQuantity = intval($_POST[$this->CartName."_Quantity_list_".$n]);
    }
    if (isset($_POST[$this->CartName."_Quantity_".$n])) {
      $itemQuantity = intval($_POST[$this->CartName."_Quantity_".$n]);
    }
    if (isset($_POST[$this->CartName."_Quantity_check_".$n])) {
      $itemQuantity = intval($_POST[$this->CartName."_Quantity_check_".$n]);
    }
Sign in to reply to this post

warrenphillips25336771Beta Tester

Thanks

Thanks Jason

Was it a bug?

Sign in to reply to this post

Jason ByrnesWebAssist

It can be argued both way's really.

take a grocery store that sells bulk flour. The customer should be able to order 2.25 pounds of flour.

But in the instance of an electronics store, you can't sell half of a tv.

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...