WordPress.org

Plugin Directory

Changeset 526358


Ignore:
Timestamp:
04/02/12 18:12:02 (2 years ago)
Author:
dllh
Message:

Add link category deletion.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • empty-blog/trunk/empty-blog.php

    r525737 r526358  
    121121                wp_delete_link( $link->link_id ); 
    122122            } 
     123            $link_cats = get_terms( 'link_category', array( 'hide_empty' => 0 ) ); 
     124            foreach ( $link_cats as $cat ) { 
     125                print sprintf( __( "Link category: %s" ), $cat->name ) . "<br />"; 
     126                wp_delete_term( $cat->term_id, 'link_category' ); 
     127            } 
    123128        }        
    124129        _e( "Blog empty completed." ); 
Note: See TracChangeset for help on using the changeset viewer.