浏览代码

Merge pull request #8 from babolivier/development

Button now has a specific id
父节点
当前提交
13be37fe17
共有 2 个文件被更改,包括 2 次插入2 次删除
  1. 1
    1
      README.md
  2. 1
    1
      front/form.js

+ 1
- 1
README.md 查看文件

@@ -120,7 +120,7 @@ The generated form will look like this:
120 120
     <textarea required="required" placeholder="Your message" id="form_text_textarea"></textarea>
121 121
 </div>
122 122
 <div id="form_subm">
123
-    <button type="submit" id="form_subm">Send the mail</button>
123
+    <button type="submit" id="form_subm_btn">Send the mail</button>
124 124
 </div>
125 125
 ```
126 126
 

+ 1
- 1
front/form.js 查看文件

@@ -175,7 +175,7 @@ function getSubmitButton(id, text) {
175 175
     var button = document.createElement('button');
176 176
     
177 177
     button.setAttribute('type', 'submit');
178
-    button.setAttribute('id', id);
178
+    button.setAttribute('id', id + '_btn');
179 179
     
180 180
     button.innerHTML = text;
181 181