Dynamic dropdown – Populate from text
-
I have 100+ products that all have their own individual dates. Within the short description I have the following links set up:
<div>
<h2>Dates</h2>
<p>24 February – 06 March 2020</p>
<p>22 June – 03 July 2020</p>
<p>19 October – 30 November 2020</p>
</div>These dates differ on every product page, which are uploaded via the product CSV import option.
I have the following JS, which I think will allow the dates to change in the CF7 dropdown field when a date is clicked:
<script type=”text/javascript”>
$ = jQuery.noConflict();=
$(“.booking-date”).on(“click”, function(e) {
$(“.coursedates select”).val($(this).data(“value”));
});</script>
But how do I get the CF7 dropdown form to auto-populate with the dates? And do it so that it works across all products?
The page I need help with: [log in to see the link]
The topic ‘Dynamic dropdown – Populate from text’ is closed to new replies.