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 | |
// register the custom post type widget area | |
genesis_register_sidebar( array( | |
'id' => 'cpt-archive-sidebar', | |
'name' => __( 'Custom Post Type Sidebar' ), | |
'description' => __( 'Display this sidebar on your custom post type archive page.' ), | |
) ); | |
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 if(is_single() ) { ?> | |
SHARETHIS CODE HERE | |
<?php } ?> |
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 | |
/** | |
* Plugin Name: Cache Post Thumbnails | |
* Description: Prime the post thumbnails cache for individual loops. | |
* Version: 1.0.0 | |
* Author: Brady Vercher | |
* Author URI: http://www.blazersix.com/ | |
* License: GPL-2.0+ | |
* License URI: http://www.gnu.org/licenses/gpl-2.0.html | |
*/ |
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
#Clinic workflow at codecademy | |
def clinic(): | |
print "You've just entered the clinic!" | |
print "Do you take the door on the left or the right?" | |
answer = raw_input("Type left or right and hit 'Enter'.").lower() | |
if answer == "left" or answer == "l": | |
print "This is the Verbal Abuse Room, you heap of parrot droppings!" | |
elif answer == "right" or answer == "r": | |
print "Of course this is the Argument Room, I've told you that already!" |
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
# Create comparative statements as appropriate on the lines below! | |
# Make me true! | |
bool_one = 3 < 5 # We already did this one for you! | |
# Make me false! | |
bool_two = 3 > 5 | |
# Make me true! | |
bool_three = 4+1 == 5 |
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
# Create a filter called 'apache-wp-login' | |
[Definition] | |
failregex = <HOST>.*] "POST /wp-login.php HTTP/.*" 200 | |
ignoreregex = | |
[INCLUDES] | |
before = apache-common.conf | |
# Create a jail | |
[wp-login] |
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
# BEGIN Ban Users | |
# Begin HackRepair.com Blacklist | |
if ($http_user_agent ~* "^[Ww]eb[Bb]andit"){ return 403; } | |
if ($http_user_agent ~* "^binlar"){ return 403; } | |
if ($http_user_agent ~* "^BlackWidow"){ return 403; } | |
if ($http_user_agent ~ "^Bolt"){ return 403; } | |
if ($http_user_agent ~* "^casper"){ return 403; } | |
if ($http_user_agent ~* "^ChinaClaw"){ return 403; } | |
if ($http_user_agent ~* "^cmsworldmap"){ return 403; } | |
if ($http_user_agent ~* "^comodo"){ return 403; } |