View naked-css-wp.php
<?php | |
function bk_is_naked_day($d) { | |
$start = date('U', mktime(-12, 0, 0, 04, $d, date('Y'))); | |
$end = date('U', mktime(36, 0, 0, 04, $d, date('Y'))); | |
$z = date('Z') * -1; | |
$now = time() + $z; | |
if ( $now >= $start && $now <= $end ) { | |
return true; | |
} |
View test_post_meta.php
<?php | |
remove_action('genesis_loop', 'genesis_do_loop'); | |
add_action('genesis_loop', 'custom_loop'); | |
function custom_loop() { | |
echo '<h1 class="entry-title" itemprop="headline">'.get_the_title().'</h1>'; | |
echo '<div class="clear"></div>'; | |
echo '<div class="singlebio">'; |
View tmpl_child-pages.php
<?php | |
/* | |
Template Name: Custom Loop | |
*/ | |
remove_action( 'genesis_loop','genesis_do_loop' ); | |
add_action( 'genesis_loop','my_custom_loop' ); | |
function my_custom_loop() { |
View rsync command with multiple exclusions
rsync -arv --exclude="*.git" --exclude=".svn" source/ /destination/ |
View QandD.css
@media only screen and (max-width: 1139px) { | |
.site-header .widget-area { | |
width: 600px; | |
} | |
.genesis-nav-menu a { | |
padding: 40px 7px 20px; | |
} |
View mangled-htaccess
# # BEGIN WordPres<I<IfModule mod_rewrite.cReRewriteEngine OReRewriteBase ReRewriteRule ^index\.php$ - [LReRewriteCond %{REQUEST_FILENAME} !-ReRewriteCond %{REQUEST_FILENAME} !-RewriteRule . /index.php [L] | |
</IfModule> | |
# END WordPress | |
s | |
View custom_comments.php
<?php | |
// Customized the comment form fields ( not the comment text area ) | |
add_filter('comment_form_default_fields', 'my_comment_form_args'); | |
// Customizes the text area - you have to do this here, rather than in comment_form_default_fields | |
add_filter('comment_form_field_comment', 'my_comment_form_field_comment'); | |
// Customized the comment notes above the form fields | |
add_filter( 'comment_form_defaults', 'my_comment_form_defaults' ); |
View if_exists.php
<?php | |
if ( function_exists( 'function_name' ) ) { | |
//... do something ... | |
} | |
if ( class_exists( 'Class_Name' ) ) { |
NewerOlder