function CheckoutPage(){

 // relabel shipping options
 $('label:contains("Continental 48 States")').html('Local Delivery (Dublin, GA or Charleston, SC only)<br><small>Enter your zip code below to see if we deliver to your area.</small>');
 $('label:contains("Table Rate")').html('Flat Rate (<a href="?page_id=31">See Shipping Rates...</a>)');
 $('.shipping_header').parent().remove();
 $('.productcart tr').each(function(i){
  i= i+1;
  $(this).addClass('row-'+i);
  $('.row-'+i+' td').eq(3).remove();
 });
 
 $('#change_country').parent().parent().remove();
 $('.current_country').hide();
 $('td:contains("Please choose a country below to calculate your shipping costs")').parent().hide();
 
 function toggleRate() {
  var flatRate = $('input[id=flatrate_0]');
  var tableRate = $('input[id=tablerate_0]');
  var flatClick = flatRate.attr('onclick');
  var tableClick = tableRate.attr('onclick');
  
  flatRate.attr('disabled','disabled').attr('checked','');
  tableRate.attr('checked','checked');
  switchmethod("Table Rate", "tablerate")
};
 toggleRate();
 
 function changeDeliveryRate() {
  var shipCodeVal = $('input[title=shippingpostcode]').val();
  var isLocalZip = jQuery.inArray(shipCodeVal,localCodes);
  if (isLocalZip > -1) { 
   $('input[id=flatrate_0]').attr('disabled','').attr('checked','checked');
   switchmethod("Continental 48 States", "flatrate");
  } else {
   toggleRate();
  }
 }
 
 // User is logged in with prepopulated fields
 $(document).ready(function(){
    changeDeliveryRate();
 });

 // change shipping info when box is checked 
 $('input[name=shippingSameBilling]').change(function(){
  $('.wpsc_shipping_forms .text').each(function() {
   var shipInput = $(this).attr('title').split('shipping')[1];
   var billInput = $('input[title=billing'+shipInput+']');
   $(this).val(billInput.val());
   if (shipInput == 'postcode') {
    changeDeliveryRate();
   }
  });
 });
 
 // change shipping info automatically after box is checked
 $('input[title*=billing]').change(function(){
  if ($('input[name=shippingSameBilling]').is(':checked')) {
   var billInput = $(this).attr('title').split('billing')[1];
   var shipInput = $('input[title=shipping'+billInput+']');
   shipInput.val($(this).val());
   if (billInput == 'postcode') {
    changeDeliveryRate();
   }
  }
 });
   
 
 
 
 
 // define zip codes for local delivery
 var localCodes = [ '30454','31003','31009','31012','31019','31021','31022','31027','31065','31075','31096','31040','29401','29403','29404','29405','29406','29407','29409','29410','29412','29414','29416','29418','29420','29424','29425','29439','29445','29451','29464','29466','29482','29492','29402','29413','29415','29417','29419','29422','29423','29457','29465','29456','29461','29485','29423','29484' ];
 
 $('input[title=shippingpostcode]').change(function(){
  changeDeliveryRate();
 });

}