|
|
#1 |
|
Adding/Removing an Extra Field using Javascript
Hi everyone. I am attempting to do the following:
1. Click a button 2. It adds a element to the page (such as a text box) 3. Then when the user clicks another button, the element is removed, and replaced with another element However, I just don't know where to start on this one. Thanks for any help. |
|
|
|
0
|
|
|
#2 |
|
This is essentially what a tabbed layout does (at least when it stays on one page). That might give you something to work from for searching out code.
[HTML]<div id="buttons"> <input type="button" value="Add" onclick="ShowZone('zone1')" /> <input type="button" value="Change" onclick="ShowZone('zone2')" /> </div> <div id="zones"> <div id="zone1"> <p>Text in zone 1.</p> </div> <div id="zone2"> <p>Text in zone 2.</p> </div> </div>[/HTML] CSS Code:
#zone1, #zone2 {
display: none;
}
PHP Code:
|
|
|
|
0
|
![]() |
|
«
Previous Thread
|
Next Thread
»
| Thread Tools | Search this Thread |
| Display Modes | |
|
|
Similar Threads
|
||||
| thread | Thread Starter | Forum | Replies | Last Post |
| Have you ever added an extra line although you don't need it to get the new iphone?! | Ramio | iPhone | 19 | Oct 11, 2011 01:40 PM |
| Resolved: [Table Views] Adding an extra "new item" row at the end. | CodeBreaker | iPhone/iPad Programming | 2 | Sep 29, 2011 10:45 AM |
| How to remove an extra windows partion from parallels? | draggo | Mac Basics and Help | 0 | May 26, 2011 04:19 PM |
| Use javascript to change <td> background colour based on value in an array | dom.mason | Web Design and Development | 2 | May 5, 2010 04:49 PM |
| Questions about adding an extra HD | masterjedi73 | Mac Basics and Help | 2 | Sep 22, 2005 04:17 PM |
All times are GMT -5. The time now is 10:29 PM.






Linear Mode

