Build a Palindrome Checker - 4th criterea Please input a value

Hi guys,
My Palindrome checker is working perfectly, except for missing the 4th criterion, where a message is supposed to appear saying “Please input a value”, when no value is entered.

I’m able to get a message to appear saying “Please fill out this field”. However, I have no idea how to change this text. I got that message to show by nesting the button in a form and making it required.

Please help me learn how to change the text of this message. Thanks!

You don’t need to add a form here. Read the user stories about where the text has to appear.

The user stories make no mention of where the text appears. This is the only user story that makes mention of the alert:
When you click on the #check-btn element without entering a value into the #text-input element, an alert should appear with the text "Please input a value"

When you click on the #check-btn element without entering a value into the #text-input element, an alert should appear with the text "Please input a value"

The keyword in this user story is ‘alert’.
You should use the alert() method:

Thanks a lot! That solved it for me.

1 Like