Skip to content

Instantly share code, notes, and snippets.

View renventura's full-sized avatar

Ren Ventura renventura

View GitHub Profile
@MichaelCurrin
MichaelCurrin / install_ruby_bundler_project_jekyll.md
Last active January 31, 2024 18:37
Set up Ruby, Bundler and a project-level Jekyll on macOS Catalina and up

Set up Jekyll environment on macOS

Set p Ruby, Bundler and a project-level Jekyll on macOS Catalina and up

This guide is for macOS Catalina and is based on the Jekyll on macOS doc and my experience.

1. Install dev tools

Use the XCode CLI to install dev tools. Recommended so that you can install native extensions when installing gems.

@amboutwe
amboutwe / yoast_seo_title_change-variable.php
Last active May 23, 2022 17:09
Change existing or add custom title or meta template variables
<?php
/********* DO NOT COPY THE PARTS ABOVE THIS LINE *********/
/* Remove Yoast SEO Change existing title or meta template variable
* Credit: Moshe Harush
* https://stackoverflow.com/questions/36281915/yoast-seo-how-to-create-custom-variables
* Last Tested: Unknown
*/
// define the wpseo_replacements callback
function filter_wpseo_replacements( $replacements ) {
@stefanbuck
stefanbuck / upload-github-release-asset.sh
Last active November 26, 2023 12:40
Script to upload a release asset using the GitHub API v3.
#!/usr/bin/env bash
#
# Author: Stefan Buck
# License: MIT
# https://gist.github.com/stefanbuck/ce788fee19ab6eb0b4447a85fc99f447
#
#
# This script accepts the following parameters:
#
# * owner
@devinsays
devinsays / jetpack.php
Last active July 26, 2022 12:36
Query by JetPack Related Posts
<?php
/**
* Prevents Related Posts from displaying in content area
*/
function prefix_remove_rp() {
if ( class_exists( 'Jetpack_RelatedPosts' ) ) {
$jprp = Jetpack_RelatedPosts::init();
$callback = array( $jprp, 'filter_add_target_to_dom' );
remove_filter( 'the_content', $callback, 40 );
}
@johnbillion
johnbillion / wp_mail.md
Last active January 27, 2024 14:06
WordPress Emails

WordPress Emails

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

@neilgee
neilgee / homeloop.php
Last active December 6, 2018 19:19
Custom Genesis Home Loop with Character Limitation on Excerpt
<?php
//do not add in opening php tag
/**
* Custom Genesis Home Loop with Character Limitation on Excerpt
*
* @package Custom Genesis Home Loop with Character Limitation on Excerpt
* @author Neil Gee
* @link https://wpbeaches.com/custom-genesis-standard-loop-blog-page/
* @copyright (c)2014, Neil Gee
@neilgee
neilgee / git.css
Last active December 7, 2023 02:08
Git Command Line Reference - Notes, Cheatsheet and reminders on Git set up and commands
/*
* Set up your Git configuration
*/
git config --global user.email "you@yourdomain.com"
git config --global user.name "Your Name"
git config --global core.editor "nano"
@paulund
paulund / example-wp-list-table.php
Last active March 31, 2024 05:40
An example code of using the WP_List_Table class. With Pagination.
<?php
/*
* Plugin Name: Paulund WP List Table Example
* Description: An example of how to use the WP_List_Table class to display data in your WordPress Admin area
* Plugin URI: http://www.paulund.co.uk
* Author: Paul Underwood
* Author URI: http://www.paulund.co.uk
* Version: 1.0
* License: GPL2
*/
@charleslouis
charleslouis / custom-search-acf-wordpress.php
Last active December 15, 2023 09:11
PHP - Wordpress - Search - wordpress custom search function that encompasses ACF/advanced custom fields and taxonomies and split expression before request
<?php
/**
* [list_searcheable_acf list all the custom fields we want to include in our search query]
* @return [array] [list of custom fields]
*/
function list_searcheable_acf(){
$list_searcheable_acf = array("title", "sub_title", "excerpt_short", "excerpt_long", "xyz", "myACF");
return $list_searcheable_acf;
}
@adamloving
adamloving / temporary-email-address-domains
Last active April 24, 2024 14:20
A list of domains for disposable and temporary email addresses. Useful for filtering your email list to increase open rates (sending email to these domains likely will not be opened).
0-mail.com
0815.ru
0clickemail.com
0wnd.net
0wnd.org
10minutemail.com
20minutemail.com
2prong.com
30minutemail.com
3d-painting.com