<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="FeedCreator 1.8" -->
<?xml-stylesheet href="https://wiki.foxycart.com/lib/exe/css.php?s=feed" type="text/css"?>
<rss version="2.0">
    <channel xmlns:g="http://base.google.com/ns/1.0">
        <title>Foxy Wiki - snippets:checkout</title>
        <description></description>
        <link>https://wiki.foxycart.com/</link>
        <lastBuildDate>Mon, 06 Jul 2026 18:22:33 +0000</lastBuildDate>
        <generator>FeedCreator 1.8</generator>
        <image>
            <url>https://wiki.foxycart.com/_media/wiki/dokuwiki.svg</url>
            <title>Foxy Wiki</title>
            <link>https://wiki.foxycart.com/</link>
        </image>
        <item>
            <title>adding_a_consent_to_data_transfer_checkbox</title>
            <link>https://wiki.foxycart.com/snippets/checkout/adding_a_consent_to_data_transfer_checkbox?rev=1493190150&amp;do=diff</link>
            <description>Adding a Consent to Data Transfer Checkbox in the Checkout

This snippet was made in relation to the post about the workaround for the removal of Safe Harbor. This would require customers to check the consent to allow a secure data transfer, and serves as a workaround until a new agreement to replace Safe Harbor is in place. You can read more information about it here:</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Wed, 26 Apr 2017 07:02:30 +0000</pubDate>
        </item>
        <item>
            <title>adding_a_coupon_code_field</title>
            <link>https://wiki.foxycart.com/snippets/checkout/adding_a_coupon_code_field?rev=1493190150&amp;do=diff</link>
            <description>Adding a coupon code field to the checkout

Its has been whipped up for a user who wasn't doing shipping or tax, so that's VERY IMPORTANT TO NOTE. This code is being used by one store but for all intents and purposes consider it UNTESTED, so make sure you test it thoroughly, as it might not work with your specific settings.</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Wed, 26 Apr 2017 07:02:30 +0000</pubDate>
        </item>
        <item>
            <title>adding_an_email_confirmation_box</title>
            <link>https://wiki.foxycart.com/snippets/checkout/adding_an_email_confirmation_box?rev=1493190150&amp;do=diff</link>
            <description>Adding an email confirmation box

TEXT WILL GO HERE...

Related Forum Discussions

	*  &lt;http://forum.foxycart.com/comments.php?DiscussionID=1668&gt;</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Wed, 26 Apr 2017 07:02:30 +0000</pubDate>
        </item>
        <item>
            <title>adding_email_confirmation_field_to_the_checkout</title>
            <link>https://wiki.foxycart.com/snippets/checkout/adding_email_confirmation_field_to_the_checkout?rev=1493190150&amp;do=diff</link>
            <description>Adding an email confirmation field to the checkout

See the code below:

