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
javascript | |
ES6ValidationInspection | |
JSAccessibilityCheckInspection | |
JSBitwiseOperatorUsageInspection | |
JSCheckFunctionSignaturesInspection | |
JSClosureCompilerSyntaxInspection | |
JSCommentMatchesSignatureInspection | |
JSComparisonWithNaNInspection | |
JSConsecutiveCommasInArrayLiteralInspection |
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 | |
/** | |
* An example function used to demonstrate how to use the `user_can_save` function | |
* that provides boilerplate security checks when saving custom post meta data. | |
* | |
* The ultimate goal is provide a simple helper function to be used in themes and | |
* plugins without the need to use a set of complex conditionals and constants. | |
* | |
* Instead, the aim is to have a simplified function that's easy to read and that uses | |
* WordPress APIs. |
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 ($) { | |
/* Twitter Bootstrap Message Helper | |
** Usage: Just select an element with `alert` class and then pass this object for options. | |
** Example: $("#messagebox").message({text: "Hello world!", type: "error"}); | |
** Author: Afshin Mehrabani <afshin.meh@gmail.com> | |
** Date: Monday, 08 October 2012 | |
*/ | |
$.fn.message = function(options) { | |
//remove all previous bootstrap alert box classes | |
this[0].className = this[0].className.replace(/alert-(success|error|warning|info)/g , ''); |
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 | |
/** | |
* Convert a comma separated file into an associated array. | |
* The first row should contain the array keys. | |
* | |
* Example: | |
* | |
* @param string $filename Path to the CSV file | |
* @param string $delimiter The separator used in the file | |
* @return array |