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: Password Reset Removed | |
* Description: Removes the ability for non admin users to change/reset their passwords. | |
* Version: 1.1 | |
* Author: Derek Herman ; Modified by Juliobox (boiteaweb.fr) | |
* Author URI: http://valendesigns.com | |
*/ | |
add_filter( 'show_password_fields', 'baw_prr_i_am_admin' ); | |
add_filter( 'allow_password_reset', 'baw_prr_i_am_admin' ); |
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
add_action( 'add_meta_boxes', 'add_my_box' ); | |
function add_my_box() { | |
add_meta_box( 'mybox', 'My Box !', '_add_my_box', get_post_type() ); | |
} | |
function _add_my_box() { | |
echo 'Ma boite :)'; | |
} |
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
add_action( 'wp_head', 'page_into_contact_form' ); | |
function page_into_contact_form(){ | |
if( is_main_query() && is_page( get_option( 'contact_page_id' ) ){ | |
add_filter( 'the_content', 'content_into_contact_form' ); | |
} | |
} | |
function content_into_contact_form( $content ){ | |
// $content est le contenu par défaut de l'article | |
if( $GLOBALS['post']->ID == get_option( 'contact_page_id' ) ){ |
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
function content_into_contact_form( $content ){ | |
if( $GLOBALS['post']->ID == get_option( 'contact_page_id' ) ){ | |
$content = '[contact-form-7 id="2" title="Contact form 1"]'; | |
} | |
return $content; | |
} |
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
function page_into_contact_form(){ | |
if( is_main_query() && is_page( get_option( 'contact_page_id' ) ){ | |
add_filter( 'the_content', 'content_into_contact_form' ); | |
} | |
} |
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
add_action( 'wp_head', 'page_into_contact_form' ); |
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: Do not load this plugins | |
Description: Do not load this plugins on wp-login.php page | |
Author: Julio Potier | |
*/ | |
add_action( 'muplugins_loaded', 'pre_baw_do_not_load_this_plugin' ); | |
function pre_baw_do_not_load_this_plugin() { | |
if( '/wp-login.php' == $_SERVER['SCRIPT_NAME'] ) { |
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: Forcer des valeurs absolues par sécurité | |
Author: Julio Potier | |
AuthorURI: http://boiteaweb.fr | |
*/ | |
// Forcer l'adresse email admin | |
add_filter( 'option_admin_email', '_option_admin_email' ); | |
function _option_admin_email( $value ) { |
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
add_filter( 'pre_option_image_default_align', '__image_default_align' ); | |
function __image_default_align() { | |
return 'left'; | |
} | |
add_filter( 'pre_option_image_default_link_type', '__image_default_link_type' ); | |
function __image_default_link_type() { | |
return 'none'; | |
} |
OlderNewer