Title: Features
Last modified: October 18, 2018

---

# Features

 *  Resolved [luhmanr](https://wordpress.org/support/users/luhmanr/)
 * (@luhmanr)
 * [7 years, 7 months ago](https://wordpress.org/support/topic/features-58/)
 * I am looking for a plugin that would allow me to run a shortcode from a button,
   a hyperlink or a menu item. Does this plugin supply the functionality?

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

 *  Plugin Author [Vova](https://wordpress.org/support/users/gn_themes/)
 * (@gn_themes)
 * [7 years, 7 months ago](https://wordpress.org/support/topic/features-58/#post-10793100)
 * Hi [@luhmanr](https://wordpress.org/support/users/luhmanr/),
 * have you seen my [previous reply](https://wordpress.org/support/topic/create-shortcodes/#post-10789955)?
   That code allows you to run a shortcode using a dropdown list. The same could
   be applied to links/buttons.
 * This plugin does not allow running shortcodes using links.
 *  Thread Starter [luhmanr](https://wordpress.org/support/users/luhmanr/)
 * (@luhmanr)
 * [7 years, 7 months ago](https://wordpress.org/support/topic/features-58/#post-10793133)
 * I did see your previous reply but after spending several hours I could not get
   it to work.
 *  Plugin Author [Vova](https://wordpress.org/support/users/gn_themes/)
 * (@gn_themes)
 * [7 years, 7 months ago](https://wordpress.org/support/topic/features-58/#post-10793457)
 * In such cases, people usually share their results.
 *  Thread Starter [luhmanr](https://wordpress.org/support/users/luhmanr/)
 * (@luhmanr)
 * [7 years, 7 months ago](https://wordpress.org/support/topic/features-58/#post-10793767)
 * So the previous code you mentioned puts the shortcode information in the address
   bar.
 * <form action=”/page-2″ method=”get”>
    <select name=”my_action”> <option value
   =”action-1″>Action 1</option> <option value=”action-2″>Action 1</option> </select
   > </form> At page-2, or within your custom shortcode, added to page-2: if ( isset(
   $_GET[‘my_action’] ) ) { $action = sanitize_key( $_GET[‘my_action’] ); if ( ‘
   action-1’ === $action ) { do_stuff(); } }
 * [http://wp.thename.com/page-2/?my_action=%255Bgallery+type%253D%2527smugmug%2527+view%253D%2527album%2527+album%253D%25277tPbqC%2527+nick_name%253D%2527thename%2527+sort_order%253D%2527Descending%2527+sort_method%253D%2527DateTaken%2527+count%253D%2527100%2527+more%253D%2527More%2527+layout%253D%2527mosaic%2527+album_sort_order%253D%2527Album+Settings%2527+columns%253D%25278%2527+title_position%253D%2527below%2527+popup%253D%2527hide%2527%255D](http://wp.thename.com/page-2/?my_action=%255Bgallery+type%253D%2527smugmug%2527+view%253D%2527album%2527+album%253D%25277tPbqC%2527+nick_name%253D%2527thename%2527+sort_order%253D%2527Descending%2527+sort_method%253D%2527DateTaken%2527+count%253D%2527100%2527+more%253D%2527More%2527+layout%253D%2527mosaic%2527+album_sort_order%253D%2527Album+Settings%2527+columns%253D%25278%2527+title_position%253D%2527below%2527+popup%253D%2527hide%2527%255D)
 *  Plugin Author [Vova](https://wordpress.org/support/users/gn_themes/)
 * (@gn_themes)
 * [7 years, 7 months ago](https://wordpress.org/support/topic/features-58/#post-10793819)
 * Now, create a custom shortcode to handle that URL. Put the following code to 
   the end of the functions.php file of your active theme:
 *     ```
       add_shortcode( 'handle_my_action', function( $atts = null, $content = null ) {
         if ( ! isset( $_GET['my_action'] ) ) {
           return;
         }
   
         $my_action = wp_kses_data( $_GET['my_action'] );
   
         // Now you can do whatever you want with the value
         // You can even call another shortcode
         return do_shortcode( '[someshortcode value="' . $my_action . '"]' );
       } );
       ```
   
 * Then add the following shortcode to page-2: `[handle_my_action]`.
 * Is this what you were looking for?
 *  Thread Starter [luhmanr](https://wordpress.org/support/users/luhmanr/)
 * (@luhmanr)
 * [7 years, 7 months ago](https://wordpress.org/support/topic/features-58/#post-10794249)
 * It seems that you have gotten me real close. The result viewed on the page-2 
   is:
 * [someshortcode value=”%5Bgallery type%3D%27smugmug%27 view%3D%27album%27 album%
   3D%277tPbqC%27 nick_name%3D%27myname%27 sort_order%3D%27Descending%27 sort_method%
   3D%27DateTaken%27 count%3D%27100%27 more%3D%27More%27 layout%3D%27mosaic%27 album_sort_order%
   3D%27Album Settings%27 columns%3D%278%27 title_position%3D%27below%27 popup%3D%
   27hide%27%5D”]
 * Rather than an executed
 * [gallery type='smugmug' view='album' album='7tPbqC' nick_name='myname' sort_order
   ='Descending' sort_method='DateTaken' count='100' more='More' layout='mosaic'
   album_sort_order='Album Settings' columns='8' title_position='below' popup='hide']
 *  Plugin Author [Vova](https://wordpress.org/support/users/gn_themes/)
 * (@gn_themes)
 * [7 years, 7 months ago](https://wordpress.org/support/topic/features-58/#post-10799037)
 * This topic is related to PHP functionality, rather than Shortcodes Ultimate. 
   You should post your question at StackOverflow or somewhere else.

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

The topic ‘Features’ is closed to new replies.

 * ![](https://ps.w.org/shortcodes-ultimate/assets/icon-256x256.gif?rev=2547563)
 * [Shortcodes Ultimate - Content Elements](https://wordpress.org/plugins/shortcodes-ultimate/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/shortcodes-ultimate/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/shortcodes-ultimate/)
 * [Active Topics](https://wordpress.org/support/plugin/shortcodes-ultimate/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/shortcodes-ultimate/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/shortcodes-ultimate/reviews/)

 * 7 replies
 * 2 participants
 * Last reply from: [Vova](https://wordpress.org/support/users/gn_themes/)
 * Last activity: [7 years, 7 months ago](https://wordpress.org/support/topic/features-58/#post-10799037)
 * Status: resolved