This file contains hidden or 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 | |
| function reassign_post_on_delete_user($user_id) { | |
| global $wpdb; | |
| // Replace the following with whatever ID you want to reassign to | |
| $replacement_id = 1; | |
| $post_ids = $wpdb->get_col($wpdb->prepare("SELECT ID FROM {$wpdb->posts} WHERE post_author = %d", $user_id)); | |
| $wpdb->update($wpdb->posts, array('post_author' => $replacement_id), array('post_author' => $user_id)); |
This file contains hidden or 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 | |
| function registered_users_only_comment_feed_where($where, $query) { | |
| return $where . " AND user_id > 0"; | |
| } | |
| add_filter('comment_feed_where', 'registered_users_only_comment_feed_where', 10, 2); |
This file contains hidden or 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: Ridiculously Naive Image Protection | |
| Description: Enables ridiculously naive image protection. Disables contextmenu and dragstart on images using jQuery's event handling. That's it! | |
| Version: 1.0.0.B.1 | |
| Author: Nick Ohrn | |
| Author URI: http://nickohrn.com/ | |
| */ | |
| function image_protector_wp_enqueue_scripts() { |
This file contains hidden or 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 | |
| /* | |
| Template Name: Fuel Landing Page | |
| */ | |
| get_header(); | |
| $fuel_options = get_option('fuel_theme_options'); | |
| ?> | |
| <div id="pageWrap"> | |
| <h1 class="pageTitle alt_font fademe"><span>Fuel</span> Network</h1> | |
NewerOlder