- Install and activate the
smtp-config.phpfile as a plugin or drop it in/mu-plugins. - Define the necessary constants in
wp-config.php.
| /** | |
| * Revised by Charles Johnson - https://github.com/GreenFootballs | |
| * | |
| * Runs automatically at window.onload(), searches document for iframes with a class of "mastodon-embed" | |
| * and resizes them to fit the content, using window.postMessage() to get the content height from the | |
| * embedded page. | |
| * | |
| * Adds an object named "_mastodonTools" to the window element, with an "embed" method. | |
| * | |
| * To resize dynamically added Mastodon iframes, call "_mastodonTools.embed(container, callback)" |
| # -*- mode: ruby -*- | |
| # vi: set ft=ruby ts=2 sw=2 et: | |
| # Add github to known hosts for private repo provisioners | |
| config.vm.provision "shell", run: "always" do |s| | |
| s.inline = <<-SHELL | |
| mkdir -p ~/.ssh | |
| chmod 700 ~/.ssh | |
| touch ~/.ssh/known_hosts | |
| if ! grep -Fxq "github.com" ~/.ssh/known_hosts; then |
| /** | |
| * Configure PHPMailer to send via PHP's mail() | |
| * | |
| * @param PHPMailer $phpmailer | |
| */ | |
| function phpmailer_send_via_mail( $phpmailer ) { | |
| $phpmailer->IsMail(); | |
| } | |
| add_action( 'phpmailer_init', 'phpmailer_send_via_mail', 999 ); |
| <?php | |
| /* | |
| * Plugin Name: Remove crazy counts slowing down my dashboard | |
| * Plugin URI: https://pmgarman.me | |
| * Description: Those comment counts are such a pain when you have a lot of comments | |
| * Author: Patrick Garman | |
| * Author URI: https://pmgarman.me | |
| * Version: 1.0.0 | |
| * License: GPLv2 | |
| */ |
| <?php | |
| /** | |
| * Add featured image url to api response | |
| * This will (hopefully) be unnecessary if the API team adds it to core | |
| * | |
| */ | |
| add_action( 'rest_api_init', 'sb_register_featured_urls' ); | |
| function sb_register_featured_urls() { | |
| register_api_field( 'post', |
| <?php | |
| /** | |
| * Make an internal REST request | |
| * | |
| * @global WP_REST_Server $wp_rest_server ResponseHandler instance (usually WP_REST_Server). | |
| * @param $request_or_method WP_REST_Request|string A WP_REST_Request object or a request method | |
| * @param $path (optional) if the path is not specific in the rest request, specify it here | |
| * @param $data (optional) option data for the request. | |
| * @return WP_Error|mixed |
Custom recipe to get OS X 10.11 El Capitan running from scratch, setup applications and developer environment. This is very similar (and currently mostly the same) as my 10.10 Yosemite setup recipe (as found on this gist https://gist.github.com/kevinelliott/0726211d17020a6abc1f). Note that I expect this to change significantly as I install El Capitan several times.
I use this gist to keep track of the important software and steps required to have a functioning system after a semi-annual fresh install. On average, I reinstall each computer from scratch every 6 months, and I do not perform upgrades between distros.
This keeps the system performing at top speeds, clean of trojans, spyware, and ensures that I maintain good organizational practices for my content and backups. I highly recommend this.
You are encouraged to fork this and modify it to your heart's content to match your own needs.
| <?php | |
| /** | |
| * Plugin Name: WP REST API Batch Requests | |
| * Description: Enabled a multi / batch requests endpoint for the WP RES API | |
| * Author: Joe Hoyle | |
| * Version: 1.0-alpha1 | |
| * Plugin URI: https://github.com/WP-API/WP-API | |
| * License: GPL2+ | |
| */ |