Skip to content

Instantly share code, notes, and snippets.

View WordPress Debug wp-config.php addon
* For developers: WordPress debugging mode.
* Change this to true to enable the display of notices during development.
* It is strongly recommended that plugin and theme developers use WP_DEBUG
* in their development environments.
if (!defined('WP_DEBUG')) {
define('WP_DEBUG', true);
define( 'WP_DEBUG_DISPLAY', false );
nocean / language-independent-acf-theme-options-output.php
Last active Aug 9, 2018 — forked from senlin/language-independent-acf-theme-options-output.php
How to get language independent ACF theme options on a WPML site
View language-independent-acf-theme-options-output.php
* To get this to work, you need to tinker with the acf/settings/ filter and reset the default language
* so that the get_field() function returns the correct results even when not on the default language.
* You can add the filter before you call the get_field() function and then remove it once complete.
* answer courtesy of James of ACF Support + love on GitHub
View oldie-redirect.js
OLDIE - or Old IE. A script that finds the version of IE you're using,
and redirects if lower than the set parameter.
[[ Created by Ryan McLaughlin, ]]
var browser = navigator.appName
var ver = navigator.appVersion
var thestart = parseFloat(ver.indexOf("MSIE"))+1 //This finds the start of the MS version string.
var brow_ver = parseFloat(ver.substring(thestart+4,thestart+7)) //This cuts out the bit of string we need.
View oldie-redirect.html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "">
<html xmlns="">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Browser Version Not Supported</title>
<body style="text-align:center;">
<div style="margin:30px auto;border:1px solid #333;padding:10px;text-align:left;width:550px;background:#FFFFCC;">
<h2 style="font-variant:small-caps;">Your browser seems out of date!</h2>
View cf7-honeypot-override-filter
function my_honeypot_override( $html, $args ) {
return $html;
add_filter('wpcf7_honeypot_html_output', 'my_honeypot_override', 10, 2 );
nocean / 0_reuse_code.js
Last active Aug 29, 2015
Here are some things you can do with Gists in GistBox.
View 0_reuse_code.js
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console