Skip to content

Instantly share code, notes, and snippets.

View sheabunge's full-sized avatar
😴

Shea Bunge sheabunge

😴
View GitHub Profile
@sheabunge
sheabunge / sunrise.php
Created November 7, 2012 20:01 — forked from chrisguitarguy/sunrise.php
A `sunrise.php` drop in that (mostly) allows custom domains in WordPress multisite. Still needs some more work, but it gets the job done.
<?php
/**
* A sunrise.php drop in that allows you to use WordPress' built in `domain`
* and `path` settings for MultiSite blogs.
*
* Some limitations:
* - Using this with a MS install and paths (not subdomains) does some
* weird stuff when updating `siteurl` and `home` while updating domain.
* So you'll you'll have to update those separately. There are probably
* filters to fix this.
@sheabunge
sheabunge / helloworld.bat
Created October 1, 2012 10:09
How to print or output the text Hello World! in many different languages. Feel free to fork and contribute. http://bungeshea.com/2011/hello-world/
@echo Hello World!
@pause
@sheabunge
sheabunge / google-search-form.html
Created October 1, 2012 09:58
Add a Google Search form to your website
<!--
See: http://bungeshea.com/easy-google-search-form/
Remember to replace 'example.com' with the domain of your site.
-->
<form action="http://www.google.com/search" method="get">
<input type="hidden" name="q" value="site:http://example.com">
<input type="text" name="q" alt="search">
<input type="submit" value="Search">
</form>
@sheabunge
sheabunge / rememeber-me-checked.php
Last active October 11, 2015 05:37
Automatically checks the "Remember Me" box on the WordPress login page
<?php
/**
* Plugin Name: Remember Me Checked
* Plugin URI: http://bungeshea.com/remember-me-checked/
* Description: Automatically checks the "Remember Me" box on the WordPress login page
* Author: Shea Bunge
* Author URI: http://bungeshea.com
* Version: 1.0
*/
@sheabunge
sheabunge / shortcode-exists.php
Last active June 28, 2017 04:29 — forked from r-a-y/shortcode.php
Check if a shortcode exists in WordPress
<?php
if ( ! function_exists( 'shortcode_exists' ) ) :
/**
* Check if a shortcode is registered in WordPress.
*
* Examples: shortcode_exists( 'caption' ) - will return true.
* shortcode_exists( 'blah' ) - will return false.
*
* @param string $shortcode The name of the shortcode to check