- Assumes "Anyone can register" is checked on wp-admin/options-general.php
- Create a code by creating a post at wp-admin/edit.php?post_type=invite_codes with the code in the title
- When a user registers at wp-login.php?action=register, they must provide a valid code. Code validation is fully dependent on
get_page_by_title
, so there is some loose matching - When a code is succuessfully used, the code "post" will be marked as 'draft', and post meta will be added indicating who used it.
- Disabling the
wp_update_post
section will allow codes to be reused until manually marked as 'draft'
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$namedcolors = array( 'AliceBlue', 'AntiqueWhite', 'Aqua', 'Aquamarine', 'Azure', 'Beige', 'Black', 'Blue', 'BlueViolet', 'Brass', 'BrightGold', 'Bronze', 'Brown', 'CadetBlue', 'Chocolate', 'Copper', 'Coral', 'Crimson', 'Cyan', 'DarkBlue', 'DarkBrown', 'DarkCyan', 'DarkGoldenRod', 'DarkGray', 'DarkGreen', 'DarkKhaki', 'DarkMagenta', 'DarkOliveGreen', 'DarkOrange', 'DarkOrchid', 'DarkPurple', 'DarkSalmon', 'DarkSlateBlue', 'DarkSlateGray', 'DarkTan', 'DarkTurquoise', 'DarkViolet', 'DarkWood', 'DimGray', 'DustyRose', 'FeldSpar', 'FireBrick', 'ForestGreen', 'Gold', 'GoldenRod', 'Gray', 'Green', 'GreenCopper', 'GreenYellow', 'HotPink', 'HunterGreen', 'IndianRed', 'Indigo', 'Ivory', 'Khaki', 'Lavender', 'LightBlue', 'LightCoral', 'LightCyan', 'LightGray', 'LightGreen', 'LightPink', 'LightSteelBlue', 'LightWood', 'Lime', 'LimeGreen', 'Magenta', 'MandarinOrange', 'Maroon', 'MediumAquaMarine', 'MediumBlue', 'MediumForestGreen', 'MediumGoldenRod', 'MediumOrchid', 'MediumSeaGreen', 'MediumSlateBlue', 'MediumSpri |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Stand-alone WordPress.org plugin api access | |
$url = 'http://api.wordpress.org/plugins/info/1.0/'; | |
$fields = array( | |
'action' => 'query_plugins', | |
'request' => serialize( (object) array( | |
'author' => 'trepmal', | |
//'search' => 'howdy', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
Plugin Name: User Meta Upload | |
Plugin URI: http://trepmal.com | |
Description: Add a file-upload form to the user edit profile page | |
Version: 0.1 | |
Author: Kailey Lampert | |
Author URI: http://kaileylampert.com | |
Copyright (C) 2012 Kailey Lampert |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
Plugin Name: WPORG Repo Plugins | |
Description: Widget to display plugins on the wordpress.org repository by author | |
Author: Kailey Lampert | |
Author URI: http://kaileylampert.com/ | |
*/ | |
add_action( 'widgets_init', 'register_wporg_repo_plugins' ); | |
function register_wporg_repo_plugins() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
Plugin Name: Include Page Widget | |
Plugin URI: http://trepmal.com/ | |
Description: Widget. Display a page's content. That's it. Fork and adapt! | |
Version: 0.1 | |
Author: Kailey Lampert | |
Author URI: http://kaileylampert.com | |
Copyright (C) 2012 Kailey Lampert |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
Plugin Name: Open Plugin File Locally | |
Plugin URI: http://trepmal.com/ | |
Description: Adds link to plugin list to open plugin files in their default desktop application. http://cl.ly/HFXW Requiments: Mac OSX, WP on localhost | |
Version: 0.1 | |
Author: Kailey Lampert | |
Author URI: http://kaileylampert.com | |
Copyright (C) 2012 Kailey Lampert |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
Plugin Name: Images for Comments | |
Plugin URI: http://trepmal.com/ | |
Description: Replaces plain textarea with one that has media uploader and formatting buttons | |
Version: 1 | |
Author: Kailey Lampert | |
Author URI: http://kaileylampert.com | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
Plugin Name: Remote Login | |
Description: Log into the site with creds that work on remote site (as defined in plugin). The remote site must have XML-RPC enabled. | |
Author: Kailey Lampert | |
Author URI: http://kaileylampert.com/ | |
THIS IS NOT COMPLETE - DO NOT USE IN PRODUCTION | |
The remote site (defined below in $server) is the "master" site. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//Plugin Name: Basic Google Analytics | |
new Basic_Google_Analytics(); | |
class Basic_Google_Analytics { | |
function __construct( ) { | |
add_action( 'admin_init' , array( &$this , 'register_fields' ) ); | |
add_action( 'init' , array( &$this , 'load_after' ) ); | |
} |