Was wondering if anyone had a JS solution to reorder address labels to be ABOVE the input field, rather than BELOW, as shown in the below example.
Having the labels below causes some confusion for my users. Cheers!
Was wondering if anyone had a JS solution to reorder address labels to be ABOVE the input field, rather than BELOW, as shown in the below example.
Having the labels below causes some confusion for my users. Cheers!
Ah, sorry. I've never worked with address fields. Here's the code to accomplish what you want (replacing FIELDID with the ID of your address field):
$.each($('#kn-input-field_FIELDID label.help'), function () {
$(this).parent().prepend($(this).detach());
});
Sorry, not sure how to apply this to an Address field, which contains multiple addresses. The address fields have label.help elements below them rather than p.kn-instructions.
Try this (changing FIELD_SELECTOR to 'kn-input-field_FIELDKEY'):
var $YOURFIELD = $('FIELD_SELECTOR')
$YOURFIELD.find('> p.kn-instructions).detatch().appendTo($(YOURFIELD).find('> label'))
If all these fields are in their own view, you can change FIELD_SELECTOR to '#view_VIEWKEY div.kn-input'. Otherwise, repeat the above code for every one of your fields.