 <?php   
$domain=$_SERVER['SERVER_NAME']; 
// echo $domain;die;
$curPageName = substr($_SERVER["SCRIPT_NAME"],strrpos($_SERVER["SCRIPT_NAME"],"/")+1); 
 $curPageName1 = ucfirst(substr($curPageName,0,-4));
?>

<?php include('header.php')?>
<!-- End Navbar Area -->		<!-- Start Page Title Area -->
		<div class="page-title-area bg-8">
			<div class="container">
				<div class="page-title-content">
					<h2>Contact us</h2>

					<ul>
						<li>
							<a href="index.php">
								Home 
							</a>
						</li>

						<li class="active">Contact us</li>
					</ul>
				</div>
			</div>
		</div>
		<!-- End Page Title Area -->

		<!-- Start Contact Area -->
		<section class="main-contact-area pt-100 pb-100">
			<div class="container">
				<form id="myForm" method="POST" enctype="multipart/form-data">
				  
					<div class="row">
						<div class="col-lg-8" style="    border: 2px solid #000000;padding: 40px;">
							<h3>Let’s get in touch</h3>
							    <div id="check1"></div>
							
							<div class="row">
								<div class="col-lg-6 col-sm-6">
									<div class="form-group">
										<label>Your name</label>
										<input type="text" name="name" id="name" class="form-control">
										<div class="help-block with-errors"></div>
									</div>
								</div>
		
								<div class="col-lg-6 col-sm-6">
									<div class="form-group">
										<label>Your email</label>
										<input type="email" name="email" id="email" class="form-control" >
										<div class="help-block with-errors"></div>
									</div>
								</div>
		
								<div class="col-lg-6 col-sm-6">
									<div class="form-group">
										<label>Your phone</label>
							<input type="text" name="phone" id="phone" class="form-control" maxlength="10" onkeypress="return isNumberKey(event)">
										<div class="help-block with-errors"></div>
									</div>
								</div>
		
								<div class="col-lg-6 col-sm-6">
									<div class="form-group">
										<label>Subject</label>
										<input type="text" name="subject" id="subject" class="form-control">
										<div class="help-block with-errors"></div>
									</div>
								</div>
		
								<div class="col-12">
									<div class="form-group">
										<label>Your message</label>
										<textarea name="message" class="form-control" id="message" cols="30" rows="8" ></textarea>
										<div class="help-block with-errors"></div>
									</div>
								</div>

		
				
		 <div class="row">
<div class="form-group col-md-12">
<!--<label for="phone"></label>-->
<input type="hidden" name="url" id="url" value="<?php echo $curPageName; ?>" class="form-control required" placeholder="url...">

</div>
<div class="form-group col-md-12">
<!--<label for="phone"></label>-->
<input type="hidden" name="domain" id="domain" value="<?php echo $domain; ?>" class="form-control required" placeholder="domain...">
<input type="hidden" name="project_unique_code" id="project_unique_code" value="uniquedosingpumps79" class="form-control required">

