Skip to content

Instantly share code, notes, and snippets.

function the_boolean(){
global $post;
$custom = get_post_custom($post->ID);
$the_boolean = $custom["the_boolean"][0];
?>
<input type="checkbox" name="the_boolean" id="the_boolean_box" value="<?php if ( $the_boolean == TRUE ) echo 'true'; else echo 'false'; ?>" <?php if ( $the_boolean == TRUE ) echo 'checked'; ?> /><label for="the_boolean_box"> The</label>
<?php
}
function save_the_boolean(){
global $post;
Returning to St. Petersburg, Tolstoy was received with great favor in both the official and literary circles of the capital.
function throttle( fn, time ) {
var t = 0;
return function() {
var args = arguments, ctx = this;
clearTimeout(t);
t = setTimeout( function() {
fn.apply( ctx, args );
}, time );
};