This is an accordion made on the woocommerce checkout page and I want to pass the value of these checkboxes to woocommerce orders. Is it possible to do it this way or any simple way. ?
add_action('woocommerce_before_checkout_form' ,'screening_checkout_clinic');
function screening_checkout_clinic(){
?>
<div class="checkout-clinic-select"><?php echo "<h2>Select a preffered clinic</h2>"; ?>
<button class="custom-accordion-screening-clinic">Kuala Lumpur</button>
<div class="panel">
<div class="custom-accordion-inner">
<input name="accordion1" id="accordion1" type="checkbox" value="Polyclinic & Surgery Khor"></input>
<label for="accordion1">Polyclinic & Surgery Khor</label>
</div>
<div class="custom-accordion-inner">
<input name="accordion2" id="accordion2" type="checkbox" value="Poliklinik & Surgeri Siva"></input>
<label for="accordion2">Poliklinik & Surgeri Siva</label>
</div>
<div class="custom-accordion-inner">
<input name="accordion3" id="accordion3" type="checkbox" value="Clinic Q City & Surgery"></input>
<label for="accordion3">Clinic Q City & Surgery</label>
</div>
<div class="custom-accordion-inner">
<input name="accordion4" id="accordion4" type="checkbox" value="HS Mediclinic & Surgery"></input>
<label for="accordion4">HS Mediclinic & Surgery</label>
</div>
</div>
<?php
}
?>