What's wrong with this code?

The headings have the same IDsThere are two headings"title" is not a good value for an idThe script tags are in the wrong position

The headings have the same IDs. If they don't have unique IDs, getElementById() won't work.