Skip to content

Tag: html

Show last 5 submitted data using only JS and HTML

I have a small question, I am yet a beginner with Java Script and I don’t have that much of knowledge with it. My question is: I need to create a fake donation form. The form contains fields where the user can write his data like his phone number, donate amount etc… and when the user hit submit hi…

How do I change the function of a button more than 2 times?

I would like to make one button do 3 or more things one after the other. I’m trying to make a CYOA and I need one button to go through multiple layers/phases/sections(Start to layer 1 to layer 2) of the CYOA, with as little repeating code* as possible. I have placeholder text in the areas where the text…

Setting a limit for checkbox in js

I’m trying to make a form that sets a limit for 3 selection max or 1 minimum for my checkbox. I do get the error message once the condition isn’t set but I still can check them. How can I prevent that? and how can I prevent it from submitting the form when it happens? This is my JavaScript code