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
/** | |
* DWTFYW License | |
* | |
* Author: Tony Brix, http://tonybrix.info | |
* | |
* This function trims all strings in an object or array | |
* | |
* This is useful when sending ajax requests | |
* | |
* var vals = { |
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
/** | |
* DWTFYW License | |
* | |
* Author: Tony Brix, http://tonybrix.info | |
* | |
* Formats date in mm/dd/yyyy format as yyyy-mm-dd | |
* | |
* Returns false on failure | |
* | |
*/ |
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 | |
/** | |
* DWTFYW License | |
* | |
* Author: Tony Brix, http://tonybrix.info | |
* | |
* Show logs from a file that matches a regular expression. Matches multiline records. | |
* @param string $file The file to search | |
* @param string $search [optional] A string or regular expression to match; default = "" |
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 | |
/** | |
* Author: Tony Brix, http://tonybrix.info | |
* | |
* Send POST request to a webpage from php and return the response. | |
* @param string $url The url of the webpage you would like to send the request to. | |
* @param array $data The post data to send with the request. | |
* @return string The response of the request | |
*/ | |
function sendPost($url, $data) { |
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
/** | |
* DWTFYW License | |
* Author: Tony Brix, http://tonybrix.info | |
* | |
* Usage: | |
* $("input").erasable(); | |
*/ | |
(function ($) { | |
var defaults = { | |
//align: "right" |
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
/** | |
* Author: Tony Brix, Tony@Brix.ninja | |
* License: MIT http://www.opensource.org/licenses/mit-license.php | |
* Template Gist: https://gist.github.com/UziTech/f85d7756ed931c304281 | |
* Description: | |
*/ | |
; | |
(function ($, undefined) { | |
"use strict"; | |
var pluginName = "plugintemplate";//TODO: ENTER YOUR PLUGIN NAME |
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
/** | |
* Author: Tony Brix | |
* Website: tony.brix.ninja | |
* License: MIT | |
* Description: Remove items from an array. Optionally limit the number of items to remove from the beginning or end of the array. | |
* Examples: | |
* var a = [1, 2, 3, 1, 2, 3]; | |
* a.remove(1); // [2, 3, 2, 3] | |
* a.remove(2, 1); // [1, 3, 1, 2, 3] | |
* a.remove(3, -1); // [1, 2, 3, 1, 2] |
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
/* | |
* DWTFYW License | |
* Author: Tony Brix, http://tonybrix.info | |
* | |
* Simple overlay with text/html in the center and a delayed cancel button | |
* Requires jQuery | |
* | |
* if cancelTimeDelay is < 0 then there is no cancel button | |
* | |
*/ |
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
/* | |
* License: MIT | |
* Author: Tony Brix, https://Tony.Brix.ninja | |
* Description: Get files from directory asynchronously and recursively with promises. | |
*/ | |
var fs = require("fs"); | |
var path = require("path"); | |
module.exports = { |
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
/* | |
* License: MIT | |
*/ | |
/** | |
* Search files in a directory by string or regex | |
* @param string $root Directory to search | |
* @param string $q Search term | |
* @param bool $recursive [optional] Search lower directories. Default = TRUE | |
* @param bool $isRegex [optional] Search term is a regular expression. Default = FASLE |
OlderNewer