On page load I want the base price to be shown, the KitFormOptions to be hidden and the customised price to be hidden. This works well with my current code.
However when the user clicks the button it still shows the base price. I need it to hide the base price, display the KitFormOptions and display the customised price.
I have the following HTML code:
<div class="body"> this is the outside <div class="customise-show-hide-wrapper"><b>Click to customise:</b><input type="button" id="customise-showhide-button" name="customise-showhide-button" class="customise-showhide-button"></div> <div id="KitFormOptions"> this is the form <br /> </div> <div class="KitPriceBox"> <div class="testing"> <span class="kitprice1"> Base Price: £20<br /> <br /> </span> <div class="kitprice2"> Customised Price: £40 <br /> (should display when button is clicked) </div>
I have a problem, I have been working on some jquery to set the quantity text box to display 25 or more. It checks if the wording personalisation has an empty string, if it doesnt them apply the 25 quantity as its obviously a kit product and personalised.
The crucial part for kit products is:
if (parseInt($("#kitProduct #Quantity").val()) < 25) {
$("#kitProduct #Quantity").attr("value", "25");
It knows its a kit product because i have a div.id wrapped around the page called Kit Product.
My problem is that i need to override this kit product code for certain products. I thought the best way to do this as aquick fix would be to check for the contents of a div, eg: