Skip to content

Instantly share code, notes, and snippets.


Renato Alves renatonascalves

Block or report user

Report or block renatonascalves

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
renatonascalves / wordpress-embed-sample-urls.json
Created Aug 12, 2019 — forked from kevinfodness/wordpress-embed-sample-urls.json
A data file containing sample URLs for WordPress oEmbed or Gutenberg Embed block testing (credit to for some of these)
View wordpress-embed-sample-urls.json
"provider": "Amazon Kindle",
"url": ""
"provider": "Animoto",
"url": ""
renatonascalves / postmark-split-wp-mail.php
Created Aug 1, 2019 — forked from danielbachhuber/postmark-split-wp-mail.php
Splits wp_mail() with more than 40 bcc into multiple batches
View postmark-split-wp-mail.php
* Splits a wp_mail() call with more than 40 bcc
* headers into multiple batches.
* Postmark only accepts 50 bcc, so this ensures the API call doesn't fail.
* @param array $args Original arguments passed to wp_mail().
* @return
renatonascalves / bp-custom.php
Created Jul 12, 2019 — forked from imath/bp-custom.php
Registering REST Fields for the BP REST API
View bp-custom.php
// Registers a REST field for the Activity Endpoints.
function example_register_activity_rest_field() {
'activity', // Id of the BuddyPress component the REST field is about
'example_field', // Used into the REST response/request
'get_callback' => 'example_get_rest_field_callback', // The function to use to get the value of the REST Field
'update_callback' => 'example_update_rest_field_callback', // The function to use to update the value of the REST Field
renatonascalves / is_rest.php
Created Jun 10, 2019 — forked from matzeeable/is_rest.php
Checks if the current request is a WP REST API request.
View is_rest.php
if (!function_exists('is_rest')) {
* Checks if the current request is a WP REST API request.
* Case #1: After WP_REST_Request initialisation
* Case #2: Support "plain" permalink settings
* Case #3: URL Path begins with wp-json/ (your REST prefix)
* Also supports WP installations in subfolders
renatonascalves / test.php
Created May 24, 2019 — forked from spacedmonkey/test.php
Add gutenberg blocks to WordPress API as json.
View test.php
add_action( 'rest_api_init', function () {
$types = get_post_types(
'show_in_rest' => true,

WordPress Emails

This document lists all the situations where WordPress sends an email, along with how to filter or disable each email.

This is accurate as of WordPress 4.9.

There are a few TODOs left. Please bear with me.

You can’t perform that action at this time.