This document lists all the situations where WordPress sends an email, along with how to filter or disable each email.
This documentation has moved here: https://github.com/johnbillion/wp_mail
| // This code is licensed under the MIT License | |
| // Copyright (c) MKRhere (https://mkr.pw) | |
| import { MessageEntity } from '@telegraf/types' | |
| import { FmtString } from './formatting' | |
| interface EntityCompare { | |
| offset: number | |
| length: number | |
| } |
| <?php | |
| /** | |
| * READING TIME | |
| * | |
| * Calculate an approximate reading-time for a post. | |
| * | |
| * @param string $content The content to be measured. | |
| * @return integer Reading-time in seconds. | |
| */ | |
| function reading_time( $content ) { |
| FROM nginx:alpine | |
| COPY default.conf /etc/nginx/conf.d/. |
| /* | |
| https://www.smashingmagazine.com/2016/07/improving-user-flow-through-page-transitions/ | |
| You can copy paste this code in your console on smashingmagazine.com | |
| in order to have cross-fade transition when change page. | |
| */ | |
| var cache = {}; | |
| function loadPage(url) { | |
| if (cache[url]) { |
This document lists all the situations where WordPress sends an email, along with how to filter or disable each email.
This documentation has moved here: https://github.com/johnbillion/wp_mail
| function register_watermarked_size() { | |
| add_image_size( 'watermarked', 550, 550, true ); // This is what should be uploaded | |
| } | |
| add_action( 'init', 'register_watermarked_size' ); | |
| class Watermark_Image { | |
| // The attachment meta array | |
| public $meta = array(); |
| <?php | |
| /* | |
| WordPress Theme Template Hierarchy Last updated for WordPress 5.4 | |
| ================================== | |
| This diagram is partially simplified for legibility. To view the complete template hierarchy in use on your site see the | |
| Template panel in the Query Monitor plugin. |
| /** | |
| * Prevent click events after a touchend. | |
| * | |
| * Inspired/copy-paste from this article of Google by Ryan Fioravanti | |
| * https://developers.google.com/mobile/articles/fast_buttons#ghost | |
| * | |
| * USAGE: | |
| * Prevent the click event for an certain element | |
| * ```` | |
| * PreventGhostClick(myElement); |
| <?php | |
| // Option 1: the follow method immediately references the relationship and saves it. | |
| class User extends Eloquent { | |
| public function follows() | |
| { | |
| return $this->belongsToMany(self::class, 'follows', 'follower_id', 'followed_id'); | |
| } |