MMCT TEAM
Server IP : 103.53.40.154  /  Your IP : 3.142.133.210
Web Server : Apache
System : Linux md-in-35.webhostbox.net 4.19.286-203.ELK.el7.x86_64 #1 SMP Wed Jun 14 04:33:55 CDT 2023 x86_64
User : ppcad7no ( 715)
PHP Version : 8.2.25
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON
Directory (0750) :  /home2/ppcad7no/comfortaircon.co/

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : /home2/ppcad7no/comfortaircon.co/form.php
<?php
    // include_once('admin/config.php');
    if(isset($_POST['submit'])) 
    {
        $name = $_POST['name'];
        $phone = $_POST['phone'];
        $email = $_POST['email'];
        $service = $_POST['service'];
        
        $query="INSERT INTO `request`(`name`, `email`, `phone`, `service`) VALUES ('$name','$phone','$email','$service')";
        $result = mysqli_query($db, $query) or die("Query unsuccessful");
        if($result){
            echo ("<script>
            window.alert('Succesfully Send');
            window.location.href='index.php';
            </script>");
		
		mysqli_close($db);
     }else{
        echo"Error ";
    }
    }
    ?>
<!--===========================
        Start Contact Form
===========================-->
<section class="contact_form_area">
    <div class="contact_form_width">
        <h1 class="contact_map_title text-center">We're not putting on airs - our work is guaranteed to satisfy.</h1>
        <div class="img-fluid" >
            <iframe src="<?php echo $data2['map_link']?>" width="550" height="550" style="border:0;" allowfullscreen="" loading="lazy" referrerpolicy="no-referrer-when-downgrade"></iframe>
        </div>
    </div><!--end .contact_form_width-->
    <div class="contact_form_width contact-right">
        <div class="hero-title-with-shape">
            <h4 class="heading_with_border">Get a free quote</h4>
            <h1>To request a service call, please fill out the form below</h1>
        </div><!--end .hero-title-width-shape-->
        <form action="<?php $_PHP_SELF?>" method="POST">
            <input class="half_width input_m_right" type="text" name="name" placeholder="Your name">
            <input class="half_width" type="EMAIL" name="email" placeholder="Email address">
            <input type="tel" name="phone" placeholder="Phone number">
            <span class="select_icon">
                <select name="service" id="select">
                    <option value="option0">Select Service</option>
                    <?php                         
                      $sqlser = "SELECT * FROM `tbl_services`";
                      $runser = mysqli_query($db,$sqlser) or die("Query Not run");
                      while($dataser = mysqli_fetch_assoc($runser)){
                    ?>
                    <option value="<?php echo $dataser['property_name']?>"><?php echo $dataser['property_name']?></option>
                    
                    <?php }?>
                </select>
            </span>
            <button class="btn-yellow" value="SUBMIT NOW" name="submit">SUBMIT NOW</button>
        </form>
    </div><!--end .contact_form_width-->
</section><!--end .contact_form_area-->
<!--===========================
        End Contact Form
===========================-->

MMCT - 2023