Custom HTML/JS code to put into hosting web page
Embed the Calculator Button
Please add the following excerpts of code to your website HTML to embed the calculator into your website. After adding the code to your page, click on the button labeled “Calculate” to use the calculator. To close it, click on the button labeled “Close”.
-
<input type="button" id="calculateBtn" value="Calculate"/>
-
<input type="button" id="calculateBtn" value="Calculate"/>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.0/jquery.min.js"></script>
<script
src="https://calculator.measuresquare.com/scripts/jquery-m2CountertopCalculatorV3.js"></script
>
<script>
$(function () {
$('#calculateBtn').m2Calculator({
cancel: function () {
},
callback: function (data) {
console.log("Callback function called!");
}
});
});
</script>