Title: php do_shortcode
Last modified: August 21, 2016

---

# php do_shortcode

 *  [amobaroti](https://wordpress.org/support/users/amobaroti/)
 * (@amobaroti)
 * [13 years ago](https://wordpress.org/support/topic/php-do_shortcode/)
 * I am using this plugin nuvuglide is a third party woocommerce plugin. I want 
   to hard code it on the home page this is the code that the plugin author says
   to use
 * ‘<?php do_shortcode(‘[nuvuglide type=”post” order=”ASC” order_by=’name’ show_excerpt
   =”true” show_date=”true” show_title=”true” show_gallery=”true” num_images=”4″]’);?
   >’
 * i get this error Parse error: syntax error, unexpected T_STRING in /home/bessobar/
   public_html/veeandjade.com/wp-content/themes/mystile-child/index.php on line 
   36
 * I’ve tried
 * ‘<?php echo do_shortcode(‘[nuvuglide type=”post” order=”ASC” order_by=’name’ 
   show_excerpt=”true” show_date=”true” show_title=”true” show_gallery=”true” num_images
   =”4″ ]’); ?>’
 * I tried double quotes instead of single and it doesn’t seem to make a difference.
 * I’ve also tried
 * ‘echo apply_filters( ‘the_content’,’ [nuvuglide] ‘);’
 * none of which works.
 * Any ideas where I could be going wrong please

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

 *  [Michael](https://wordpress.org/support/users/alchymyth/)
 * (@alchymyth)
 * [13 years ago](https://wordpress.org/support/topic/php-do_shortcode/#post-3783105)
 * change these quotes to double quotes:
 * `order_by='name'`
 * if this does not help:
 * – generally, make sure not to violate any php syntax.
    – please post the code
   in the context of the full template; use the pastebin [http://codex.wordpress.org/Forum_Welcome#Posting_Code](http://codex.wordpress.org/Forum_Welcome#Posting_Code)
 *  Thread Starter [amobaroti](https://wordpress.org/support/users/amobaroti/)
 * (@amobaroti)
 * [13 years ago](https://wordpress.org/support/topic/php-do_shortcode/#post-3783108)
 * I though I did that and got an error, but what do you know I did it again and
   it’s work.
 * cheers
 *  Thread Starter [amobaroti](https://wordpress.org/support/users/amobaroti/)
 * (@amobaroti)
 * [13 years ago](https://wordpress.org/support/topic/php-do_shortcode/#post-3783110)
 * Well it’s working using this code
 * ‘ <?php do_shortcode(‘[nuvuglide type=”post” order=”ASC” order_by=”name” show_excerpt
   =”true” show_date=”true” show_title=”true” show_gallery=”true” num_images=”4″]’);?
   >’
 * It does not work if you use “echo” or have double quotes around the short code
   and args.
 *  Thread Starter [amobaroti](https://wordpress.org/support/users/amobaroti/)
 * (@amobaroti)
 * [13 years ago](https://wordpress.org/support/topic/php-do_shortcode/#post-3783111)
 * noted re: pastebin

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

The topic ‘php do_shortcode’ is closed to new replies.

## Tags

 * [Parse error: syntax error](https://wordpress.org/support/topic-tag/parse-error-syntax-error/)
 * [shortcode](https://wordpress.org/support/topic-tag/shortcode/)

 * 4 replies
 * 2 participants
 * Last reply from: [amobaroti](https://wordpress.org/support/users/amobaroti/)
 * Last activity: [13 years ago](https://wordpress.org/support/topic/php-do_shortcode/#post-3783111)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
