Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

blucollarguy

Archived
  • Posts

    739
  • Joined

  • Last visited

Everything posted by blucollarguy

  1. Yes you can. In includes/modules/vendors_shipping/upsxml.php, do a search for this: $this->_upsGetTimeServices This is the date that is shown to the customer. What you can do is create some code in the products page that will add so many days to the current date, and put that number in the database with the product(a new feild would need to be created for it) and then do a query for the number (this could be done from the shopping_cart class) and then use it to add to the current date(date at the time the customer places the order) replace the code I posted, with it. This shouldn't really be too difficult, but will take some time to work thru. Back up all files you work with and go for it. You have nothing to lose but some time, and generally speaking, time is cheaper than people. Good luck, Craig :)
  2. Sorry I wasn't able to post earlier Paul. Glad you seem to have fixed it. Seems like a strange error considering the function it is referring to as "undefined" should be defined by the Register Globals mod. The file you did the fix in is the file I would have guessed was the one being used so I suppose you found the offending code. Is it still working? Craig :)
  3. So the function is there? so you say this is in the file: //// // Creates a pull-down list of countries function tep_get_country_list($name, $selected = '', $parameters = '') { $countries = tep_get_countries(); return tep_draw_pull_down_menu($name, $countries, $selected, $parameters); } That is strange. I think Jim might be right, you guys have come from the Twilight Zone to mess with us! Craig :o :lol:
  4. That is difficult. Your dates on the id's of the files you posted are 2002, and some of the code that is there, is no longer in those files. the error "tep_array_merge" is from a function that was added in MS2 2.2. So I don't think it really is MS2 2.2. What you could try is to download the latest osC, and do a diff on these particular files, being very careful not to delete any of the code in the original file on your site, but you could add to it from the newer version. Or upgrade the whole site. Craig :)
  5. NO, the version of osCommerce you are running is not compatible with MVS, or vice/versa. Kurt is right, you will need to upgrade your website first, then add MVS. Sorry, Craig :(
  6. This is an easy fix, in admin/includes/database_tables.php: ============= Find Line 57 ============= define('TABLE_ZONES', 'zones'); ============================================ Add After Line 57 and before the closing ?> ============================================ //MVS start define('TABLE_VENDORS', 'vendors'); define('TABLE_VENDORS_INFO', 'vendors_info'); define('TABLE_VENDOR_CONFIGURATION', 'vendor_configuration'); define('TABLE_ORDERS_SHIPPING', 'orders_shipping'); define('TABLE_PACKAGING', 'packaging'); //MVS end Note that this was my bug, I have the wrong data to add in this block of the admin install instructions. V1.2 just got started. Sorry about that.
  7. That was an interesting approach Paul. Very nice. Craig :)
  8. I think you have a bigger problem: MS1. You are not using MS2 and MVS will be difficult at best to get working on your site. Can you update to MS2? Your problems would disappear if you do. Good luck, Craig :)
  9. You have files missing or several blocks of code missing. Double check: admin/includes/functions/general.php and admin/includes/application_top.php You also have a file you apparently renamed "old check out code mltship.php" this file cannot be in this directory with the ".php" extension. If you need to rename a file to keep as a backup, rename it like this: "mltship.php.old_check_out_code" , also, one should never use spaces in file names that you use on the web. Windows is fine with spaces(usually), but Linux(the OS that runs about 90% of the internet, does not like spaces in names. Craig :)
  10. I agree, such options would be very good for MVS. All suggestions concerning MVS(added functionality, optional components, whatever) please don't hesitate to post them, the worst we can do is not add them. This forum has helped us proceed with MVS very nicely, I don't plan to go backwards in that regard. Craig :)
  11. Yes, can be done. FEC has a few bugs with the paymeny modules that require yet more work. But they do play nice. Craig :)
  12. You will need to check the original contribution for the instructions on adding that field to the categories.php page. I haven't completed going thru all the add-ons yet, testing and writing instructions for the ones that don't have them yet. Craig :)
  13. This may be another way of doing things, but could also be a bit difficult because the customer would see the shipping cost including tax from the beginning, never really seeing a price without tax. Craig :)
  14. The original issue with the shipping tax was the fact that the "module" couldn't register properly because of the "array" of vendor modules. The ot_shipping wants one number to use as a tax and one number to use as shipping price, we can't give that with MVS because each Vendor may or may not be taxing the shipping cost. So, my solution was to create it per vendor(actually per group of products) in the order class. This block is from includes/classes/order.php: //MVS start $orders_shipping_id = ''; $check_new_vendor_data_query = tep_db_query("select orders_shipping_id, orders_id, vendors_id, vendors_name, shipping_module, shipping_method, shipping_cost from " . TABLE_ORDERS_SHIPPING . " where orders_id = '" . (int)$order_id . "'"); while ($checked_data = tep_db_fetch_array($check_new_vendor_data_query)) { $this->orders_shipping_id = $checked_data['orders_shipping_id']; } //MVS End $index = 0; $products = $cart->get_products(); for ($i=0, $n=sizeof($products); $i<$n; $i++) { $this->products[$index] = array('qty' => $products[$i]['quantity'], 'name' => $products[$i]['name'], 'model' => $products[$i]['model'], 'tax' => tep_get_tax_rate($products[$i]['tax_class_id'], $tax_address['entry_country_id'], $tax_address['entry_zone_id']), 'tax_description' => tep_get_tax_description($products[$i]['tax_class_id'], $tax_address['entry_country_id'], $tax_address['entry_zone_id']), 'price' => $products[$i]['price'], 'final_price' => $products[$i]['price'] + $cart->attributes_price($products[$i]['id']), //MVS start 'vendors_id' => $products[$i]['vendors_id'], 'vendors_name' => $products[$i]['vendors_name'], //MVS end 'weight' => $products[$i]['weight'], 'id' => $products[$i]['id']); if ($products[$i]['attributes']) { $subindex = 0; reset($products[$i]['attributes']); while (list($option, $value) = each($products[$i]['attributes'])) { $attributes_query = tep_db_query("select popt.products_options_name, poval.products_options_values_name, pa.options_values_price, pa.price_prefix from " . TABLE_PRODUCTS_OPTIONS . " popt, " . TABLE_PRODUCTS_OPTIONS_VALUES . " poval, " . TABLE_PRODUCTS_ATTRIBUTES . " pa where pa.products_id = '" . (int)$products[$i]['id'] . "' and pa.options_id = '" . (int)$option . "' and pa.options_id = popt.products_options_id and pa.options_values_id = '" . (int)$value . "' and pa.options_values_id = poval.products_options_values_id and popt.language_id = '" . (int)$languages_id . "' and poval.language_id = '" . (int)$languages_id . "'"); $attributes = tep_db_fetch_array($attributes_query); $this->products[$index]['attributes'][$subindex] = array('option' => $attributes['products_options_name'], 'value' => $attributes['products_options_values_name'], 'option_id' => $option, 'value_id' => $value, 'prefix' => $attributes['price_prefix'], 'price' => $attributes['options_values_price']); $subindex++; } } $shown_price = tep_add_tax($this->products[$index]['final_price'], $this->products[$index]['tax']) * $this->products[$index]['qty']; $this->info['subtotal'] += $shown_price; $products_tax = $this->products[$index]['tax']; $products_tax_description = $this->products[$index]['tax_description']; if (DISPLAY_PRICE_WITH_TAX == 'true') { $this->info['tax'] += $shown_price - ($shown_price / (($products_tax < 10) ? "1.0" . str_replace('.', '', $products_tax) : "1." . str_replace('.', '', $products_tax))); if (isset($this->info['tax_groups']["$products_tax_description"])) { $this->info['tax_groups']["$products_tax_description"] += $shown_price - ($shown_price / (($products_tax < 10) ? "1.0" . str_replace('.', '', $products_tax) : "1." . str_replace('.', '', $products_tax))); } else { $this->info['tax_groups']["$products_tax_description"] = $shown_price - ($shown_price / (($products_tax < 10) ? "1.0" . str_replace('.', '', $products_tax) : "1." . str_replace('.', '', $products_tax))); } } else { $this->info['tax'] += ($products_tax / 100) * $shown_price; if (isset($this->info['tax_groups']["$products_tax_description"])) { $this->info['tax_groups']["$products_tax_description"] += ($products_tax / 100) * $shown_price; } else { //MVS Start add shipping tax $this->info['tax_groups']["$products_tax_description"] = ($products_tax / 100) * $shown_price + $shipping['shipping_tax_total']; //MVS end While this is not exactly all the code we added to this file, it is the block that pertains to the tax question. By adding the "shipping_tax" here we were able to add it for each Vendors shipping charges rather than across the board on the "total shipping charge" the customer pays. I spent the better of 2 weeks playing with ways to do this as simply as possible to make installation easy. The only other option I can see for us is to write an ot_vendor_shipping module to handle the tax at the same time as the other order total modules do their work. That would be a bit of work, and would have to be installed as yet another step in the MVS installation process, but it could be done. As Jim points out, all the data being worked with here passed via session variables from the "order" class and the "cart" class. Not sure where to go with this at this point. Craig :)
  15. The problem with this idea is that no shipping method has been selected and therefore, no price has been set. I have considered this issue for many issues, but I am yet to come up with a viable solution. Any suggestions will be taken, Craig :)
  16. The code Jim is referencing from ot_shipping.php: if (tep_not_null($order->info['shipping_method'])) { if ($GLOBALS[$module]->tax_class > 0) { $shipping_tax = tep_get_tax_rate($GLOBALS[$module]->tax_class, $order->delivery['country']['id'], $order->delivery['zone_id']); $shipping_tax_description = tep_get_tax_description($GLOBALS[$module]->tax_class, $order->delivery['country']['id'], $order->delivery['zone_id']); $order->info['tax'] += tep_calculate_tax($order->info['shipping_cost'], $shipping_tax); $order->info['tax_groups']["$shipping_tax_description"] += tep_calculate_tax($order->info['shipping_cost'], $shipping_tax); $order->info['total'] += tep_calculate_tax($order->info['shipping_cost'], $shipping_tax); if (DISPLAY_PRICE_WITH_TAX == 'true') $order->info['shipping_cost'] += tep_calculate_tax($order->info['shipping_cost'], $shipping_tax); } $this->output[] = array('title' => $order->info['shipping_method'] . ':', 'text' => $currencies->format($order->info['shipping_cost'], true, $order->info['currency'], $order->info['currency_value']), 'value' => $order->info['shipping_cost']); } } Note the second line. You can "print" out all of the involved variables from this block of code to see if everything is being set. I am thinking that one of these variables is not being set at all. The $GLOBAL could be the issue, but as Jim said, there would be much more missing than just the tax if it were wiped out due to the "register_globals" issue. Try printing out these varaibles and see what is and isn't set. Craig :)
  17. That's great Eddie, glad it's working now. Things like that can be just about anywhere in the code. Ya never know. Craig :)
  18. I have uploaded MVS V1.1. Updated for the couple of issues we had found in V1.0 and added a tool to move products from one Vendor to another. At this point, it only moves ALL products to another Vendor. I plan to add the ability to select from a list of products which ones to move, but to get 1.1 up and out there, I did this simple version first. I included some upgrade instructions for anyone who has already installed V1.0. Craig :)
  19. The code you are referrencing from MVS is such to pass the correct vendors id. The code that adds the tax was added in includes/classes/order.php. This block of code: $this->info = array('order_status' => DEFAULT_ORDERS_STATUS_ID, 'currency' => $currency, 'currency_value' => $currencies->currencies[$currency]['value'], 'payment_method' => $payment, 'cc_type' => (isset($GLOBALS['cc_type']) ? $GLOBALS['cc_type'] : ''), 'cc_owner' => (isset($GLOBALS['cc_owner']) ? $GLOBALS['cc_owner'] : ''), 'cc_number' => (isset($GLOBALS['cc_number']) ? $GLOBALS['cc_number'] : ''), 'cc_expires' => (isset($GLOBALS['cc_expires']) ? $GLOBALS['cc_expires'] : ''), 'shipping_method' => $shipping['title'], 'shipping_cost' => $shipping['cost'], //MVS Start 'shipping_tax' => $shipping['shipping_tax_total'], 'subtotal' => 0, 'tax' => 0 + $shipping['shipping_tax_total'], //MVS End 'tax_groups' => array(), 'comments' => (isset($GLOBALS['comments']) ? $GLOBALS['comments'] : '')); And then in this block: $products_tax = $this->products[$index]['tax']; $products_tax_description = $this->products[$index]['tax_description']; if (DISPLAY_PRICE_WITH_TAX == 'true') { $this->info['tax'] += $shown_price - ($shown_price / (($products_tax < 10) ? "1.0" . str_replace('.', '', $products_tax) : "1." . str_replace('.', '', $products_tax))); if (isset($this->info['tax_groups']["$products_tax_description"])) { $this->info['tax_groups']["$products_tax_description"] += $shown_price - ($shown_price / (($products_tax < 10) ? "1.0" . str_replace('.', '', $products_tax) : "1." . str_replace('.', '', $products_tax))); } else { $this->info['tax_groups']["$products_tax_description"] = $shown_price - ($shown_price / (($products_tax < 10) ? "1.0" . str_replace('.', '', $products_tax) : "1." . str_replace('.', '', $products_tax))); } } else { $this->info['tax'] += ($products_tax / 100) * $shown_price; if (isset($this->info['tax_groups']["$products_tax_description"])) { $this->info['tax_groups']["$products_tax_description"] += ($products_tax / 100) * $shown_price; } else { //MVS Start add shipping tax $this->info['tax_groups']["$products_tax_description"] = ($products_tax / 100) * $shown_price + $shipping['shipping_tax_total']; //MVS end Make sure these 2 blocks are correct, after that, I'm not sure what else would create your issues. There are other edits in this file as well(passing more data for the vendors). The other posting that was having this we never did figure out exactly what was causing his problems, but he was using a very unusual tax setup. Good luck, Craig :)
  20. Did you do your mods using the instructions or a diff tool? MVS V1.0? With so many other mods, I absoluteley suggest using a diff tool AND the instructions. It sounds like your missing a closing tag in checkout_shipping.php. That is an easy miss when adding so many mods together. Double check that all tags have their matching closing tag( open tag: { -- closing tag: }) Craig :)
  21. You got that right, looking at the road map, they have quite a bit left to do. Seems like they should go ahead and consider integrating the MVS system since they have so much left to do. I know someone had posted that they submitted the formal request to add MVS to MS3, but never heard if there was a response. Does anyone know it a response of any kind was ever sent? Craig :)
  22. I know that one works great, not as feature packed obviously, but works very nicely. And of course it fully complies with all osC backend stuff rather than bypassing the "checkout process" and using it's own the way IPN 2.XX and up does. Which matters when you are using other contributions that alter the checkout process like MVS does. For instance, in order to use the email functionality in MVS and it's predecessor, Vendors_Auto_Email, one had to also modify the IPN's checkout process. A real pain. But the "constant" updating taking place from that system was something I really liked very much. Criag :)
  23. My thoughts exactly Jim. I have looked at MS3(cvs) a couple of times over the last 4 or 5 months but have not really done anything with it to find out just how much has been done. Maybe I will add that to my very extensive list. For now though, there isn't much I can add to this particular point other than MVS was designed to work with osC MS2 2.2. Much like PHP 5 or 6 or anything else, we can't control other changes in code architecture via MVS. We obviously will have to be prepared to adapt to each of these changes as they come, but that is all we can do. For my part, I will investigate all of this further as I have time. I appreciate all suggestions concerning this particular issue. Craig :)
  24. I am not familiar with either one. But, I have run into some as of yet unknow problems with the PayPal IPN 2.8 and 3.0. I haven't figured out yet if it involves the "fasteasycheckout" contrib that I added as well, but there is an issue there. Good luck, Craig :)
  25. First, I haven't uploaded 1.1 yet so don't tell everyone you got an advanced copy! :lol: Actuall, this is something else that needs to be added, a note about that. V1.0 was modified and the instructions written against the that updated version of osC. That version contains all the securtity patches that were released. 1.1 on the way this weekend. Craig :)
×
×
  • Create New...