Libraries commonly use jQuery to reword the labels on various fields in the patron record (like changing "Surname" to "Last name"). Those field labels lack distinct IDs, which makes targeting them with jQuery more complicated and fragile: $('.label:contains("Surname")').text('Last name:'); $('label[for="surname"]').text("Last name:"); If that label had an ID like "#surname_label" it would simplify things.
Created attachment 191519 [details] [review] Bug 41638: Add IDs to labels on patron edit When targeting with jquery and css, labels on the patron edit screen can be fragile and complicated. This patch adds ids to all the labels that follow the following convention: <label for="surname" class="required" id="surname_label"> Each id is the "for" with _label appended. To Test: 1. Before applying the patch, go to add a new patron 2. Right click on the page and use the browser inspector/inspect element. 3. Observe there are no ids for the field labels. 4. Apply patch 5. Reload the page 6. Observe there are now ids for the fields. 7. Go through all the fields and confirm there is an id and that they follow the convention above. 8. Change mandatory fields and confirm the labels are still correct. 9. Edit an existing patron and confirm the ids are still present. 10. Sign off!