<div id="mask"> <i class="fa fa-cog fa-spin" aria-hidden="true"></i> </div>
<!-- Modal -->
<div class="modal fade" id="modalPopup" role="dialog">
  <div class="modal-dialog modal-sm">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal">&times;</button>
        <h4 class="modal-title">Modal Header</h4>
      </div>
      <div class="modal-body">
        <p>Modal message</p>
      </div>
      <div class="modal-footer">
        <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
      </div>
    </div>
  </div>
</div>

<!-- Modal -->
<div class="modal fade" id="modalWorkArea" tabindex="-1" role="dialog" aria-labelledby="modalWorkAreaLabel" aria-hidden="true">
  <div class="modal-dialog">
    <div class="modal-content"> 
      <!-- Modal Header -->
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal"> <span aria-hidden="true">&times;</span> <span class="sr-only">Close</span> </button>
        <h4 class="modal-title" id="modalWorkAreaLabel"> Modal title </h4>
      </div>
      <!-- Modal Body -->
      <div id="work_area" class="modal-body">Loading...</div>
      <!-- Modal Footer -->
      <div class="modal-footer">
      	<div id="modal_ajax_actions" class="pull-left"><i class="fa fa-cog fa-spin"></i>&nbsp;Please wait</div>
        <button type="button" class="btn btn-primary" id="closebutton" data-dismiss="modal"> Close </button>
        <button type="button" class="btn btn-success" id="savechangesbutton"> Save changes </button>
      </div>
    </div>
  </div>
</div> 

<!-- Image Processing Modal -->
<div class="modal fade" id="modalImageProcess" tabindex="-1" role="dialog" aria-labelledby="modalImageProcessLabel" aria-hidden="true" onclick="javascript:void(0);">
  <div class="modal-dialog modal-lg">
  <script type="text/javascript">
  function resetImageSelectArea() {
	  $('.imgareaselect-outer').addClass('zero_index');
	  $('.imgareaselect-selection').parent().addClass('zero_index');
	  $('#working_image').attr('src', 'public/media/img/work_area_bg.gif');
	  $('#x1, #y1, #x2, #y2').val('');
  };
  </script>
    <div class="modal-content"> 
      <!-- Modal Header -->
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" onclick="resetImageSelectArea();"> <span aria-hidden="true">&times;</span> <span class="sr-only">Close</span> </button>
        <h4 class="modal-title" id="modalImageProcessLabel"> Process Product Image </h4>
        <div class="clearfix"></div>
      </div>
      <div class="clearfix"></div>
      <!-- Modal Body -->
      <div id="image_work_area" class="modal-body">
      <div class="clearfix"></div>
<!-- image cropping -->
	  <div id="image_work_area_wrapper" style="margin:0; padding:0!important; width:800px!important; background:#ff0000;">
		<img id="working_image" style="margin:0;" src="public/media/img/work_area_bg.gif" />
        <div class="clearfix"></div>
      </div>
<!-- end image cropping -->  
          <div class="clearfix"></div>
          <div class="hidden">
              x1<input type="text" id="x1" name="x1" value="" />  
              y1<input type="text" id="y1" name="y1" value="" />
              x2<input type="text" id="x2" name="x2" value="" />   
              y2<input type="text" id="y2" name="y2" value="" /> 
          </div>   
          <div class="clearfix"></div>
      </div>
      <!-- Modal Footer -->
      <div class="modal-footer">
      	<div id="image_ajax_actions" class="pull-left"><i class="fa fa-cog fa-spin"></i>&nbsp;Please wait</div>
        <button type="button" class="btn btn-primary" id="closebutton" data-dismiss="modal" onclick="resetImageSelectArea();"> Close </button>
        <button type="button" class="btn btn-success" id="saveimagebutton"> Apply </button>
      </div>
      <div class="clearfix"></div>
    </div>
  </div>
</div> 

<!-- Confirm Delete Modal-->
<!-- Modal Dialog -->
<div class="modal fade" id="confirmDelete" role="dialog" aria-labelledby="confirmDeleteLabel" aria-hidden="true">
<div class="modal-dialog">
  <div class="modal-content">
    <div class="modal-header">
      <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
      <h4 class="modal-title">Delete Permanently</h4>
    </div>
    <div class="modal-body">
      <p>Are you sure ?</p>
    </div>
    <div class="modal-footer">
      <button type="button" class="btn btn-default" id="canceldelete" data-dismiss="modal">Cancel</button>
      <button type="button" class="btn btn-danger" id="confirm">Delete</button>
    </div>
  </div>
</div>
</div>