Skip to content

Commit ab4859e

Browse files
danezweaverryan
authored andcommitted
Fixed Typo and better example
There is a $ missing in the JS code. I also added two lines from the referenced function, to make clear, that you do not have to add it at the beginning of this function but after the first two lines.
1 parent e2ee504 commit ab4859e

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

cookbook/form/form_collections.rst

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -613,8 +613,11 @@ First, add a "delete this tag" link to each tag form:
613613
.. code-block:: javascript
614614
615615
jQuery(document).ready(function() {
616+
// Get the ul that holds the collection of tags
617+
$collectionHolder = $('ul.tags');
618+
616619
// add a delete link to all of the existing tag form li elements
617-
collectionHolder.find('li').each(function() {
620+
$collectionHolder.find('li').each(function() {
618621
addTagFormDeleteLink($(this));
619622
});
620623

0 commit comments

Comments
 (0)