This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<!-- CSS --> | |
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"> | |
<!-- JS --> | |
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.6.3/angular.min.js"></script> | |
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.6.3/angular-animate.js"></script> | |
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.6.3/angular-messages.js"></script> | |
<!-- |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function new_submenu_class($menu) { | |
$menu = preg_replace('/ class="sub-menu"/','/ class="yourclass" /',$menu); | |
return $menu; | |
} | |
add_filter('wp_nav_menu','new_submenu_class'); | |
?> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$urls = "yahoo.com Regexes are not a magic wand that you wave at every problem that involves strings. Plus," | |
. " validation of URLs is a solved problem that you do not need to solve yourself. " | |
. "google.com You use existing http://maxworth.ca/wp-admin/customize.php?return=%2Fwp-admin%2Fupdate-core.php&autofocus%5Bcontrol%5D=background_image code google.com that has bing.com already " | |
. "been https://google.com written, tested and debugged"; | |
function makeUrls($urls) { | |
$url_list = preg_split('/[\s]+/', $urls); | |
$pattern = '/(?:https?:\/\/)?(?:[a-zA-Z0-9.-]+?\.(?:[a-zA-Z])|\d+\.\d+\.\d+\.\d+)/'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
autocomplete.addListener('place_changed', function() { | |
var place = autocomplete.getPlace(); | |
//Extract country from autocomplete address api | |
var country; | |
for(var c = 0; c < place.address_components.length; c += 1) { | |
var locality = place.address_components[c]; | |
for(var d = 0; d < locality.types.length; d += 1) { | |
if (locality.types[d] === 'country') { | |
country = locality.long_name; // confirm that this is the country name | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
autocomplete.addListener('place_changed', function() { | |
var place = autocomplete.getPlace(); | |
//Extract city from autocomplete address api | |
var city; | |
for(var a = 0; a < place.address_components.length; a += 1) { | |
var addressObj = place.address_components[a]; | |
for(var b = 0; b < addressObj.types.length; b += 1) { | |
if (addressObj.types[b] === 'locality') { | |
city = addressObj.long_name; // confirm that this is the country name | |
//console.log(addressObj.long_name); // confirm that this is the country name |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="controls"> | |
<div class="span1 four"><a id="editPoly" class="tracing-control active" title="This is the drawing/tracing tool. Work with this tool to create your outlines."><i class="fa fa-lg fa-pencil icon-pencil icon-large"></i><br>Trace</a></div> | |
<div class="span1 four"><a id="moveMap" class="tracing-control" title="Click here to move the map. Or click and drag when in Tracing mode."><i class="fa fa-lg fa-arrows icon-move icon-large"></i><br>Edit</a></div> | |
<div class="span1 four"> <a id="undoDrawing" class="tracing-control" title="Did your tracing not turn out? Click here to undo your last outline."><i class="fa fa-lg fa-undo icon-undo icon-large"></i><br>Undo</a> | |
</div> | |
</div> | |
<?php $yard_size = $_POST['yard_size'];?> | |
<input type="hidden" name="yard_size" id="yard_size" value="<?php $yard_size?>"> | |
<div id="map" style="display: block; width: 100%; height: 500px;"></div> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function($) { | |
//id of sidebar | |
var element = $('#sidebar') | |
originalY = $(element).offset().top; | |
// Space between element and top of screen (when scrolling) | |
var topMargin = 20; | |
// Should probably be set in CSS; but here just for emphasis | |
element.css('position', 'relative'); | |
$(window).on('scroll', function(event) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function($) { | |
//id of sidebar | |
var element = $('#sidebar') | |
originalY = $(element).offset().top; | |
// Space between element and top of screen (when scrolling) | |
var topMargin = 20; | |
// Should probably be set in CSS; but here just for emphasis | |
element.css('position', 'relative'); | |
$(window).on('scroll', function(event) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
application/x-httpd-php functions.php ( PHP script, ASCII text ) | |
<?php | |
/** | |
* | |
* 1. Bond Only - Expedia, Direct, HomeAway | |
* https://readysethost.co/checkout/?add-to-cart=772:1:2.00&rcode=TST2&fname=Mike&lname=Aubor&email=damiike%40gmail.com | |
* 2. Booking Only - Booking.com, Direct, HomeAway | |
* https://readysethost.co/checkout/?add-to-cart=1334:1:1.00&rcode=TST2&fname=Mike&lname=Aubor&email=damiike%40gmail.com | |
* 3. Booking Deposit Only - Direct, HomeAway |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* C.1. Custom Billing Field | |
*/ | |
add_filter( 'woocommerce_billing_fields' , 'wc_custom_fields' ); | |
function wc_custom_fields( $fields ) { | |
$fields['billing_reservationcode'] = array( | |
'type' => 'text', | |
'required' => true, | |
'class' => array('reservationcode'), |
OlderNewer