close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Auspost Regular and Express

Thread began 1/03/2011 5:15 pm by jarrad407561 | Last modified 1/19/2011 3:18 pm by Jason Byrnes | 3792 views | 16 replies |

jarrad407561

Auspost Regular and Express

I currently have my cart setup to calculate Australia Post Regular, is there a way I can make an option to choose Australia Post Express as well?

test.costumesandpartystuff.com.au

Sign in to reply to this post

Jason ByrnesWebAssist

you would need to add a select list on the checkout page with the service type options:

<select name="AusPost_ServiceType" id="AusPostService">
<option value="STANDARD">Standard</option>
<option value="EXPRESS">Express</option>
</select>



and add a hidden form element on the confirm page to capture the selection:

<input name="AusPost_ServiceType" type="hidden" id="AusPost_ServiceType" value="<?php echo((isset($_POST["AusPost_ServiceType"]))?$_POST["AusPost_ServiceType"]:"") ?>">




then on the confirm page, go to the server behaviors panel and click the plus button. Select eCart -> General -> Set Session Value.

set the trigger to any form post.

set the name to AusPost_ServiceType

for the value, click the lightning bolt and select the AusPost_ServiceType element from the form collection.

Now edit the Autralia post lookup server behavior, click the lightning bolt next to service type and select the AusPost_ServiceType session variable.

Sign in to reply to this post

jarrad407561

Thanks Jason, that's done it :)

Sign in to reply to this post

Jason ByrnesWebAssist

you're welcome, glad to hear it is working.

Sign in to reply to this post

jarrad407561

Just another question on the same page..
I have a PayPal Express option at the top of the check out page, now if you take the paypal option, it skips the whole postage calculation step, so the customer is charged without the addition of postage & handling..

How can I get around this?

Sign in to reply to this post

Jason ByrnesWebAssist

you would need to add the Australia post shipping lookup behavior to the pp_confirm.php page.

when the user selects to use paypal express, they go to the paypal site and set the payment method, then paypal directs them back to your site at the pp_confirm page. you can calculate shipping on this page.

Sign in to reply to this post

jarrad407561

OK, looks like it is already setup this way..
Perhaps I should move the standard/express option back to the shopping cart..
I'll give it a try..

The test I just did timed out on return from paypal, loading pp_confirm.php it just timed out..
Hopefully it's a domain thing, as it is setup to redirect back to the live domain, it should work once it goes live... i hope..

Sign in to reply to this post

jarrad407561

I moved the standard/express option back to the cart instead.. everything was running smoothly so I've gone live with it..

Now on the live site, the shipping quote fails every time (when it didn't before)..
I have it setup to return a default value of $12 shipping on failure of a quote, so it's not a huge problem, but i do still need to get it working..

Why would it be working before and not now?

Sign in to reply to this post

Jason ByrnesWebAssist

we would need to see the full request and full response being sent to Australia post.


add the following code to your page to return the full request and full response from Australia post, this should help identify why it is failing:

php:
<?php if(!session_id()) session_start(); ?>

Full Requesst: <?php echo $_SESSION["eCart4_AusPost_FullRequest"]; ?><br />
Full Response: <?php echo $_SESSION["eCart4_AusPost_FullResponse"]; ?><br />




NOTE: you will need to change "eCart4" to the name of your eCart object.

Sign in to reply to this post

jarrad407561

It appears to be working now.
It seems customers so far haven't had any problems with it, except international (which i have set to default to a set amount)..

I think it had something to do with that fact my cart contents were stored in a cookie from a previous day.
I cleared my cookies, then tried again with the code that you posted, and it calculated the postage fine.
It didn't give anything for full request and response.. I put that code on the pp_confirm.php page.. (edit... my bad, i had the eCart object name wrong)

I just ran through an order for an international address and here is the response.

Full Requesst: Pickup_Postcode=5046&Destination_Postcode=90211&Country=US&Service_Type=STANDARD&Weight=45&Length=100&Width=100&Height=100&Quantity=1.0
Full Response: charge=0 days=0 err_msg=Standard Postage Rates not available for areas outside Australia

Sign in to reply to this post
loading

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...