为了账号安全,请及时绑定邮箱和手机立即绑定

js里面怎么多排添加字符?

var heml = '<div class="ui-datepicker-header">
                <a href="#" class="ui-datepicker-btn ui-datepicker-prev-btn">&lt;</a>
                <a href="#" class="ui-datepicker-btn ui-datepicker-next-btn">&gt;</a>
                <span class="ui-datepicker-curr-month">2017-4</span>
            </div>
            <div class="ui-datepicker-body">
                <table>
                    <thead>
                        <tr>
                            <th>一</th>
                            <th>二</th>
                            <th>三</th>
                            <th>四</th>
                            <th>五</th>
                            <th>六</th>
                            <th>七</th>
                        </tr>    
                    </thead>                    
                    <tbody>                        
                        <tr>                            
                            <td>29</td>
                            <td>30</td>
                            <td>1</td>
                            <td>2</td>
                            <td>3</td>
                            <td>4</td>
                            <td>5</td>
                        </tr>
                        <tr>                            
                            <td>6</td>
                            <td>7</td>
                            <td>8</td>
                            <td>9</td>
                            <td>10</td>
                            <td>11</td>
                            <td>12</td>
                        </tr>
                        <tr>                            
                            <td>13</td>
                            <td>14</td>
                            <td>15</td>
                            <td>16</td>
                            <td>17</td>
                            <td>18</td>
                            <td>19</td>
                        </tr>
                        <tr>                            
                            <td>20</td>
                            <td>21</td>
                            <td>22</td>
                            <td>23</td>
                            <td>24</td>
                            <td>25</td>
                            <td>26</td>
                        </tr>
                        <tr>                            
                            <td>27</td>
                            <td>28</td>
                            <td>29</td>
                            <td>30</td>
                            <td>1</td>
                            <td>2</td>
                            <td>3</td>
                        </tr>                        
                    </tbody>
                </table>
            </div>';


正在回答

1 回答

每个标签左右俩边加'这个符号,然后例如'<td>1</td>' + '<td>1</td>'这样,视频里面都有讲的

0 回复 有任何疑惑可以回复我~

举报

0/150
提交
取消

js里面怎么多排添加字符?

我要回答 关注问题
意见反馈 帮助中心 APP下载
官方微信