Completing my first project and now I'm getting 'href' error

Hey guys,
After getting some advise from some campers here to re-start my programming journey through the web-development route prior to the ‘python’ route I took initially(i had already done two projects out of 5), I’ve finally done the first project on “responsive web design-survey form project”

Everything works perfectly but when i click ‘submit’, i get this error


Someone should pls tell me where i got it wrong
Here’s the link to my code:

Hey there,

This is standard behaviour on CodePen . There’s nothing wrong with your code.

When an HTML form is submitted, the default behaviour is to refresh the page. CodePen’s previewer uses an iFrame, and for security purposes they block any “url changes”. Your project passes all of the tests and you are good to submit it if you are ready.

thanks @nhcarrigan
I thought it was a problem from my side

1 Like

could you use form onsubmit=“return false;” in this specific case to make it work?

You can! That will prevent the page refresh, but also means the form doesn’t clear when you “submit”.