Skip to content

Instantly share code, notes, and snippets.

View atcraigwatson's full-sized avatar

Craig Waton atcraigwatson

  • Watson Memorials
  • United Kingdom
  • 18:50 (UTC)
View GitHub Profile
@hmbashar
hmbashar / change_reg_message.php
Created February 6, 2019 01:52
Change WordPress’ Default “Register For This Site” Message To Your Own Custom Text
function change_reg_message($message)
{
// change messages that contain 'Register'
if (strpos($message, 'Register') !== FALSE) {
$newMessage = "Hello! We're so excited to have you as a member! Just enter a username and your email, and we'll have you squared away in no time.";
return '<p class="message register">' . $newMessage . '</p>';
}
else {
return $message;
}
@salcode
salcode / .gitignore
Last active July 10, 2024 14:28
Please see https://salferrarello.com/wordpress-gitignore/ for the canonical version of this WordPress .gitignore file. Note: I do not receive notifications for comments here (because GitHub does not send notifications on Gists)
# -----------------------------------------------------------------
# .gitignore for WordPress @salcode
# ver 20180808
#
# From the root of your project run
# curl -O https://gist.githubusercontent.com/salcode/b515f520d3f8207ecd04/raw/.gitignore
# to download this file
#
# By default all files are ignored. You'll need to whitelist
# any mu-plugins, plugins, or themes you want to include in the repo.
/** Force full width layout on single posts only*/
add_filter( 'genesis_pre_get_option_site_layout', 'full_width_layout_single_posts' );
/**
* @author Brad Dalton
* @link http://wpsites.net/web-design/change-layout-genesis/
*/
function full_width_layout_single_posts( $opt ) {
if ( is_singular( 'post' ) ) {
$opt = 'full-width-content';
return $opt;