• Great Plugin!

    The following code could find and list all registered Custom Post types and Taxonomies. The list could be automatically added to “Where to show this template” area.

    If you could supply the code, in your plugin, for the “input name=”wpsr_template” fields, the groups could be disabled by custom post types and Taxonomies.

    This would be very helpful instead of turning off on individual posts and pages.

    <?php
    foreach ( get_post_types( array( '_builtin' => false, 'public' => true ), 'objects' ) as $posttype ) {
    echo '<label><input name="wpsr_template" type="checkbox" value="1" />';
    echo ' <span id="' . esc_attr( $name ) . '">' . esc_html( ucfirst( $posttype->labels->name ) ) . '</span></label><br/>';
    }
    ?>
    
    <?php
    foreach ( get_taxonomies( array( '_builtin' => false, 'public' => true), 'objects' ) as $tax ) {
    echo '<label><input name="wpsr_template" type="checkbox" value="1" />';
    echo ' <span>' . esc_html( ucfirst( $tax->labels->name ) ) . '</span></label><br/>';
    }
    ?>

    http://wordpress.org/plugins/wp-socializer/

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘Feature Request For Custom Post Types and Taxonomies’ is closed to new replies.