</div>
</div>
                  
		
		
								<div class="col-lg-12 col-md-12">
									<button type="submit" name="submit" id="btn_submit"  class="default-btn">
										<span>Send message</span>
									</button>
									<div id="msgSubmit" class="h3 text-center hidden"></div>
									<div class="clearfix"></div>
								</div>
							</div>
						</div>
						
						
						<script src="../ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>

						
						
						 <script src="../ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
   


						<div class="col-lg-4">
							<div class="single-contact-bg">
								<div class="single-contact-info">
									<h3>Contact information</h3>
		
									<ul class="address">
										<li class="location">
											<span>Address</span>
											Plot No. - M88, MIDC, Ambad, Nashik - 422010, Maharashtra, India.
										</li>
										<!--<li>-->
										<!--	<span>Phone</span>-->
										<!--	<a href="tel:+91-9130022891">+91-9130022891 </a>-->
										<!--</li>-->
										
										<li>
											<span>Phone: (Mr. Mahendra Kasar)</span>
											
											<a href="tel: +91-9822420535"> +91-9822420535</a><a href="tel: 0253-2386610"> 0253-2386610</a>
											
										
										</li>
										
										<li>
											<span>Phone</span>
											<a href="tel:+91 88054 00535"> +91 88054 00535</a>
										</li>
										<li>
											<span>Email</span>
											<a href="mailto:info@uniquedosing.com">info@uniquedosing.com</a>
										</li>
										<li>
											<span>Email</span>
											<a href="mailto:sales@uniquedosing.com">sales@uniquedosing.com</a>
										</li>
									</ul>
									<div class="social-links" style="margin-top:4%;">
        
									<span><b>Share:</b></span>
								
									<a href="https://www.facebook.com/uniquedosingsystems/" target="_blank" style="border-radius: 50%;
    border: 2px solid gray;margin:3px;">
										<i class="ri-facebook-fill"></i>
									</a>
							
									<a href="" style="border-radius: 50%;
    border: 2px solid gray;margin:3px;">
										<img src="assets/img/download/skp.png"> 
								</a>
								
      </div>
								</div>
		
							
							</div>
						</div>
					</div>
				</form>
			</div>
		</section>
		<!-- End Contact Area -->

		<!-- Start Map Area -->
		<div class="map-area">
			
			<iframe src="https://www.google.com/maps/embed?pb=!1m14!1m8!1m3!1d30001.84996102254!2d73.74463!3d19.956775!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x3bddecad61841edf%3A0xe710d0cfe3ef5ea!2sUnique%20Dosing%20System%20Pvt.%20Ltd!5e0!3m2!1sen!2sin!4v1695817395696!5m2!1sen!2sin" width="600" height="450" style="border:0;" allowfullscreen="" loading="lazy" referrerpolicy="no-referrer-when-downgrade"></iframe>
		</div>
		<!-- End Map Area -->

	

		
		<!-- End Newsletters Area -->
	<link rel="stylesheet" href="assets/css/about-item.css">
<?php include('footer.php')?>







<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<script type="text/javascript">


    $(document).ready(function(){
      
        $('#myForm').submit(function(e){
            
            e.preventDefault();
            var name = $('#name').val();
            var subject = $('#subject').val();
            var email = $('#email').val();
            var phone = $('#phone').val();
            var message = $('#message').val();
            var error = false;
            var flg=1;
            //alert(name);alert(email);alert(subject);
             var name_regex="^[a-zA-Z\\s]*$";
            var email_regex =/\b(^(\S+@).+((\.com)|(\.net)|(\.edu)|(\.mil)|(\.gov)|(\.org)|(\.info)|(\.in)|(\.biz)|(\.aero)|(\.coop)|(\.museum)|(\.name)|(\.pro)|(\..{2,2}))$)\b/gi;
            var mobile_regex=/\d{10}/;
        if(!name.match(name_regex) || name == "")
        {
          $('#check1').html('** Please Enter your Name **').css( "color", "red");
          $("#name").focus();
          var error = true;
          return false;
        }
        
         
         if (!email.match(email_regex)|| email == "") 
        {
          $('#check1').html('** Please Enter Your Email Id **').css( "color", "red");
          $("#email").focus();
          var error = true;
          return false;
        }
        
        if (!phone.match(mobile_regex)|| phone == "") 
        {
          $('#check1').html('** Please Enter Your Phone No **').css( "color", "red");
          $("#phone").focus();
          var error = true;
          return false;
        }
        
        if( subject == "")
        {
          $('#check1').html('** Please Select your Subject **').css( "color", "red");
          $("#subject").focus();
          var error = true;
          return false;
        }
     
         if (message == "") 
        {
          $('#check1').html('** Please Enter Your Message **').css( "color", "red");
          $("#message").focus();
          var error = true;
          return false;
        } 
        if(error!=true)
            {
                $('#btn_submit').attr({'disabled' : 'true', 'value' : 'Sending...' });  
               var form = $('#myForm')[0];
                var formData = new FormData(form);
                $.ajax({
                    url: "contact_valid.php",

                    type: "POST",             
                    data: formData,
                    contentType: false,       
                    cache: false,             
                    processData:false, 
                    success: function(data) {
                    
                       
                        if(data=='sent')
                        {
                            $('#btn_submit').removeAttr('disabled').attr('value', 'Sent')
                            $('#check1').html('** Thank You For Contacting Us,We Will Contact You Soon.. **').css( "color", "green");
                             $("#myForm").get(0).reset();
                            
                        }
                        else
                        {
                                $('#btn_submit').removeAttr('disabled').attr('value', 'Retry');
                            $('#check1').html(data).css("color","red");
                        }
                    }
                });
                return false;
            }
            else
            {
                alert("error");
            }
        });
    });
</script>






<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<script type="text/javascript">


    $(document).ready(function(){
      
        $('#myForm').submit(function(e){
            
            e.preventDefault();
            var name = $('#name').val();
            var subject = $('#subject').val();
            var email = $('#email').val();
            var phone = $('#phone').val();
            var message = $('#message').val();
            var error = false;
            var flg=1;
            //alert(name);alert(email);alert(subject);
             var name_regex="^[a-zA-Z\\s]*$";
            var email_regex =/\b(^(\S+@).+((\.com)|(\.net)|(\.edu)|(\.mil)|(\.gov)|(\.org)|(\.info)|(\.in)|(\.biz)|(\.aero)|(\.coop)|(\.museum)|(\.name)|(\.pro)|(\..{2,2}))$)\b/gi;
            var mobile_regex=/\d{10}/;
        if(!name.match(name_regex) || name == "")
        {
          $('#check1').html('** Please Enter your Name **').css( "color", "red");
          $("#name").focus();
          var error = true;
          return false;
        }
        
         
         if (!email.match(email_regex)|| email == "") 
        {
          $('#check1').html('** Please Enter Your Email Id **').css( "color", "red");
          $("#email").focus();
          var error = true;
          return false;
        }
        
        if (!phone.match(mobile_regex)|| phone == "") 
        {
          $('#check1').html('** Please Enter Your Phone No **').css( "color", "red");
          $("#phone").focus();
          var error = true;
          return false;
        }
        
        if( subject == "")
        {
          $('#check1').html('** Please Select your Subject **').css( "color", "red");
          $("#subject").focus();
          var error = true;
          return false;
        }
     
         if (message == "") 
        {
          $('#check1').html('** Please Enter Your Message **').css( "color", "red");
          $("#message").focus();
          var error = true;
          return false;
        } 
        if(error!=true)
            {
                $('#btn_submit').attr({'disabled' : 'true', 'value' : 'Sending...' });  
               var form = $('#myForm')[0];
                var formData = new FormData(form);
                $.ajax({
                    url: "https://script.google.com/macros/s/AKfycbyq-3aslv9EJImCF5faDnBvm2ZhAqVOEaQzm5Ld6hCzGU4k9oq3sPJ6OBPbJ1VBktIX/exec",

                    type: "POST",             
                    data: formData,
                    contentType: false,       
                    cache: false,             
                    processData:false, 
                    success: function(data) {
                     
                        if(data=='sent')
                        {
                            $('#btn_submit').removeAttr('disabled').attr('value', 'Sent')
                            $('#check1').html('** Thank You For Contacting Us,We Will Contact You Soon.. **').css( "color", "green");
                             $("#myForm").get(0).reset();
                            
                        }
                        else
                        {
                                $('#btn_submit').removeAttr('disabled').attr('value', 'Retry');
                            $('#check1').html(data).css("color","red");
                        }
                    }
                });
                return false;
            }
            else
            {
                alert("error");
            }
        });
    });
</script>
