从其他页面获取变量变量变量包含1、2或3,jquery函数为具有相同数据的每个数字创建

i2loujxw  于 2021-09-13  发布在  Java
关注(0)|答案(0)|浏览(277)

我正在开发一个页面,其中会话通过变量传递数据。变量循环并创建1、2或3个表单,每个表单使用dropdwon进行选择,如@for($i=1$i<session()->get('benificary')+1$(i++)

<label class="form-label" for="name">Beneficiary Name</label>
               <input type="text" class="form-control @error('name') is-invalid @enderror"
              name="name[]" value="" id="name[]" placeholder="Employee Name" required data-parsley-minlength="6">

       <label class="form-label">Beneficiary Relation</label>
      <select class="form-control select2" id='relation[]' name="relation[]" required>

       <option value="" disabled selected hidden>Select Relation with</option>

      </select>

    <label class="form-label" for="cnic">Beneficiary CNIC Number</label>
     <input type="text"  data-inputmask="'mask': '54400-0120001-0'" class="form-control @error('cnic') is-invalid @enderror"
   name="cnic[]" value="" id="cnic[]" placeholder="54400-0120001-1" required data-parsley-minlength="15">

        <div class="col-md-4 col-lg-2 col-xl-4">

        <div class="mb-3">
    <label class="form-label">Beneficiary Bank</label>
      <select class="form-control select2" id='bank[]' name="bank[]" required data-parsley-minlength="1">
          <option value="" disabled selected hidden>Beneficiary Bank
               </option>

         </select>

 <label class="form-label">Beneficiary Bank Branch</label>
    <select class="form-control select2 Subbanks" id='Subbanks[]' name="branch[]" required data-parsley-minlength="1">
       <option value="" disabled selected hidden>Select Bank Branch
         </option>
           </select>

    <label class="form-label" for="account">Bank Account No</label>
      <input type="text"  class="form-control @error('account') is-invalid @enderror" 
         name="account[]" value="" id="account[]" placeholder="Enter Account No" required data-parsley-minlength="8"> 

      <hr>

@endfor how get every from with uniq id of dropdown

暂无答案!

目前还没有任何答案,快来回答吧!

相关问题