&lt;script type=&quot;text/javascript&quot; charset=&quot;utf-8&quot;&gt;
jQuery(document).ready(function() {
  var verifyEmail = '&lt;li id=&quot;li_customer_email_verify&quot; class=&quot;fc_row fc_customer_email_verify&quot;&gt;';
  verifyEmail += '&lt;label class=&quot;fc_label_left&quot; for=&quot;customer_email_verify&quot;&gt;Retype Email&lt;span class=&quot;fc_ast&quot;&gt;*&lt;/span&gt;&lt;/label&gt;';
  verifyEmail += '&lt;input type=&quot;text&quot; value=&quot;&quot; autocomplete=&quot;off&quot; class=&quot;fc_text fc_text_long fc_required&quot; id=&quot;customer…</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Wed, 26 Apr 2017 07:02:30 +0000</pubDate>
        </item>
        <item>
            <title>adding_gift_wrapping_checkbox</title>
            <link>https://wiki.foxycart.com/snippets/checkout/adding_gift_wrapping_checkbox?rev=1493190150&amp;do=diff</link>
            <description>Adding a gift-wrapping checkbox to the checkout

Navigate to your store's FoxyCart administration, and load the “checkout” template page.

Within the template, look for the line containing ^^checkout^^, and paste the following right below it:


^^custom_begin^^
&lt;fieldset id=&quot;fc_custom_fields&quot;&gt;
	&lt;legend&gt;Additional Information&lt;/legend&gt;
	&lt;div class=&quot;fc_inner&quot;&gt;
		&lt;ol&gt;
			&lt;li class=&quot;fc_row&quot;&gt;
				&lt;input type=&quot;checkbox&quot; name=&quot;gift_wrap&quot; id=&quot;gift_wrap&quot; value=&quot;yes&quot; class=&quot;fc_checkbox&quot; checked=&quot;checked&quot; /…</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Wed, 26 Apr 2017 07:02:30 +0000</pubDate>
        </item>
        <item>
            <title>age-validation-for-alcohol-purchase</title>
            <link>https://wiki.foxycart.com/snippets/checkout/age-validation-for-alcohol-purchase?rev=1493190150&amp;do=diff</link>
            <description>Age Validation For Alcohol Purchase

This snippet will force the user to enter their birthday and confirms that they are 21 years old prior to checkout.

Code

Put this code in your checkout template. Version 1.0 required.

^^custom_begin^^

&lt;h2&gt;Additional Information&lt;/h2&gt;
 
&lt;fieldset id=&quot;fc_custom_fields&quot;&gt;
	&lt;div class=&quot;fc_inner&quot;&gt;
		&lt;div&gt;
			&lt;h4&gt;Date of Birth&lt;/h4&gt;
			&lt;select name=&quot;h:Month&quot; id=&quot;birthmonth&quot;&gt;
				&lt;option value=&quot;&quot;&gt;-- Month --&lt;/option&gt;
				{% for i in 1..12 %}
					{% set temp_date =…</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Wed, 26 Apr 2017 07:02:30 +0000</pubDate>
        </item>
        <item>
            <title>displaying_po_payment_option</title>
            <link>https://wiki.foxycart.com/snippets/checkout/displaying_po_payment_option?rev=1493190150&amp;do=diff</link>
            <description>Displaying PO payment option

Displaying PO payment option if certain criteria is met, using the shipping_phone field to fake a custom field for the customer.

FoxEE Setup:

	* You must force the user to login on the EE side before you checkout. You can accomplish this by using the custom add to cart foxEE tag and using a hidden input redirect to redirect the user to a EE custom login/checkout page. Make sure to turn FoxyBox Off. You can turn it on later once you force the user to login and/or i…</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Wed, 26 Apr 2017 07:02:30 +0000</pubDate>
        </item>
        <item>
            <title>hiding_po_payment_option</title>
            <link>https://wiki.foxycart.com/snippets/checkout/hiding_po_payment_option?rev=1493190150&amp;do=diff</link>
            <description>Hiding the Purchase Order payment option

This snippet is really useful for situations where you want to gather customer orders and billing/shipping information but not actually capture any payment at all - like if you contact the customer over the phone to request credit card details to process them manually in a physical store.</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Wed, 26 Apr 2017 07:02:30 +0000</pubDate>
        </item>
        <item>
            <title>making_checkout_fields_required</title>
            <link>https://wiki.foxycart.com/snippets/checkout/making_checkout_fields_required?rev=1493190150&amp;do=diff</link>
            <description>Making checkout fields required

Sometimes as part of the checkout you need to ensure that customers are providing their phone number or company names. To do that, simply paste the following relevant script right before the closing &lt;/head&gt; tag of your</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Wed, 26 Apr 2017 07:02:30 +0000</pubDate>
        </item>
        <item>
            <title>making_shipping_address_fields_mirror_billing_fields</title>
            <link>https://wiki.foxycart.com/snippets/checkout/making_shipping_address_fields_mirror_billing_fields?rev=1493190150&amp;do=diff</link>
            <description>Making shipping address fields mirror billing fields

Making shipping address fields mirror billing fields if the “Use billing address for shipping address” checkbox is checked.


&lt;script type=&quot;text/javascript&quot;&gt;
jQuery(document).ready(function($) {
$(&quot;#fc_form_checkout input&quot;).blur(function() {
if (!$(&quot;#use_different_addresses&quot;).is(&quot;:checked&quot;)) {
var names = [&quot;first_name&quot;,&quot;last_name&quot;,&quot;company&quot;,&quot;address1&quot;,&quot;address2&quot;,&quot;city&quot;,&quot;state_name&quot;,&quot;postal_code&quot;,&quot;phone&quot;];
for (var i in names) {
$(&quot;#shipping_&quot;…</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Wed, 26 Apr 2017 07:02:30 +0000</pubDate>
        </item>
        <item>
            <title>making_shipping_and_payment_fields_hidden</title>
            <link>https://wiki.foxycart.com/snippets/checkout/making_shipping_and_payment_fields_hidden?rev=1493190150&amp;do=diff</link>
            <description>Making the the shipping and payment fields hidden until a valid selection is made for guest/login step of checkout

Making the the shipping and payment fields hidden until a valid selection is made for guest/login step of checkout, adding the functionality that was present pre 050.</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Wed, 26 Apr 2017 07:02:30 +0000</pubDate>
        </item>
        <item>
            <title>override-sales-tax-during-checkout</title>
            <link>https://wiki.foxycart.com/snippets/checkout/override-sales-tax-during-checkout?rev=1493190150&amp;do=diff</link>
            <description>Overriding product category during checkout via SSO Endpoint in Foxy-Shop

This code will help you change product categories on the fly for specific users during checkout.  I had a use-case where a specific class of user wasn't supposed to be charged state sales tax.  To accomplish this, I had to remove all of the products from the cart, changed the category of each product, then re-add the product to the cart.  This is done at the SSO endpoint.  I was using WordPress and Foxy-Shop, so had a nic…</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Wed, 26 Apr 2017 07:02:30 +0000</pubDate>
        </item>
        <item>
            <title>performing_actions_when_customer_logged_in_on_checkout</title>
            <link>https://wiki.foxycart.com/snippets/checkout/performing_actions_when_customer_logged_in_on_checkout?rev=1493190150&amp;do=diff</link>
            <description>Performing actions when customer has logged in on the checkout

Sometimes you need to perform actions only for returning users who have logged into your checkout, such as displaying a 'welcome back' message or displaying special options or pricing for valued customers. This code lets you run logic only when they successfully log in.</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Wed, 26 Apr 2017 07:02:30 +0000</pubDate>
        </item>
        <item>
            <title>pre_populating_checkout_values</title>
            <link>https://wiki.foxycart.com/snippets/checkout/pre_populating_checkout_values?rev=1727969002&amp;do=diff</link>
            <description>Pre-populating checkout values

Pre-populating checkout values, without invoking “single-use customers”  .


&lt;script type='text/javascript'&gt;
//&lt;![CDATA[
jQuery(function($){
if(fc_json.custom_fields.customer_email){
$('#customer_email').val(fc_json.custom_fields.customer_email);
FC.checkout.checkLogin();
}
});
//]]&gt;
&lt;/script&gt;</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Thu, 03 Oct 2024 15:23:22 +0000</pubDate>
        </item>
        <item>
            <title>smarty-streets-address-validation</title>
            <link>https://wiki.foxycart.com/snippets/checkout/smarty-streets-address-validation?rev=1493190150&amp;do=diff</link>
            <description>SmartyStreets Address Validation

Installing this code in your checkout template will enable SmartyStreets address validation for your billing and shipping addresses. It isn't currently working for multi-ship but it wouldn't be too hard to hack that support in.</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Wed, 26 Apr 2017 07:02:30 +0000</pubDate>
        </item>
    </channel>
</rss>
