Skip to content

Instantly share code, notes, and snippets.

@kovshenin
kovshenin / options.php
Created April 23, 2012 12:12
Reusable Settings API fields
<?php
/**
* Text Field
*
* A simple text field callback to use with the Settings API. Don't forget to pass in
* the arguments array. Here's an example call to add_settings_field() :
*
* add_settings_field( 'my_option', __( 'My Option' ), 'foo_field_text', 'theme_options', 'general', array(
* 'name' => 'my_theme_options[my_option]',
* 'value' => $options['my_option'], // assuming $options is declared
@alexkingorg
alexkingorg / oembed-gist.php
Created August 18, 2011 06:39
Small mod to oEmbed Gist WordPress plugin to add NOSCRIPT support (RSS feeds, etc.).
<?php
/*
Plugin Name: oEmbed gist (AK)
Plugin URI: http://firegoby.theta.ne.jp/wp/oembed-gist
Description: Embed source from gist.github.
Author: Takayuki Miyauchi (THETA NETWORKS Co,.Ltd)
Version: 1.1.0
Author URI: http://firegoby.theta.ne.jp/
*/