{"_id":"5632a5ec49e16d0d001224c0","category":{"_id":"5632a5e749e16d0d00122444","pages":["5632a5ec49e16d0d001224bd","5632a5ec49e16d0d001224be","5632a5ec49e16d0d001224bf","5632a5ec49e16d0d001224c0","5632a5ec49e16d0d001224c1","5632a5ec49e16d0d001224c2","5632a5ec49e16d0d001224c3","5632a5ec49e16d0d001224c4","5632a5ec49e16d0d001224c5","5632a5ec49e16d0d001224c6","5632a5ec49e16d0d001224c7","5632a5ec49e16d0d001224c8","5632a5ec49e16d0d001224c9","5632a5ec49e16d0d001224ca","5632a5ec49e16d0d001224cb","5633bab59c607719001b86a1","5633bcbac49a7c19001fd0a6","5633befcc49a7c19001fd0a9","5633c585b904a10d0032f864","5633d7547b56ae0d0025a062","5633d7e87b56ae0d0025a066","5633d85435355017003ca3c8","5633da507e9e880d00af1a28","5633daa3fa71f30d00ba74ab","5633e1f87e9e880d00af1a3f","5633e323fa71f30d00ba74b9","5633e3aa7b56ae0d0025a072","5633e4c6737ea01700ea3276"],"project":"55b933b3146ef121002158d3","version":"5632a5e549e16d0d00122443","__v":14,"sync":{"url":"","isSync":false},"reference":false,"createdAt":"2015-07-31T23:12:47.262Z","from_sync":false,"order":0,"slug":"epayment-form","title":"ePayment Form"},"project":"55b933b3146ef121002158d3","githubsync":"","version":{"_id":"5632a5e549e16d0d00122443","__v":6,"project":"55b933b3146ef121002158d3","createdAt":"2015-10-29T23:04:05.701Z","releaseDate":"2015-10-29T23:04:05.701Z","categories":["5632a5e749e16d0d00122444","5632a5e749e16d0d00122445","5632a5e749e16d0d00122446","5632a5e749e16d0d00122447","5632a5e749e16d0d00122448","5632a5e749e16d0d00122449","5632a5e749e16d0d0012244a","5632a5e749e16d0d0012244b","5632a5e749e16d0d0012244c","5632a5e749e16d0d0012244d","5632a5e749e16d0d0012244e","5632a5e749e16d0d0012244f","5632a5e749e16d0d00122450","5632b179df556c0d00cd095b","564e13053b2b4a19000cd69b","59caa9df65accc001a489c95","59cab50965accc001a489d28","59cadd464ab7b70024378e74"],"is_deprecated":false,"is_hidden":false,"is_beta":false,"is_stable":true,"codename":"","version_clean":"1.1.0","version":"1.1"},"__v":0,"user":"55b932ba8fd1a02b00f496c8","parentDoc":null,"updates":[],"next":{"pages":[],"description":""},"createdAt":"2015-08-03T17:38:05.710Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"results":{"codes":[]},"settings":"","auth":"required","params":[],"url":""},"isReference":false,"order":3,"body":"This code will allow you to add a box to your form that automatically duplicates the Billing information for use in the Shipping fields. This will save your customers some time while filling out the form.\n\n1. Log into your eBizCharge merchant gateway. Go to “Settings”, then “Source Keys”. Select the source key you are using and click “Edit”. Click “Edit Customization to Epay Form”.\n\n2. Click in the text box, then hit Ctrl-F on your keyboard to search the text. Search for “Shipping Information”. It should take you to a portion of code that looks like:\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"<tr>\\n<td bgcolor=\\\"#C4C7D4\\\" width=\\\"692\\\" colspan=\\\"2\\\"><b><font face=\\\"Verdana\\\">Shipping Information:</font></b></td>\\n</tr>\",\n      \"language\": \"html\"\n    }\n  ]\n}\n[/block]\n1. Add the following code to the next line:\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"<tr>\\n<td bgcolor=\\\"#F0F0F0\\\" width=\\\"234\\\" align=\\\"right\\\"><font face=\\\"Verdana\\\" size=\\\"2\\\">Same as Billing:</font></td>\\n<td bgcolor=\\\"#F0F0F0\\\" width=\\\"450\\\">\\n<input type=\\\"checkbox\\\" name=\\\"shipsameasbill\\\" size=\\\"28\\\" value=\\\"yes\\\" onClick=\\\"copyBillingToShipping()\\\"></td>\\n</tr>\",\n      \"language\": \"html\"\n    }\n  ]\n}\n[/block]\n1. Insert a new line and add the following between <script> and </script> tags:\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"<!--\\nfunction copyBillingToShipping()\\n{\\nvar form = document.epayform;\\nif(form.shipsameasbill.checked)\\n{\\nform.UMshipcompany.value=form.UMbillcompany.value;\\nform.UMshipfname.value=form.UMbillfname.value;\\nform.UMshiplname.value=form.UMbilllname.value;\\nform.UMshipcompany.value=form.UMbillcompany.value;\\nform.UMshipstreet.value=form.UMbillstreet.value;\\nform.UMshipstreet2.value=form.UMbillstreet2.value;\\nform.UMshipcity.value=form.UMbillcity.value;\\nform.UMshipstate.value=form.UMbillstate.value;\\nform.UMshipzip.value=form.UMbillzip.value;\\nform.UMshipcountry.value=form.UMbillcountry.value;\\nform.UMshipphone.value=form.UMbillphone.value;\\n}\\n}\\n//-->\",\n      \"language\": \"javascript\"\n    }\n  ]\n}\n[/block]\n1. Save the changes to your form. This will create a checkbox on your payment form that looks like this:\n[block:image]\n{\n  \"images\": [\n    {\n      \"image\": [\n        \"https://files.readme.io/thOOVygUQsO16kPaMMXS_sameasbillbox.gif\",\n        \"sameasbillbox.gif\",\n        \"465\",\n        \"97\",\n        \"#4b8cd3\",\n        \"\"\n      ]\n    }\n  ]\n}\n[/block]\nOnce you have saved changes to your payment form, you will be able to instantly fill out the Shipping fields with Billing information.","excerpt":"","slug":"same-as-billing","type":"basic","title":"Same as Billing"}
This code will allow you to add a box to your form that automatically duplicates the Billing information for use in the Shipping fields. This will save your customers some time while filling out the form. 1. Log into your eBizCharge merchant gateway. Go to “Settings”, then “Source Keys”. Select the source key you are using and click “Edit”. Click “Edit Customization to Epay Form”. 2. Click in the text box, then hit Ctrl-F on your keyboard to search the text. Search for “Shipping Information”. It should take you to a portion of code that looks like: [block:code] { "codes": [ { "code": "<tr>\n<td bgcolor=\"#C4C7D4\" width=\"692\" colspan=\"2\"><b><font face=\"Verdana\">Shipping Information:</font></b></td>\n</tr>", "language": "html" } ] } [/block] 1. Add the following code to the next line: [block:code] { "codes": [ { "code": "<tr>\n<td bgcolor=\"#F0F0F0\" width=\"234\" align=\"right\"><font face=\"Verdana\" size=\"2\">Same as Billing:</font></td>\n<td bgcolor=\"#F0F0F0\" width=\"450\">\n<input type=\"checkbox\" name=\"shipsameasbill\" size=\"28\" value=\"yes\" onClick=\"copyBillingToShipping()\"></td>\n</tr>", "language": "html" } ] } [/block] 1. Insert a new line and add the following between <script> and </script> tags: [block:code] { "codes": [ { "code": "<!--\nfunction copyBillingToShipping()\n{\nvar form = document.epayform;\nif(form.shipsameasbill.checked)\n{\nform.UMshipcompany.value=form.UMbillcompany.value;\nform.UMshipfname.value=form.UMbillfname.value;\nform.UMshiplname.value=form.UMbilllname.value;\nform.UMshipcompany.value=form.UMbillcompany.value;\nform.UMshipstreet.value=form.UMbillstreet.value;\nform.UMshipstreet2.value=form.UMbillstreet2.value;\nform.UMshipcity.value=form.UMbillcity.value;\nform.UMshipstate.value=form.UMbillstate.value;\nform.UMshipzip.value=form.UMbillzip.value;\nform.UMshipcountry.value=form.UMbillcountry.value;\nform.UMshipphone.value=form.UMbillphone.value;\n}\n}\n//-->", "language": "javascript" } ] } [/block] 1. Save the changes to your form. This will create a checkbox on your payment form that looks like this: [block:image] { "images": [ { "image": [ "https://files.readme.io/thOOVygUQsO16kPaMMXS_sameasbillbox.gif", "sameasbillbox.gif", "465", "97", "#4b8cd3", "" ] } ] } [/block] Once you have saved changes to your payment form, you will be able to instantly fill out the Shipping fields with Billing information.