--- id: 5ef9b03c81a63668521804d8 title: Step 36 challengeType: 0 dashedName: step-36 --- # --description-- The `input` element allows you several ways to collect data from a web form. Like `img` elements, `input` elements are self-closing and do not need closing tags. Nest an `input` element in the `form` element. # --hints-- Your `form` element should have an opening tag and closing tag in the correct order. You may be missing one or both of the required tags, or have them in the wrong order. ```js const noSpaces = code.replace(/\s/g, ''); assert( document.querySelector('form') && code.match(/<\/form>/g) && noSpaces.indexOf('') ); ``` Your `form` element's opening tag should only have an `action` attribute. Remove anything else you may have typed in it. ```js assert([...document.querySelector('form').attributes].length < 2); ``` You should create an input element. Check the syntax. ```js assert(document.querySelector('input')); ``` Your `input` element should have an opening tag, but not a closing tag. ```js assert(document.querySelector('input') && !code.match(/<\/input\>/g)); ``` Your `input` element should be nested within the `form` element. ```js assert(document.querySelector('form > input')); ``` Your `form` should only contain the `input` element. Remove any HTML elements or text between the `form` element's tags. ```js assert( $('form')[0].children.length === 1 && $('form')[0].innerText.trim().length === 0 ); ``` # --seed-- ## --seed-contents-- ```html

CatPhotoApp

Cat Photos

Click here to view more cat photos.

A cute orange cat lying on its back.

Cat Lists

Things cats love:

  • cat nip
  • laser pointers
  • lasagna
A slice of lasagna on a plate.
Cats love lasagna.

Top 3 things cats hate:

  1. flea treatment
  2. thunder
  3. other cats
Five cats looking around a field.
Cats hate other cats.

Cat Form

--fcc-editable-region--
--fcc-editable-region--
```