BullishD

Member
  • Content count

    8
  • Joined

  • Last visited

Community Reputation

0 Neutral

About BullishD

Profile Information

  • Gender
    Male
  • Location
    Ontario, Canada
  1. Keat, Out of hundreds of products there were 9 that didn't have a tax_type assigned to them. and these items were on all of the orders with messed up tax, except one . there is one order that has an incorrect tax amount, that i cannot explain. But, i can't say what has happened as this store is my wife's and her business partner. and the coupon has been removed. (and all values zero'd out when I look in database). So i can't say if the coupon was set up correct or not. I am also not sure if the products in question on that order have been updated since the order was placed. (that particular order was over a month ago). Since i have little to go on for further investigation and the other incorrect taxes can be explained by no tax_type being set for items in the cart. I am going to say the issue is fixed for now, and watch to see if it happens again. if it does happen again, I'll make sure they don't go in and modify anything until i have had a chance to investigate. Thanks for your help Keat!
  2. Thanks for the reply Keat, They should all be assigned 'Standard Rate'. I am at my 9-5 right now so can't verify, but will check tonight and confirm
  3. I am having an issue with taxes on my site. When no coupons are used, the taxes calculate properly. but when a coupon is added. (either % or value) the tax ends up calculating wrong. I cannot figure out how it comes to the rate it applies. I am on CubeCart Version 6.1.5, The tax rate that should be applied is 13% pictures are worth 1000 words, so I'll try to show what is happening through the following pictures. Here is an order where the tax is calculating wrong. The Subtotal is $73.80 ($82-$8.2). Tax of 13% should mean HST = $9.59. Yet a tax rate of $8.42 is applied. (11.41% ????) This is the coupon that was applied Here are the tax details and tax rules I have looked through the code but can't figure out how the tax is being applied wrong. i have not modified my cart.class.php (it is original) Has anyone seen this behaviour before? or is there something that i have set wrong in the coupon or tax? any help would be appreciated, Thank you!
  4. Thanks for the replies bsmither and Ian, bsmither, that is great and exactly why I posted as I haven't figured out all the established methods yet, much simpler. thank you. I will change to your version and test out Ian, great points, and yes I was aware I would have to maintain these changes at upgrade time. I was actually going to ask if it was worthwhile to make this change as a plug-in instead of core code changes. (I haven't looked into how to do that yet). Very good point with the categories and depending on how they are set up would negate the need for this change. As the categories are currently set up, the manufacturers are not included (this store is for my wife's small business). But they may decide to change that since they are still figuring out how they want it all laid out. Good points, worth mulling over. Thank you
  5. note: This is more of a how to, instead of a question. Please let me know if this is in the wrong spot. I wanted to include our products manufacturer names in the automatically generated SEO product URL. Since when people search for our particular products they will most likely include the manufacturer name in their search. I figure adding the manufacturer name to the url should help with our SEO. I couldn't find a solution on the forums (If one exists, I apologize), so I figured I would add mine here, just in case anyone in the future has a similar need. I am running CubeCart 6.0.12. The area that I was looking to modify is under products -> Search Engines tab. and the field " Custom SEO URL Path * " If this is left blank the system will automatically generate an SEO friendly url for the product. the default behaviour generates the seo path based on the product name. (and possibly the category if that option is selected in store settings) example: Product name: Test Product Manufacturer: Blue Chip Default SEO url: test-product Desired SEO url: blue-chip-test-product In order to accomplish this I had to modify the file ..\classes\seo.class.php First, we want to bring back the products selected manufacturer. Update the SQL statement to return this. in classes\seo.class.php at or near line 276, change } elseif (($prods = $GLOBALS['db']->select('CubeCart_inventory', array('product_id', 'name', 'cat_id'), array('product_id' => (int)$id), false, 1)) !== false) { to } elseif (($prods = $GLOBALS['db']->select('CubeCart_inventory', array('product_id', 'name', 'cat_id', 'manufacturer'), array('product_id' => (int)$id), false, 1, false)) !== false) { This will bring back the ID value of the manufacturer. The next step is to grab the name of the manufacturer, and then display this along with the product name. This next block does both steps. in classes\seo.class.php at or near line 293, replace the line $path = empty($cat_directory) ? $prods[0]['name'] : $cat_directory.'/'.$prods[0]['name']; with $manufacturername = ($manuf = $GLOBALS['db']->select('CubeCart_manufacturers', array('name'), array('id' => (int)$prods[0]['manufacturer']))) ? $manuf[0]['name'] : ''; if ($manufacturername != '') { $path = empty($cat_directory) ? $manufacturername.'-'.$prods[0]['name'] : $cat_directory.'/'.$manufacturername.'-'.$prods[0]['name']; } else { $path = empty($cat_directory) ? $prods[0]['name'] : $cat_directory.'/'.$prods[0]['name']; } And that is it. the first line $manufacturername = ... grabs the name of the manufacturer from the database given the id from the product query above. the second line, and start of the if statement, checks if a manufacturer name exists;Iif it does, it will generate the SEO friend url including the manufacturer name; if it does not, then it will generate the SEO friendly url the 'default' way using just the product name (and possibly the category) I am still new to CubeCart, so those of you with more experience, let me know if I can simplify / optimize this solution. also, speak up if you think it is not worth it from an SEO perspective. I hope this helps someone down the road.
  6. Ok, I was just able to test this, and the code works great, I only made one slight change. The complete change below. (including your recommendations) In the file /classes/cubecart.class.php, near line 587 I changed if ($_GET['_a'] == 'basket' && $this->_basket['billing_address']['user_defined']) { httpredir('index.php?_a=confirm'); } to if (false && $_GET['_a'] == 'basket' && $this->_basket['billing_address']['user_defined']) { httpredir('index.php?_a=confirm'); } i added if (false && instead of what you had if (!$GLOBALS['user']->is() && because of the case where it is a guest user, and they fill in their address in the checkout page, but decide to go back to home (or elsewhere) and eventually hit 'view basket' again. with the ['user']->is() statement, it would send them directly to checkout, where I would still like them to head to the 'basket' first. So, I removed the redirect completely by adding if (false... condition. Unless you see another reason that i am not to keep the ['user']->is() part of the condition. (I am new to cubecart so may be missing something) i will stick with the 'false' condition. Then I followed your code exactly (copied again here) In the file /classes/cubecart.class.php, near line 629: Find: if ($GLOBALS['user']->is() && in_array($_GET['_a'], array('basket', 'cart'))) { Change to: if (false && $GLOBALS['user']->is() && in_array($_GET['_a'], array('basket', 'cart'))) { bsmither, thank you very much for your help on this. I am going to run a few more scenarios through but as it stands right now, I am confident in the result.
  7. Thank you for the quick response bsmither! This is great, I really appreciate you taking the time to help out, I will make the changes and test it out tonight. I'll post back how it goes.
  8. I have recently started to use CubeCart (Version 6.0.12). I have based my skin off of foundation, and everything so far is set up and working as expected except for one piece. Logged in users cannot view their cart, and are forced to go to the checkout page to view/edit their cart contents. (.../index.php?_a=basket gets automatically redirected to .../index.php?_a=confirm). basically, logged in users skip step 1 of the "1. cart / 2. checkout / 3. complete" process. The process works as expected for guests. I understand that users have all the functionality of the 'basket' page on the checkout page, but this is not the expected behaviour for users and will cause confusion. This redirect behaviour breaks "the principal of least astonishment", as the standard flow of ecommerce websites, is to view/edit cart, and then move to checkout. I would like to maintain this standard/expected process for my customers (even if it means extra clicks for them) I would like to remove this redirect for logged in users but have not been able to isolate where this is happening in the code. Can someone point me in the right direction on where I will find the redirect so I can remove it. I should note that in the "your basket" box I only display the 'View Basket' button for both guests and logged in users. Thank you! Forgot to add, that I want to thank the developers for all their hard work on cubecart, it is very much appreciated!