Title: Removing orphan shortcodes
Last modified: November 1, 2016

---

# Removing orphan shortcodes

 *  [xopox](https://wordpress.org/support/users/xopox/)
 * (@xopox)
 * [9 years, 6 months ago](https://wordpress.org/support/topic/removing-orphan-shortcodes/)
 * Hi,
 * I want to remove all orphan shortcodes from my WP, mainly the WPG2 (Gallery2)
   shortcodes.
 * I have a lot of entries with this, so i tried to search and replace with regEx
   with some plugins but i can’t do.
 * My shortcodes is like this:
 * <wpg2>3223523523523</wpg2>
 * Any suggestion to massively remove? Thanks

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Moderator [cubecolour](https://wordpress.org/support/users/numeeja/)
 * (@numeeja)
 * [9 years, 6 months ago](https://wordpress.org/support/topic/removing-orphan-shortcodes/#post-8382241)
 * If you have uninstalled the plugin that processes the shortcodes, you can redefine
   the shortcode to output nothing by using a function that returns without outputting
   anything either in your functions.php or a custom plugin. eg:
 *     ```
       function cc_dummy_shortcode_wpg2() {
       	return;
       }
       add_shortcode( 'wpg2', 'cc_dummy_shortcode_wpg2' );
       ```
   
 * The example function above should work for any `[wpg2]` shortcode, including `[
   wpg2]3223523523523[/wpg2]`, however there would be a problem if your site really
   uses the angle bracket syntax you have shown in your example as this does not
   use square brackets so is not actually a shortcode.
    -  This reply was modified 9 years, 6 months ago by [cubecolour](https://wordpress.org/support/users/numeeja/).
 *  Thread Starter [xopox](https://wordpress.org/support/users/xopox/)
 * (@xopox)
 * [9 years, 6 months ago](https://wordpress.org/support/topic/removing-orphan-shortcodes/#post-8382245)
 * Hi cubecolour, thanks for your reply.
 * Yes, as you can said, wpg2 uses square brackets and not angle bracket syntax 
   🙁

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Removing orphan shortcodes’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 2 replies
 * 2 participants
 * Last reply from: [xopox](https://wordpress.org/support/users/xopox/)
 * Last activity: [9 years, 6 months ago](https://wordpress.org/support/topic/removing-orphan-shortcodes/#post-8382245)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
