Documentation You are here: start » v » 0.6.0 » docs » upgrading » 0.2.5

Upgrading to v0.2.5

Note: These notes are specifically geared towards upgrading from v0.2.4.

Please make sure you review the changelog before upgrading. v0.2.5 included two significant changes that will require changes to your CSS.

New "Remove" Buttons on Cart

Three new spans have been added with the classes:

  • fc_cart_remove_left
  • fc_cart_remove_center
  • fc_cart_remove_right

Our recommendation is to hide the left and right spans by adding this to your CSS:

span.fc_cart_remove_left,
span.fc_cart_remove_right {
	display:none;
}

You can also use our “standard” theme to style the remove link by adding this:

#fc_cart_table .fc_cart_remove_link {
	width:20px;
	height:0px; overflow:hidden;
	padding:16px 0px 0px 0px;
	display:block;
	background:url(https://www.foxycart.com/themes/standard/images/cart_item_remove.png) no-repeat 8px -3px;
}
#fc_cart_table .fc_cart_remove_link:hover {
	background-position:8px -27px;
}

The old cart HTML:

<tr class="fc_cart_item fc_cart_item_last">
	<td>Product Name
		<ul class="fc_cart_item_options">
			<li class="fc_cart_item_option">
				<span class="fc_cart_item_option_name">size</span><span class="fc_cart_item_option_separator">:</span>
				<span class="fc_cart_item_option_value">4 oz tube, dispenser cap</span>
			</li>
			<li class="fc_cart_item_option fc_cart_item_code">
				Code: A20401
			</li>
			<li class="fc_cart_item_option fc_cart_item_weight">
				Weight: 0.3 lbs.
			</li>
		</ul>
		<input type="hidden" name="id1" value="3786" />
	</td>
	<td class="fc_cart_item_quantity">
		<input class="fc_cart_item_quantity" type="text" name="quantity1" value="2" onchange="fc_HideCheckout()" />
	</td>
	<td class="fc_cart_item_price">
		<span class="fc_cart_item_price_total">$19.98</span>
		<span class="fc_cart_item_price_each"> ($9.99 each)</span>
	</td>
</tr>

The new cart HTML:

<tr class="fc_cart_item fc_cart_item_last">
	<td>Product Name
		<ul class="fc_cart_item_options">
			<li class="fc_cart_item_option">
				<span class="fc_cart_item_option_name">size</span><span class="fc_cart_item_option_separator">:</span>
				<span class="fc_cart_item_option_value">4 oz tube, dispenser cap</span>
			</li>
			<li class="fc_cart_item_option fc_cart_item_code">
				Code: A20401
			</li>
			<li class="fc_cart_item_option fc_cart_item_weight">
				Weight: 0.3 lbs.
			</li>
		</ul>
<!-- NEW STUFF START -->
		<span class="fc_cart_remove_left">
			<a href="#" onclick="fc_RemoveItem(1); return false;" class="fc_cart_remove_link" title="Remove this item">[x]</a>
		</span>
<!-- NEW STUFF END -->
		<input type="hidden" name="id1" value="570" />
	</td>
	<td class="fc_cart_item_quantity">
		<input class="fc_cart_item_quantity" type="text" id="quantity1" name="quantity1" value="2" onchange="fc_HideCheckout()" />
<!-- NEW STUFF START -->
		<span class="fc_cart_remove_center">
			<a href="#" onclick="fc_RemoveItem(1); return false;" class="fc_cart_remove_link" title="Remove this item">[x]</a>
		</span>
<!-- NEW STUFF END -->
	</td>
	<td class="fc_cart_item_price">
		<span class="fc_cart_item_price_total">$19.90</span>
		<span class="fc_cart_item_price_each"> ($9.95 each)</span>
<!-- NEW STUFF START -->
		<span class="fc_cart_remove_right">
			<a href="#" onclick="fc_RemoveItem(1); return false;" class="fc_cart_remove_link" title="Remove this item">[x]</a>
		</span>
<!-- NEW STUFF END -->
	</td>
</tr>

New Cart Controls

The “Update” and “Checkout” buttons have been updated, and now appear both above and below the cart table. We recommend taking advantage of this, and modifying your CSS to apply to both the top and bottom set of buttons.

Change/split all your #fc_cart_controls declarations to #fc_cart_controls_top and #fc_cart_controls_bottom. Similarly, change/split all your #fc_cart_update, #fc_cart_checkout and #fc_cart_notice to _top and _bottom suffixes.

Old cart HTML:

<div id="fc_cart_controls">
	<a id="fc_cart_update" class="fc_link_nav" href="#" onclick="fc_UpdateCart();return false;">Update Cart</a>
	<a id="fc_cart_checkout" class="fc_link_nav fc_link_forward" href="/v/0.2.4/checkout.php?ThisAction=customer_info&amp;PHPSESSID=95bfgnjhvov0utqut47lnp6941" target="_top">Check Out</a>
	<span id="fc_cart_notice" style="display:none;">Please update your cart before checkout.</span>
</div>

New cart HTML:

<div id="fc_cart_controls_top">
	<a id="fc_cart_update_top" class="fc_link_nav fc_cart_update" href="#" onclick="fc_UpdateCart();return false;">Update Cart</a>
	<a id="fc_cart_checkout_top" class="fc_link_nav fc_link_forward fc_cart_checkout" href="/v/0.2.5/checkout.php?ThisAction=customer_info&amp;PHPSESSID=gev0v093jets46830llb3qqs91" target="_top">Check Out</a>
	<span id="fc_cart_notice_top" class="fc_cart_notice" style="display:none;">Please update your cart.</span>
</div><!-- #fc_cart_controls_top -->
 
<!-- CART TABLE GOES HERE -->
 
<div id="fc_cart_controls_bottom">
	<a id="fc_cart_update_bottom" class="fc_link_nav fc_cart_update" href="#" onclick="fc_UpdateCart();return false;">Update Cart</a>
	<a id="fc_cart_checkout_bottom" class="fc_link_nav fc_link_forward fc_cart_checkout" href="/v/0.2.5/checkout.php?ThisAction=customer_info&amp;PHPSESSID=gev0v093jets46830llb3qqs91" target="_top">Check Out</a>
	<span id="fc_cart_notice_bottom" class="fc_cart_notice" style="display:none;">Please update your cart.</span>
</div><!-- #fc_cart_controls_bottom -->

Site Tools