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
<div class="toggle"> | |
<input type="checkbox" class="check"> | |
<b class="b switch"></b> | |
<b class="b track"></b> | |
</div> |
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
<svg class="editorial" | |
xmlns="http://www.w3.org/2000/svg" | |
xmlns:xlink="http://www.w3.org/1999/xlink" | |
viewBox="0 24 150 28 " | |
preserveAspectRatio="none"> | |
<defs> | |
<path id="gentle-wave" | |
d="M-160 44c30 0 | |
58-18 88-18s | |
58 18 88 18 |
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 | |
//The content which should be parsed | |
$content = '<p>Hello, my name is John an my age is [calc-age day="4" month="10" year="1991"].</p>'; | |
$content .= '<p>Hello, my name is Carol an my age is [calc-age day="26" month="11" year="1996"].</p>'; | |
//The array with all the shortcode handlers. This is just a regular associative array with anonymous functions as values. A very cool new feature in PHP, just like callbacks in JavaScript or delegates in C#. | |
$shortcodes = array( | |
"calc-age" => function($data){ | |
$content = ""; | |
//Calculate the age |
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
#ui | |
.bg | |
.rings | |
- for (i = 0; i < 10; i++) | |
.ring | |
.border |
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 | |
/** | |
* Get either a gravatar URL or a complete image tag for a specified email | |
* | |
* @param string $sEmail The email address | |
* @param string $sSize The size on pixels, defaults to 80px [ 1 - 2048 ] | |
* @param string $sDefault Default imageset to use [ 404 | mp | identicon | monsterid | wavatar ] | |
* @param string $sRating Maximum rating (inclusive) [ g | pg | r | x ] | |
* @param boolean $bImg True to return the complete img-tag, false for just the URL |
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 | |
class Registry { | |
/** | |
* @var array The store for all objects | |
*/ | |
static private $store = array(); | |
/** |
NewerOlder