Select Carrier Patch for StoreFront 6.1
by Structured Solutions

The Select Carrier Patch is a control that you add to the ShipSummary.aspx page. It does two things: First, It pre-selects a carrier and shipping method and calculates the total shipping before the Ship Summary page is displayed. If you only use one carrier and shipping method, this one will be pre-selected. This significantly streamlines the shipping step of the checkout process by eliminating 2 round-trips to the server for each shipping address.

Second, the control allows you (the merchant) to pick a default carrier and shipping method. If you support multiple carriers and shipping methods, but you have one that you prefer, you can choose to pre-select your preference.

Features
Tables of Contents

Installation Instructions

Follow these steps to install the Select Carrier Patch:

  1. Copy SSSelectCarrier.dll from the bin directory where you unzipped the Select Carrier Patch, to the bin directory of your store.
  2. Make a backup copy of ssl/ShipSummary.aspx.
  3. Open ShipSummary.aspx with a text editor and add the following line to the top of the file:
    <%@ Register TagPrefix="sfaddons" Namespace="StructuredSolutions.WebControls" Assembly="SSSelectCarrier" %>
  4. Now find the following tag:
    <form id="Form2" method="post" runat="server">
  5. Add the tag shown in bold:
    <form id="Form2" method="post" runat="server">
    <sfaddons:SelectCarrier id="SelectCarrier1" runat="server"></sfaddons:SelectCarrier>
  6. Save your changes and close the file. The patch takes effect immediately.
Some stores are configured to use a separate bin directory for secure processing pages such as ShipSummary. If your store is configured this way, copy SSSelectCarrier.dll to the secure bin directory.

Back to top

User's Guide

This patch control does not require any interaction from you or the customer. As installed above, the patch will select the first carrier in the list of active carriers returned from the database. Likewise, the first supported shipping method is also selected. There are two optional attributes that you can add to the tag to choose the default carrier and shipping method. These are described in Control Documentation below.

Back to top

Control Documentation

The table below lists the attributes  that can be added to the <sfaddons:SelectCarrier> tag. Multiple properties can be specified just like the are for standard HTML tags like <table>. Moreover, you do not need to recompile your store to see your changes. Just save your change and reload the page in your browser. This makes experimenting very easy.

The <sfaddons:SelectCarrier> tag is used in the ShipSummary.aspx page to pre-select a carrier and shipping method before the page is displayed. This saves quite a bit of time since it eliminates two separate page submits for each shipping address. If the customer has selected a preferred shipping method while using the Shipping Cost Estimator, then that method will be selected by the control and the rates will be pre-calculated before the page is displayed. If the customer has not selected a preferred shipping method, then the defaults shown in the table below will be selected.

Table 1 <sfaddons:SelectCarrier> Tag Attributes
Attribute Description Example
CarrierCode

The code for the carrier you want to be pre-selected when the page is first loaded. The code can be found in the ShippingCarriers table of the store database. The code can be entered in either upper or lower case.

If no code is entered, or an incorrect code, or a code for an inactive carrier is entered, then the default carrier will be pre-selected.

Default: The 1st carrier in the list of active carriers returned from the StoreFront engine.

<sfaddons:SelectCarrier CarrierCode="USPS" ...>
Enabled

A Boolean value (True or False) which enables or disables this control. When Enabled="False", this control will have no effect. This can be useful if you are troubleshooting the ShipSummary page with StoreFront support.

Default: True

<sfaddons:SelectCarrier Enabled="False"  ...>
OnSelectCarrier The name of an event handler to be called right before the carrier is selected. This occurs before shipping costs are calculated. If you select a carrier during this event, it will override the selection calculated by the control.

This event allows you to use your own logic to pre-select a carrier.

Default: No event handler

<sfaddons:SelectCarrier OnSelectCarrier="SelectCarrier1_SelectCarrier" ...>

Note: ShipSummary.aspx.vb must include the event handler code with the following prototype.

Protected Sub SelectCarrier1_SelectCarrier(ByVal sender As Object, ByVal e As DataListItemEventArgs)

' Event handling code goes here

End Sub

OnSelectMethod The name of an event handler to be called right before the shipping method is selected. This occurs after shipping costs are calculated. If you select a shipping method during this event, it will override the selection calculated by the control.

This event allows you to use your own logic to pre-select a shipping method.

Default: No event handler

<sfaddons:SelectCarrier OnSelectMethod="SelectCarrier1_SelectMethod" ...>

Note: ShipSummary.aspx.vb must include the event handler code with the following prototype.

Protected Sub SelectCarrier1_SelectMethod(ByVal sender As Object, ByVal e As DataListItemEventArgs)

' Event handling code goes here

End Sub

ShippingMethod

The name of the shipping method you want to be pre-selected when the page is first loaded. The name can be found in the Shipping table of the store database. The name does not have to match upper and lower case.

If no method is entered, or an incorrect method, or the name of an inactive method is entered, then the default method will be pre-selected.

Default: The 1st method in the list of active and available methods returned from the StoreFront engine. Note that this patch also sorts the methods into ascending order by cost, so the 1st method is also the least expensive.

<sfaddons:SelectCarrier ShippingMethod="USPS Priority Mail" ...>

Back to top

Removal Instructions

To remove the Select Carrier Patch from your store, you will need to restore ShipSummary.aspx. If you made a backup copy of this file prior to installing the patch, then use that in the restore steps below. Otherwise, use the original version from the StoreFront installation directory (typically. "C:\Program Files\StoreFront 6.0\Web\Controls").

  1. Copy the backup or original ShipSummary.aspx file to the ssl directory of your store.
  2. Remove SSSelectCarrier.dll from the bin directory of your store.

Back to top

Support

Direct email support is available from support@sfaddons.com for all licensed users of this add-on. You also may find answers to questions on the StoreFront newsgroup.

Back to top

Copyright © 2003 by Structured Solutions