Magento: Customer Comment on order page required field
- by Shamim Ahmed
I am using whiteOrderComment module for customer comment on order review page. but in this section text-area field required option not working.
I did little bit change on /checkout-onepage-review-button.phtml like this
<script type="text/javascript">
function validate(){
if(document.getElementById("whiteOrderComment").value == ""){
alert('Required');
}else{
review.save();
}
</script>
<button type="submit" title="<?php echo $this->__('Place Order') ?>" class="button btn-checkout" onclick="validate();"><span><span><?php echo $this->__('Place Order') ?></span></span></button>
but in this page javascript not working.
can you please give any better idea, how can i make this text-area field required.
thanks