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 | |
remove_filter( 'authenticate', 'wp_authenticate_email_password', 20 ); | |
/** | |
* Disable logging in via email | |
* | |
* Check for and serve an appropriate response to users attempting to sign in with email. | |
* | |
* @param string $user If the user is authenticated. | |
* @param string $username Username or email address. |
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>ǝɯɐɟ ɟo qƃ5˙1 ʎɯ | ssıʇɹɐ pıʌɐp</title> | |
</head> | |
<style type="text/css"> | |
body, iframe { | |
display: block; | |
margin: 0; |
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
/** | |
* Validate Plugin Requirements | |
* | |
* Deactivate the plugin if a minimum set of requirements aren't met. | |
*/ | |
function validate_plugin_requirements() { | |
$exit = false; | |
$reasons = ''; |
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 | |
/** | |
* Thread Embed | |
* | |
* @package threads-embed | |
* @author David Artiss | |
* @license GPL-2.0-or-later | |
* | |
* Plugin Name: Threads Embed | |
* Plugin URI: https://gist.github.com/dartiss/97b7da945b9de709dba8fed5a7f23ede |
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 dismiss_admin_notices() { | |
// Check if the current user is not an administrator. | |
if ( ! current_user_can( 'administrator' ) ) { | |
// Dismiss all admin notices. | |
remove_all_actions( 'admin_notices' ); | |
} | |
} | |
add_action( 'admin_init', 'dismiss_admin_notices' ); |
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
$tocolor = array( | |
'Black' => '#000', | |
'DarkBlue' => '#00008B', | |
'MediumBlue' => '#0000CD', | |
'DarkGreen' => '#006400', | |
'DarkCyan' => '#008B8B', | |
'DeepSkyBlue' => '#00BFFF', | |
'DarkTurquoise' => '#00CED1', | |
'MediumSpringGreen' => '#00FA9A', | |
'SpringGreen' => '#00FF7F', |
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
$tocolor = array( | |
'#000080' => 'Navy', | |
'#008000' => 'Green', | |
'#008080' => 'Teal', | |
'#00FF00' => 'Lime', | |
'#4B0082' => 'Indigo', | |
'#800000' => 'Maroon', | |
'#800080' => 'Purple', | |
'#808000' => 'Olive', | |
'#808080' => 'Gray', |
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 add_mastodon_verification() { | |
?> | |
<link rel="me" href="[your Mastodon profile link]"> | |
<?php | |
} | |
add_action( 'wp_head', 'add_mastodon_verification' ); |
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 | |
/** | |
* Add support for a theme colour | |
*/ | |
function add_theme_colour() { | |
?> | |
<meta name="theme-color" content="#BE702B" media="(prefers-color-scheme: light)"> | |
<meta name="theme-color" content="#333333" media="(prefers-color-scheme: dark)"> | |
<?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
/** | |
* Admin menu changes | |
*/ | |
function add_menus() { | |
if ( class_exists( 'Jetpack' ) ) { | |
add_action( 'jetpack_admin_menu', 'add_jetpack_menu' ); | |
} | |
} |
NewerOlder