This file contains 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
// original from: http://mashe.hawksey.info/2014/07/google-sheets-as-a-database-insert-with-apps-script-using-postget-methods-with-ajax-example/ | |
// original gist: https://gist.github.com/willpatera/ee41ae374d3c9839c2d6 | |
function doGet(e){ | |
return handleResponse(e); | |
} | |
// Enter sheet name where data is to be written below | |
var SHEET_NAME = "Sheet1"; |
This file contains 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
$.fn.serializeObject = function() { | |
var o = {}; | |
var a = this.serializeArray(); | |
$.each(a, function() { | |
if (o[this.name]) { | |
if (!o[this.name].push) { | |
o[this.name] = [o[this.name]]; | |
} | |
o[this.name].push(this.value || ""); | |
} else { |
This file contains 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
================================================================= | |
Ultimate Comment Blacklist | |
Source: | |
Ultimate Comment Blacklist for WordPress | |
https://perishablepress.com/wordpress-ultimate-comment-blacklist/ | |
License: |
This file contains 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 lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> | |
<meta name="description" content=""> | |
<meta name="author" content=""> | |
<title>Bare - Start Bootstrap Template</title> | |
<!-- Bootstrap core CSS --> |
This file contains 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
# BEGIN Expire headers | |
<ifModule mod_expires.c> | |
ExpiresActive On | |
ExpiresDefault "access plus 5 seconds" | |
ExpiresByType image/x-icon "access plus 2592000 seconds" | |
ExpiresByType image/jpeg "access plus 2592000 seconds" | |
ExpiresByType image/png "access plus 2592000 seconds" | |
ExpiresByType image/gif "access plus 2592000 seconds" | |
ExpiresByType image/svg+xml "access plus 2592000 seconds" | |
ExpiresByType application/x-font-ttf "access plus 2592000 seconds" |
This file contains 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
document.onkeydown = checkKey; | |
function checkKey(e) { | |
e = e || window.event; | |
if (e.keyCode == '38') { | |
// up arrow | |
} | |
else if (e.keyCode == '40') { | |
// down arrow |
This file contains 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 | |
date_default_timezone_set('america/chicago'); | |
$currentDayTime = new DateTime(); // Get Today's Date/Time | |
echo $currentDayTime->format('m-d-Y H:i') . "<br>"; | |
$startDateTime = new DateTime('2020-01-15'); | |
$startDateTime->setTime(8, 00); | |
echo $startDateTime->format('m-d-Y H:i') . "<br>"; |
This file contains 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
wp_nav_menu( array $args = array( | |
'menu' => "", // (int|string|WP_Term) Desired menu. Accepts a menu ID, slug, name, or object. | |
'menu_class' => "", // (string) CSS class to use for the ul element which forms the menu. Default 'menu'. | |
'menu_id' => "", // (string) The ID that is applied to the ul element which forms the menu. Default is the menu slug, incremented. | |
'container' => "", // (string) Whether to wrap the ul, and what to wrap it with. Default 'div'. | |
'container_class' => "", // (string) Class that is applied to the container. Default 'menu-{menu slug}-container'. | |
'container_id' => "", // (string) The ID that is applied to the container. | |
'fallback_cb' => "", // (callable|bool) If the menu doesn't exists, a callback function will fire. Default is 'wp_page_menu'. Set to false for no fallback. | |
'before' => "", // (string) Text before the link markup. | |
'after' => "", // (string) Text after the link mar |
This file contains 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 currencyFormat(num) { | |
return '$' + num.toFixed(2).replace(/(\d)(?=(\d{3})+(?!\d))/g, '$1,') | |
} | |
console.info(currencyFormat(2665)) // $2,665.00 | |
console.info(currencyFormat(102665)) // $102,665.00 |