76 lines
3.5 KiB
PHP
76 lines
3.5 KiB
PHP
<?php
|
|
/**
|
|
* Plugin Name: Roomwithavw Custom
|
|
* Description: Custom code for roomwithavw.co.uk
|
|
* Author: Ray Elliott
|
|
* Author URI: https://rayelliott.dev
|
|
* Text Domain: roomwithavw-custom
|
|
* Domain Path: /languages
|
|
* Version: 0.1.0
|
|
*
|
|
* @package Roomwithavw_Custom
|
|
*/
|
|
|
|
function roomwithavw_custom_add_scripts() {
|
|
wp_register_script( 'roomwithavw-custom-script', plugins_url( 'assets/js/index.js', __FILE__ ), '', '1.0', true );
|
|
wp_enqueue_script( 'roomwithavw-custom-script' );
|
|
|
|
wp_enqueue_style( 'roomwithavw-custom-styles', plugins_url( 'assets/css/style.css', __FILE__ ), '', '1.0' );
|
|
}
|
|
add_action( 'wp_enqueue_scripts', 'roomwithavw_custom_add_scripts' );
|
|
|
|
function roowitahvw_dequeue_scripts() {
|
|
wp_dequeue_script( LAYERS_THEME_SLUG . '-map-api' );
|
|
wp_deregister_script( LAYERS_THEME_SLUG . '-map-api' );
|
|
// wp_dequeue_script( LAYERS_THEME_SLUG . '-map-trigger' );
|
|
// wp_deregister_script( LAYERS_THEME_SLUG . '-map-trigger' );
|
|
}
|
|
add_action( 'wp_enqueue_scripts', 'roowitahvw_dequeue_scripts', 99 );
|
|
|
|
|
|
function roomwithavw_custom_enquiry_form() {
|
|
?>
|
|
<p class="lead">
|
|
We are family run business that enjoys liaising with our clients to ensure we provide the best experience. For this reason, unlike regular camper van hire companies, we are not using an online calendar booking system as we believe it takes away from the personal touch we strive to maintain.
|
|
</p>
|
|
|
|
<p class="lead">
|
|
Fill in the form below and one of our team will be in touch with you shortly.
|
|
</p>
|
|
<div class="enquiry-form wpcf7" role="form" dir="ltr">
|
|
<div class="screen-reader-response" aria-live="polite"></div>
|
|
|
|
<!-- <form action="https://mailthis.to/mailthis@gabbaell.co.uk" method="post" class="wpcf7-form" novalidate="novalidate"> -->
|
|
<form action="" method="post" id="rwavw-enquiry-form" class="wpcf7-form" novalidate="novalidate">
|
|
<p><label> Forename (required)<br />
|
|
<span class="wpcf7-form-control-wrap forename"><input type="text" name="forename" value="" size="40" class="wpcf7-form-control wpcf7-text wpcf7-validates-as-required" aria-required="true" aria-invalid="false" /></span> </label></p>
|
|
<p><label> Surname (required)<br />
|
|
<span class="wpcf7-form-control-wrap surname"><input type="text" name="surname" value="" size="40" class="wpcf7-form-control wpcf7-text wpcf7-validates-as-required" aria-required="true" aria-invalid="false" /></span> </label></p>
|
|
|
|
<p class="dates">
|
|
<label> Booking Date<br />
|
|
<span class="wpcf7-form-control-wrap booking-date">
|
|
<input type="date" name="booking-date" value="" class="rwavw-datepicker booking-date wpcf7-form-control wpcf7-date wpcf7-validates-as-date" aria-invalid="false" />
|
|
</span>
|
|
</label>
|
|
</p>
|
|
|
|
<p>
|
|
<label> Number of Days<br />
|
|
<span class="wpcf7-form-control-wrap day-count">
|
|
<input type="number" name="day-count" value="3" class="days wpcf7-form-control wpcf7-number wpcf7-validates-as-number" aria-invalid="false" />
|
|
</span>
|
|
</label>
|
|
</p>
|
|
|
|
<p><label> Your Email (required)<br />
|
|
<span class="wpcf7-form-control-wrap replyto"><input type="email" name="_replyto" value="" size="40" class="wpcf7-form-control wpcf7-text wpcf7-email wpcf7-validates-as-required wpcf7-validates-as-email" aria-required="true" aria-invalid="false" /></span> </label></p>
|
|
<p><input type="submit" value="Send" class="wpcf7-form-control wpcf7-submit" /></p>
|
|
<div class="wpcf7-response-output wpcf7-display-none" aria-hidden="true"></div>
|
|
</form>
|
|
</p>
|
|
</div>
|
|
<?php
|
|
}
|
|
add_shortcode('rwavw-capsule-enquiry', 'roomwithavw_custom_enquiry_form');
|