Yahoo Answers is shutting down on May 4th, 2021 (Eastern Time) and beginning April 20th, 2021 (Eastern Time) the Yahoo Answers website will be in read-only mode. There will be no changes to other Yahoo properties or services, or your Yahoo account. You can find more information about the Yahoo Answers shutdown and how to download your data on this help page.
Trending News
Need a small HTML code...?
Hi,
I need a HTML code. right code will get 10 points.
I want to create a HTML page on which there is a button.
On clicking that button, A message appears below the button.
If we click the button again, the message comes once again below it and if further clicked, it apears again and again below it.
Just give the code for upper purpose,
Left all editing i will do...
4 Answers
- 1 decade agoFavorite Answer
A single action on a button is like this :
<button>Button Name</button>
Using only HTML you can only define with "name", "type", "value", and "disabled".
An HTML Button's standard attributes are id, class, title, style, dir, lang, xml:lang, accesskey and tabindex.
Yet what you are looking for is an event attribute.
Event attributes are onfocus, onblur, onclick, ondblclick, onmousedown, onmouseup, onmouseover, onmousemove, onmouseout, onkeypress, onkeydown and onkeyup.
What you are going to use is onclick and it needs a javascript.
The code would be like this :
<button onclick:"thejavascripthere">Button Name</button>
Yet you have to write the script for it; try a site who has already done it. Look at its source code, then find the script url, then download and use it with your code.
- Anonymous1 decade ago
You need java script...you can probably find a script at javascriptkit.com with that.
- Anonymous1 decade ago
You can't just do it with HTML.
You will need some Javascript, and some CSS will help.