Closed (fixed)
Project:
Canada Post Shipping Quotes
Version:
6.x-1.x-dev
Component:
Miscellaneous
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
31 Aug 2009 at 16:48 UTC
Updated:
22 Nov 2009 at 02:25 UTC
I'm not quite sure what i'm doing wrong here, but i cannot get the Canada Post Shipping module to calculate shipping, all i ever get when i hit the "calculate shipping" button is "You must select a shipping option before continuing."
I uncommented these two lines in my code:
//drupal_set_message('<pre>'. check_plain(var_export($xml, TRUE)) .'</pre>');
//drupal_set_message('<pre>'. check_plain(var_export($response, TRUE)) .'</pre>');And got the following output. could you help me decipher where my problem is? thanks!
<li><pre>'<?xml version="1.0" ?><eparcel><language>en</language><ratesAndServicesRequest><merchantCPCID>CPC_GLITCH_HOP_FORUM</merchantCPCID><turnAroundTime>24</turnAroundTime><itemsPrice>20</itemsPrice><lineItems><item><quantity>1</quantity><weight>1</weight><length>1</length><width>1</width><height>1</height><description>1 items</description><readyToShip /></item></lineItems><city>woodbridge</city><provOrState>ON</provOrState><country>CA</country><postalCode>L4L1A7</postalCode></ratesAndServicesRequest></eparcel>'</pre></li>
<li><pre>false</pre></li>
PHP 5.2.9
Drupal 6.13
Modules:
Ubercart 6.x-2.0-rc6
Canada Post Shipping Quotes for Ubercart 6.x-1.x-dev (2009-Aug-26)
Ubercart Views 6.x-2.0
Theme: Vigilianty 6.x-1.1
Comments
Comment #1
deweydb commentedSorry about the messy XML dump, i've cleaned it up a bit here:
This alone leads me to believe something is off, the weight is set at 180 grams in the ubercart product definition. Are grams not compatible with uc_canadapost?
Comment #2
tr commentedYour weight question is addressed at http://drupal.org/node/570318
The XML being sent to the Canada Post server looks correct. However, the parsed result returned from the server is "false", indicating an HTTP error or a network error. No way to tell without sticking in some debug print statements and seeing what is happening. My guess is that it's something like your server blocking port 30000, causing the POST to fail, or that the CP server was just off-line when you did your testing. There's a possibility that some debug information is in your logs at admin/reports/dblog.
Comment #3
deweydb commentedThanks TR. I've made some progress with this, i called my hosting and got them to open port 30000 and now i can get quotes when ever i finish entering the mailing address info and click outside the box. But the moment i actually hit the "calculate shipping" button the page refreshes and i get an error "you must select a shipping option before continuing". In fact if i have any of the "next" buttons enabled during checkout the page always refreshes. I guess that this is more of an ubercart bug, but if you have any ideas i would appreciate it.
Also thanks for clearing up the weight issue.
Comment #4
tr commentedSearch the Ubercart forums for that error - lot's of possible causes not related to this or any other shipping module. The most common one is having a JavaScript error on the checkout page.
Comment #5
tr commentedComment #6
tr commentedNo activity in two months, so I'm going to assume it's solve. Re-open if you continue to have the problem and can provide more information.