Click the add button and delete button respectively
I want elements and text boxes to be added and removed
// Element to move Element A // Add button <input type = "button" value = "add"> // Delete button <input type = "button" value = "Delete"> <form method = "post" action = ""> <p> <input type = "text" placeholder = "name of icon" name = "icon"> </p> <p> Element A <input type = "text" value = "Please click ☆" name = "zahyou"> </p> // Send <p> <input type = "submit" value = "next" name = "send"> </p>
Answer # 1
First of all,
What kind of UI do you want to process multiple times
How to reflect in form and how to process in form
Please pack etc.
Answer # 2
Add button I want to be able to add and delete "elements I want to move" and "text box" (element A in this case) by pressing the delete button.
I can move only one of them with my knowledge now, so I want to add or delete multiple
The essential problem is the same as the previous question, so please reread all the answers to the previous question.
Problem "If you want to specify an additional position corresponding to an additional button, you can't implement it with my skill unless you prepare as many event handlers as there are buttons."
The solution is to prepare a map or specify a relative position, as in the previous answer.
Preparecorresponding mapof add button and location
Add torelative position(parent/child, brother/brother) corresponding to the add button
Answer # 3
Element inherits node (node derived object), so you can use the properties and methods of the parent node.
If you also check the node implementation, there are the following methods:
There are also the following implementations:
When reading the MDN, the parent object implementation should check the parent object's page, while the target object's page explains what the parent (derived from) object is.Search for "object inheritance" to see why a
element can use a node implementation.
- python 3x - how to remove 0 elements in numpy 2darray
- php - i want to remove commas from the data in $this-> data