Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
/**
* Unhook regsitration_form_addons from parent theme on init. Hooking to init because register_form has already been hooked-in
*
* @author Dan Cameron
*/
add_action('init', 'unhook_registration_form_addons');
function unhook_registration_form_addons()
{
remove_action( 'register_form', 'registration_form_addons' );
}
/**
* Add a new registration form element.
*
* @author Dan Cameron
*/
add_action( 'register_form', 'registration_form_addons_new' );
function registration_form_addons_new()
{
?>
<span class="check clearfix">
<input type="checkbox" name="gbs_profile[group-buying-opt-in]" value="TRUE" checked="checked"> <?php _e('Subscribe to our deals.', 'groupbuyingtheme'); ?>
</span>
<?php
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment