Skip to content

Instantly share code, notes, and snippets.

@cargix1
Last active September 23, 2015 10:18
Show Gist options
  • Save cargix1/fde68ee51889c59aedf2 to your computer and use it in GitHub Desktop.
Save cargix1/fde68ee51889c59aedf2 to your computer and use it in GitHub Desktop.
{% if template contains 'cart' %}
<script type="text/javascript">
$(document).ready(function() {
$("[name='checkout']").on("click", function() {
var date = $(".zapietCollectionDate").val();
var locationId = $(".clickCollectLocation").val();
if(locationId != 'none') {
if(date == '') {
alert('Please select a pickup date and time.');
return false;
}
}
});
});
</script>
{% endif %}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment