Add Authority To Leave to your Shopify cart
You can enable authority to leave in Shopify by following the below steps
StarShipIT can display a Check-box on the Shopping cart page and import the choice of your customer.
1. Modify the Shopping Cart page.
To display a Check-box on your Shopping cart you need to edit the Theme Code of Shopify and copy the custom code from StarShipIT.
If you need assistance to edit the Theme Code please refer to the section "Add a form field to your theme code" of this article.
Once in the editor paste the following code:
<p class="cart-attribute__field">
<input type="hidden" name="attributes[Authority To Leave]" value="No">
<input type="checkbox" name="attributes[Authority To Leave]" value="Yes"{% if cart.attributes["Authority To Leave"] == "Yes" %} checked{% endif %}>
<label>Authority To Leave</label>
</p>
Here is what it should look like when the code has been pasted.
Note: You can modify the Style of the Check-box however the name must be "Authority To Leave" otherwise the information won't be imported into StarShipIT.
2. Result in Shopify
After you have added the check-box Authority To Leave, you should see it in your Shipping cart page and in your order details as described in the two screen-shots below.
3. Result in StarShipIT
After you have added the check-box Authority To Leave and if your customer have selected the Authority to Leave option during the checkout process; The Authority to Leave Option in StarShipIT will be automatically selected.