We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
sheepit/jquery.sheepItPlugin.js
Line 155 in 7318e91
normalizeFieldsForForm() function through an error in case the element (input) had no name or id attributes
normalizeFieldsForForm()
name
id
Below is my suggestion for the fix:
var that = $(this) ,idTemplateAttr = getOrSetTemplate(that,"id") ,nameTemplateAttr = getOrSetTemplate(that, "name") ,idAttr = that.attr("id") ,nameAttr = that.attr("name") /* Normalize field name attributes */ newNameAttr = nameTemplateAttr ? nameTemplateAttr.replace(options.indexFormat, index) : nameAttr; that.attr("name", newNameAttr); /* Normalize field id attributes */ newIdAttr = idTemplateAttr ? idTemplateAttr.replace(options.indexFormat, index) : idAttr; idAttr ? form.find("label[for='"+idAttr+"']").each(function(){ $(this).attr("for", newIdAttr); }) : null; that.attr("id", newIdAttr);
The text was updated successfully, but these errors were encountered:
No branches or pull requests
sheepit/jquery.sheepItPlugin.js
Line 155 in 7318e91
normalizeFieldsForForm()
function through an error in case the element (input) had noname
orid
attributesBelow is my suggestion for the fix:
The text was updated successfully, but these errors were encountered: