<?php $__env->startSection('content'); ?>

  <div class="page-heading">
                <div class="bread">
                    <h4><?php echo e(__('web.formdesc')); ?></h4>
                    <nav aria-label="breadcrumb">
                        <ol class="breadcrumb">
                        <li class="breadcrumb-item"><a href="<?php echo e(url(getCurrentLocale().'/')); ?>"><?php echo e(__('web.home')); ?></a></li>
                        <li class="breadcrumb-item active" aria-current="page"><?php echo e(__('web.form')); ?> </li>
                        </ol>
                    </nav>
                </div>
            </div>  
        <main>
            <!--start diet-form-->
            <section class="diet-form">
                <div class="container">
                    <div class="row">
                        <div class="col-md-8 m-auto">
                            <div class="inner">
                                <div class="text mb-5">
                                    <h3><?php echo e(__('web.fromdesc')); ?></h3>
                                </div>
                                
                                <form  id="formcontacts" onsubmit="contacts()"  method="post" action="<?php echo e(url(getCurrentLocale().'/forming')); ?>">
                                    <?php echo csrf_field(); ?>
                                   
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.name')); ?></label>
                                            <div class="form-group">
                                                <input name="name" class="form-control">
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.age')); ?></label>
                                            <div class="form-group">
                                                <input name="age" class="form-control" >
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.length')); ?></label>
                                            <div class="form-group">
                                                <input name="length" class="form-control" >
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.weigth')); ?></label>
                                            <div class="form-group">
                                                <input name="weigth" class="form-control" >
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.nick')); ?></label>
                                            <a href="<?php echo e(url('')); ?>/assets/web/images/form-img-1.jpg" data-fancybox="images" class="example-link" data-caption="محيط الرقبه">
                                                <?php echo e(__('web.example')); ?>

                                            </a>
                                            <div class="form-group">
                                                <input name="nick"  class="form-control" >
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.medium')); ?></label>
                                            <a href="<?php echo e(url('')); ?>/assets/web/images/form-img-2.jpg" data-fancybox="images" class="example-link" data-caption="محيط الوسط">
                                                <?php echo e(__('web.example')); ?>

                                            </a>
                                            <div class="form-group">
                                                <input name="medium" class="form-control" >
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.basin')); ?></label>
                                            <a href="<?php echo e(url('')); ?>/assets/web/images/form-img-3.jpg" data-fancybox="images" class="example-link" data-caption="محيط الحوض">
                                                <?php echo e(__('web.example')); ?>

                                            </a>
                                            <div class="form-group">
                                                <input name="basin" class="form-control" >
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.medicine')); ?></label>
                                            <div class="form-group">
                                                <input name="medicine" class="form-control" >
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.vitamins')); ?></label>
                                            <div class="form-group">
                                                <input name="vitamins" class="form-control" >
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.goal')); ?></label>
                                            <div class="form-group">
                                                <select  name="goal" class="form-control" >
                                                    <option value="0"><?php echo e(__('web.weightless')); ?></option>
                                                    <option value="1"><?php echo e(__('web.overweight')); ?></option>
                                                    <option value="2" ><?php echo e(__('web.health')); ?></option>
                                                    <option value="3"><?php echo e(__('web.sportincrease')); ?></option>
                                                    <option value="4"><?php echo e(__('web.other')); ?></option>
                                                </select>
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.wakeup')); ?></label>
                                            <div class="form-group">
                                                <input  name="wakeup" class="form-control" >
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.food')); ?></label>
                                            <div class="form-group">
                                                <input  name="food" class="form-control" >
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.examples')); ?></label>
                                            <div class="form-group">
                                                <input  name="example" class="form-control" >
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.work')); ?></label>
                                            <div class="form-group">
                                                <input name="work" class="form-control" >
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.train')); ?></label>
                                            <div class="form-group">
                                                <input name="train" class="form-control" >
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.sport')); ?></label>
                                            <div class="form-group">
                                                <input name="sport" class="form-control" >
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.meals')); ?></label>
                                            <div class="form-group">
                                                <input name="meals" class="form-control" >
                                            </div>
                                        </div>
                                        <div class="col-md-12">
                                            <label><?php echo e(__('web.sense')); ?></label>
                                            <div class="form-group">
                                                <input name="sense" class="form-control" >
                                            </div>
                                        </div>
                                         <div class="row">
                                        <div id="success" style="display : none" class="col-12 alert alert-success">
                           
                        </div>
                         <div id="error" style="display : none" class="col-12 alert alert-danger">
                           
                        </div>
                                        <div class="col-md-12">
                                            <button class="bg-butn"><span><?php echo e(__('web.send')); ?></span></button>
                                        </div>
                                    </div>
                                </form>
                            </div>
                        </div>
                    </div>
                </div>
            </section>
        </main>

 <?php $__env->startPush('js'); ?>
   <script>
        function contacts(){
        event.preventDefault(); 
       var action = $('#formcontacts').attr('action');
       var urls = action;
       var dataform = $('#formcontacts').serialize();
     
      $.ajax({
          url : urls,
          type: 'POST',              
          data: dataform,
          success:function(data)
          {
           
              $('#error').css("display", "none");
              $('#success').css("display", "block");
            $('#success').html('تم ارسال رسالتك بنجاح');
             location.reload();
             
          }
          ,error:function(data) {
             
              $('#success').css("display", "none");
              $('#error').html('');
    $('#error').css("display", "block");
   
   $.each(data.responseJSON.errors, function(value) {
     $('#error').append('<div class="col-12">'+value+'</div');
     
     
 }); 
 
}
        })
        }
    </script>
   <?php $__env->stopPush(); ?>
<?php $__env->stopSection(); ?>
<?php echo $__env->make('web.layouts.main', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/omaralyomhost/public_html/nawalgym/resources/views/web/pages/form.blade.php ENDPATH**/ ?>