View file File name : Add_aminity_form.php Content :<div class="container-fluid"> <div class="col-md-12 content-center"> <div class="card-plain"> <form class="form" method="post" action="<?=base_url()?>Add_aminity/Add_amminity"> <div class="header"> <h5>Add Aminity</h5> </div> <div class="content"> <div class="input-group"> <select name="properties" required class="form-control"> <option value="">select property</option> <?php foreach($prt as $pr){ ?> <option value="<?=$pr->id?>"><?=$pr->project_code?></option> <?php } ?> </select> </div> <div class="content"> <div class="input-group"> <select name="aminities" required class="form-control"> <option value="">select aminities</option> <?php foreach($data as $pr){ ?> <option value="<?=$pr->id?>"><?=$pr->name?></option> <?php } ?> </select> </div> </div> <div class="footer text-center"> <button type="submit" class="btn l-cyan btn-round btn-lg btn-block waves-effect waves-light">Add amminities</button> </div> </form> </div> </div> </div>