close ad
Databridge V2 with MySQLi support IS Now Available!
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Adding an expedited shipping option

Thread began 5/10/2012 12:51 pm by Armen | Last modified 7/26/2013 11:30 am by Jason Byrnes | 785 views | 11 replies |

Armen

Adding an expedited shipping option

I am using CS 5.5 eCart 5.0.4 on PHP/MySQL

I want to add an option for expedited shipping on the cart display page. If checked, there will be a $5.00 charge added to the total shipping amount. How do I go about doing this?

Sign in to reply to this post

Jason ByrnesWebAssist

on the checkout page, add the checkbox:

php:
<label for="expedited">Expedited Shipping:</label>

<input name="expedited" type="checkbox" id="expedited" value="1" />



on the confirm page, near the bottom of the page, there is a collection of hidden element, add a new hidden element using the same name as the checkbox on the checkout page:

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



next, add a set session value behavior. on the server behaviors panel, click the plus button and select eCart -> General -> Set Session Value.

for the trigger and value, click the lightning bolt icon and select the "expedited" form element. set the name to "expedited"


in the eCart object, create a new shipping rule.

set the trigger to based on session variable value:
if the session variable "expedited" has a value of "1"

and use a flat rate calculation of 5

Sign in to reply to this post

Armen

The expedited shipping charge appears on the confirm page but not on the checkout success page...

Sign in to reply to this post

Jason ByrnesWebAssist

that means the session is being reset to 0, i'll need a copy of the checkout and confirm page to examine the code.

Sign in to reply to this post

Armen

Thanks. See attachment to thread.

Sign in to reply to this post

Jason ByrnesWebAssist

1) On the confirm page, the expedited form element is not a part of the form. it needs to be moved so it is after the following form tag:
<form name="ecart_checkout_form" action="<?php echo $_SERVER["PHP_SELF"]; ?>" method="post">

right now, it is before.



2) the trigger for the set session value behavior is set to before page load.

for the trigger, you should click the lightning bolt and select the expiated form element.

Sign in to reply to this post

Armen

My friend, you are Amazing! Thanks!

Sign in to reply to this post

info185511

Adding option of express shipping to US only, with three existing options depending on country "shipping country",

Not sure if I should post this to existing or start a fresh post. Client now requests an option of express shipping at $20.00 extra to US addresses only and I am trying to figure out if the above process could be applied in some way.
Presently there is existing an option from a drop down menu of the country in the checkout page which transfers to the confirm page, standard shipping fee based on weight for US, flat fee of $32 for Canada and flat fee of $45 the rest of the world. There are three products which are exempt, having their own additional fees as charges based on product ID since they have to be shipped express due to spoilage issues.
If I need a Premier support ticket please let me know. Thanks in advance

Sign in to reply to this post

Jason ByrnesWebAssist

setting this up is similar to the process mentioned above. add the expedited shipping form element to the checkout page. Add a hidden form element on the confirm page to capture the value from the checkout page and add a set session variable behavior.

since you need more conditions, you will need to set up the shipping rules to use the shipping country session, and the expedited session to determine how they are applied.

we could definitely get this set up for you in a premiere support appointment.

Sign in to reply to this post

info185511

Adding option of express shipping to US only......

Thanks for your quick response had implemented the above code and it worked well, but I could not isolate it to US only My last try was

If the the value of the session variable expedited is = a value of 1
AND Session variable exists : eCartCheckout_shipping_country
AND Based on session variable value
If the the value of the session variable eCartCheckout_shipping_country is = a value of US
Flat Rate $20

without success. At this point I require a Premiere support ticket as I need to isolate this service to US customers only and there are 8 products which presently have their specific special shipping charges and would not be included in the expedited shipping option( a bit more complicated than originally thought). The fees for those 8 products were set up under charges using the product id number to set the fee. In the shopping cart it shows under Handing Charges, separate from Shipping. This leads to my next question, can there be a separate line item for the Expedited Shipping in the shopping cart and order confirmation pages. Thanks in advance and let me know when to apply for a premiere support appointment.

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