swishemart Posted March 12, 2005 Share Posted March 12, 2005 I had everything working on my staging server but now on my live site when I checkout on the shipping page it only shows"This is currently the only shipping method available to use on this order." with no options below it. I'm using all of the same files that were on my staging server??? I'm lost :(, any help would be appreciated. BTW, thank you for the great contribution. <{POST_SNAPBACK}> if you want to have options you have to get the multiple shipping version of this Quote Link to comment Share on other sites More sharing options...
swishemart Posted March 12, 2005 Share Posted March 12, 2005 ok i did a little digging on the below error I am getting on the order confirmation page. IF i remove line 29 and 30 from ot_tax.php it removes the errors but the total still shows $0.00 I am still totally lost and cant figure out what to do. :huh: Warning: Variable passed to reset() is not an array or object in /usr341/home/e/v/everspee/public_html/includes/modules/order_total/ot_tax.php on line 29 Warning: Variable passed to each() is not an array or object in /usr341/home/e/v/everspee/public_html/includes/modules/order_total/ot_tax.php on line 30 Quote Link to comment Share on other sites More sharing options...
swishemart Posted March 12, 2005 Share Posted March 12, 2005 ok i did a little digging and the error will go away if I disable tax from showing via the admin panel. But im also having a problem with the total...everything on the confirmation pages shows 0.00 as the totals. im thinking i may have messed up my coding in something. ANY HELP IS APPREICATED! lol this has become an all day event Warning: Variable passed to reset() is not an array or object in /usr341/home/e/v/everspee/public_html/includes/modules/order_total/ot_tax.php on line 29 Warning: Variable passed to each() is not an array or object in /usr341/home/e/v/everspee/public_html/includes/modules/order_total/ot_tax.php on line 30 sorry for the double post but it would'nt let me edit it...MOD please delete my post before this Quote Link to comment Share on other sites More sharing options...
jay jay Posted March 12, 2005 Share Posted March 12, 2005 I had everything working on my staging server but now on my live site when I checkout on the shipping page it only shows"This is currently the only shipping method available to use on this order." with no options below it. I'm using all of the same files that were on my staging server??? I'm lost :(, any help would be appreciated. BTW, thank you for the great contribution. <{POST_SNAPBACK}> Nevermind, figured it out :D Quote Link to comment Share on other sites More sharing options...
crashwave Posted March 12, 2005 Share Posted March 12, 2005 No where in instructions does it say to edit ot_tax.php nor any tax values. You need to check your codes and steps. People have emailed me for that same error Warning: Variable passed to reset() is not an array or object in /usr341/home/e/v/everspee/public_html/includes/modules/order_total/ot_tax.php on line 29 Warning: Variable passed to each() is not an array or object in /usr341/home/e/v/everspee/public_html/includes/modules/order_total/ot_tax.php on line 30 and it is because they did something wrong in order.php. Either you forgot to delete something (usually the case) or you forgot to add a global. Two people had two global lines. Check your order.php that is where the problem is coming from NO WHERE ELSE. Quote q_|_|| _|9~~J >-o>-o q_|_|| )| q_|| ) Link to comment Share on other sites More sharing options...
crashwave Posted March 12, 2005 Share Posted March 12, 2005 Nevermind, figured it out :D <{POST_SNAPBACK}> So what was it? You only had products with individual shipping? Quote q_|_|| _|9~~J >-o>-o q_|_|| )| q_|| ) Link to comment Share on other sites More sharing options...
swishemart Posted March 12, 2005 Share Posted March 12, 2005 GOT IT!!! lol thank you yet again crashwave you were correct on the orders.php heres what i had: function cart() { global $customer_id, $sendto, $billto, $cart, $languages_id, $currency, $currencies, $shipping, $payment; function cart() { global $customer_id, $sendto, $billto, $cart, $languages_id, $currency, $currencies, $shipping, $payment, $shipping_modules;//phpmom.com indv ship added due to the instructions saying to add ANOTHER function instead of chang ethe function so now its just: function cart() { global $customer_id, $sendto, $billto, $cart, $languages_id, $currency, $currencies, $shipping, $payment, $shipping_modules;//phpmom.com indv ship added hope this will help anyone else that is having this problem!! :lol: :lol: :rolleyes: Quote Link to comment Share on other sites More sharing options...
crashwave Posted March 12, 2005 Share Posted March 12, 2005 (edited) BTW instructions do not say add another function they said add another global I changed it somewhat to this function cart() { global $customer_id, $sendto, $billto, $cart, $languages_id, $currency, $currencies, $shipping, $payment; add $shipping_modules as a global like this function cart() { global $customer_id, $sendto, $billto, $cart, $languages_id, $currency, $currencies, $shipping, $payment, $shipping_modules; to add another global does not mean to write the word global again, just add to it. Edited March 12, 2005 by crashwave Quote q_|_|| _|9~~J >-o>-o q_|_|| )| q_|| ) Link to comment Share on other sites More sharing options...
swishemart Posted March 12, 2005 Share Posted March 12, 2005 (edited) BTW instructions do not say add another function they said add another global I changed it somewhat to this function cart() { global $customer_id, $sendto, $billto, $cart, $languages_id, $currency, $currencies, $shipping, $payment; add $shipping_modules as a global like this function cart() { global $customer_id, $sendto, $billto, $cart, $languages_id, $currency, $currencies, $shipping, $payment, $shipping_modules; <{POST_SNAPBACK}> sorry i must have misunderstood i am new to php BTW i never got a chance to say thank you for this great contribution and all of your help..so thank you crashwave Edited March 12, 2005 by swishemart Quote Link to comment Share on other sites More sharing options...
crashwave Posted March 12, 2005 Share Posted March 12, 2005 Your Welcome Any time Quote q_|_|| _|9~~J >-o>-o q_|_|| )| q_|| ) Link to comment Share on other sites More sharing options...
oldworldcharms Posted March 12, 2005 Share Posted March 12, 2005 We got the basic feature of the contribution to work. How do we display the shipping price with the item info on the product_info.php page? I would like to display the shipping cost below the price. Can I add a call to the items page for example. Shipping inside United States: $10.00 Shipping outside United States: Quoted at time of purchase Thanks Elizabeth Quote Link to comment Share on other sites More sharing options...
jay jay Posted March 12, 2005 Share Posted March 12, 2005 So what was it? You only had products with individual shipping? <{POST_SNAPBACK}> Some of the code in shoping_cart.php was messed up. Quote Link to comment Share on other sites More sharing options...
jay jay Posted March 12, 2005 Share Posted March 12, 2005 (edited) We got the basic feature of the contribution to work. How do we display the shipping price with the item info on the product_info.php page? I would like to display the shipping cost below the price. Can I add a call to the items page for example. Shipping inside United States: $10.00 Shipping outside United States: Quoted at time of purchase Thanks Elizabeth <{POST_SNAPBACK}> Here is what I rigged up for my site. I am showing free shipping on items marked with "0" and not displaying anything for items with a price. If you want to show the price instead read my comment in the commented out line. I have no idea how to program so if it's sloppy code I appologize. put this code in product_info.php <?php $products_shipping_query = tep_db_query("select products_ship_price from " . TABLE_PRODUCTS_SHIPPING . " where products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "'");// hadir//phpmom.com ? ? ? ? ?$products_shipping = tep_db_fetch_array($products_shipping_query);//phpmom.com ? ? ? ? ?$products_array[] = array('id' => $products_id, ? ? ? ? ?'products_ship_price' => $products_shipping['products_ship_price']); ? ? ? ? ?$products_ship = $products_shipping['products_ship_price']; ? ? ? ? ?if ( $products_ship == 0 ) { ? ? ? ? ?$products_ship = 'Free Shipping'; ? ?}else{ ? ? ? ? ?$products_ship = ""; ? ?//Show price instead and comment the line above out// $products_ship = "Shipping: $" .$products_shipping['products_ship_price']."\n"; ? ? ? ? ? ? ?} ?><br><? echo $products_ship;?> below <?php echo $products_price; ?> Edited March 12, 2005 by jay jay Quote Link to comment Share on other sites More sharing options...
oldworldcharms Posted March 12, 2005 Share Posted March 12, 2005 Thanks Jay Jay I am not a programer either so I am hoping someone could look at this code and alter it to do the shipping inside US ect.... We got the basic feature of the contribution to work. How do we display the shipping price with the item info on the product_info.php page? I would like to display the shipping cost below the price. Can I add a call to the items page for example. Shipping inside United States: $10.00 Shipping outside United States: Quoted at time of purchase Quote Link to comment Share on other sites More sharing options...
oldworldcharms Posted March 12, 2005 Share Posted March 12, 2005 here is my code for the products page. The echo statement for the price is toward the bottom // extra field modifications gs if (tep_not_null($product_info['products_url'])) { echo '<p>' . sprintf(TEXT_MORE_INFORMATION, tep_href_link(FILENAME_REDIRECT, 'action=url&goto=' . urlencode($product_info['products_url']), 'NONSSL', true, false)). '</p>'; } if (tep_not_null($product_info['products_dimensions'])) { echo '<p>' . TEXT_PRODUCTS_DIMENSIONS . ' ' . stripslashes($product_info['products_dimensions']) . '</p>'; } if (tep_not_null($product_info['products_height'])) { echo '<p>' . TEXT_PRODUCTS_HEIGHT . ' ' . stripslashes($product_info['products_height']) . '</p>'; } if (tep_not_null($product_info['products_width'])) { echo '<p>' . TEXT_PRODUCTS_WIDTH . ' ' . stripslashes($product_info['products_width']) . '</p>'; } if (tep_not_null($product_info['products_depth'])) { echo '<p>' . TEXT_PRODUCTS_DEPTH . ' ' . stripslashes($product_info['products_depth']) . '</p>'; } if (tep_not_null($product_info['products_style'])) { echo '<p>' . TEXT_PRODUCTS_STYLE . ' ' . stripslashes($product_info['products_style']) . '</p>'; } if (tep_not_null($product_info['products_condition'])) { echo '<p>' . TEXT_PRODUCTS_CONDITION . ' ' . stripslashes($product_info['products_condition']) . '</p>'; } if (tep_not_null($product_info['products_year'])) { echo '<p>' . TEXT_PRODUCTS_YEAR . ' ' . stripslashes($product_info['products_year']) . '</p>'; } if (tep_not_null($product_info['products_reference'])) { echo '<p>' . TEXT_PRODUCTS_REFERENCE . ' ' . stripslashes($product_info['products_reference']) . '</p>'; } if ( ($product_info['products_quantity'] <= 0) && (STOCK_CHECK =='true') ) { echo '<br>' . TEXT_OUT_OF_STOCK . '<br><br>'; } else { echo '<p><font class="productprice">' . TEXT_PRODUCTS_PRICE . ' ' . stripslashes($products_price) . '</font></p>'; } //echo tep_draw_hidden_field('products_id', $product_info['products_id']) . tep_image_submit('button_in_cart.gif', IMAGE_BUTTON_IN_CART); ?> </TD> Quote Link to comment Share on other sites More sharing options...
Fourbit Posted March 13, 2005 Share Posted March 13, 2005 Jay Jay, Thanks. That saved me a little time. That was kind of what I was looking for. Here's what I ended up with. // ADDITIONAL CODE FOR INDIVSHIP $products_shipping_query = tep_db_query("select products_ship_price from " . TABLE_PRODUCTS_SHIPPING . " where products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "'"); $products_shipping = tep_db_fetch_array($products_shipping_query); $products_shipping_price = $products_shipping['products_ship_price']; if ( $products_shipping_price == 0 ) { $products_ship = TEXT_SHIP_NO_PRICE . TEXT_SHIP_NONUS; }else{ $products_ship = TEXT_SHIP_PRICE . $products_shipping_price . TEXT_SHIP_NONUS; } echo $products_ship; // END ADDITIONAL CODE FOR INDIVSHIP With some new defines in the /languages/english/product_info.php file for the TEXT_SHIP_NO_PRICE, TEXT_SHIP_PRICE, and TEXT_SHIP_NONUS . ;) Quote Link to comment Share on other sites More sharing options...
oldworldcharms Posted March 13, 2005 Share Posted March 13, 2005 Thanks Jay Jay and Fourbit :D Quote Link to comment Share on other sites More sharing options...
oldworldcharms Posted March 13, 2005 Share Posted March 13, 2005 DEFINE('TEXT_SHIP_NO_PRICE','Shipping inside US: $12.00<br>Shipping outside US: Quoted at time of purchase <br>'); DEFINE('TEXT_SHIP_PRICE','Shipping inside US: $'); DEFINE('TEXT_SHIP_NONUS','<br>Shipping outside US: Quoted at time of purchase <br>'); Quote Link to comment Share on other sites More sharing options...
crashwave Posted March 13, 2005 Share Posted March 13, 2005 Glad you guys got it working. Sorry I couldn't help. Sick today. Went to take an hour nap at 4:30 got up 7 hours later. Quote q_|_|| _|9~~J >-o>-o q_|_|| )| q_|| ) Link to comment Share on other sites More sharing options...
oldworldcharms Posted March 13, 2005 Share Posted March 13, 2005 Can someone give a better explantion of this Zip Code notnull Indv. Shipping Price: notnull Each Additional Price: notnull Why would you want the zip code? What is the Each Additional Price used? Can someone give an example? thanks Elizabeth Quote Link to comment Share on other sites More sharing options...
crashwave Posted March 13, 2005 Share Posted March 13, 2005 (edited) Can someone give a better explantion of thisZip Code? notnull Indv. Shipping Price:? notnull Each Additional Price:? notnull <{POST_SNAPBACK}> The null and not null part was for me really to test the values of the database so I can write the code correctly. That can be removed. The zip code really does nothing with individual shipping other than let you know where it will be shipped from. Hopefully it will work with the Multishipping contribution that is in the works. It came with the original contribution and I think it is used by other contributions too. For now it is just there. The additional shipping is if customer buys more than one of the product. 1st item shipped at indv price second and so on shipped at additional price. Edited March 13, 2005 by crashwave Quote q_|_|| _|9~~J >-o>-o q_|_|| )| q_|| ) Link to comment Share on other sites More sharing options...
jay jay Posted March 13, 2005 Share Posted March 13, 2005 Would anyone know how to add each product id with products_ship_price = 0 or some number to the products_shipping table in mysql? Quote Link to comment Share on other sites More sharing options...
jay jay Posted March 14, 2005 Share Posted March 14, 2005 nevermind, figured it out ;) Quote Link to comment Share on other sites More sharing options...
jay jay Posted March 16, 2005 Share Posted March 16, 2005 Anyone know of a way to have a pop-up widow or just show the items being purchased with the idividual shipping prices for each on the checkout_shipping page? Quote Link to comment Share on other sites More sharing options...
Extremest Posted March 17, 2005 Share Posted March 17, 2005 I have everything working but it is not adding the additional shipping charge. Has anyone else had this problem? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.