Title: Shortcode into PHP, hardcode.
Last modified: August 21, 2016

---

# Shortcode into PHP, hardcode.

 *  [tambovskya](https://wordpress.org/support/users/tambovskya/)
 * (@tambovskya)
 * [12 years, 8 months ago](https://wordpress.org/support/topic/shortcode-into-php-hardcode/)
 * So, I’m trying to put this shortcode into the php as a hardcode, but it’s returning
   with a t-string error.
 * [shortmenu menu=”Header Menu” id=”Shortcode Menu” display=”inline” enhance=”true”]
 * What is the problem?

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

 *  [Michael](https://wordpress.org/support/users/alchymyth/)
 * (@alchymyth)
 * [12 years, 8 months ago](https://wordpress.org/support/topic/shortcode-into-php-hardcode/#post-4195314)
 * generally, to integrate shortcode into a php template, you would use [http://codex.wordpress.org/Function_Reference/do_shortcode](http://codex.wordpress.org/Function_Reference/do_shortcode)
 * what is your exact code?
 *  Thread Starter [tambovskya](https://wordpress.org/support/users/tambovskya/)
 * (@tambovskya)
 * [12 years, 8 months ago](https://wordpress.org/support/topic/shortcode-into-php-hardcode/#post-4195315)
 * <?php echo do_shortcode(‘[shortmenu menu=”Header Menu” id=”Shortcode Menu” display
   =”inline” enhance=”true” ]’); ?>
 *  Thread Starter [tambovskya](https://wordpress.org/support/users/tambovskya/)
 * (@tambovskya)
 * [12 years, 8 months ago](https://wordpress.org/support/topic/shortcode-into-php-hardcode/#post-4195317)
 * I just redone a couple things in my template, and now it works. I have no clue
   what I did wrong before. I think that it was a symbol error. Thank you for providing
   me the link, it fixed my error.

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

The topic ‘Shortcode into PHP, hardcode.’ is closed to new replies.

 * 3 replies
 * 2 participants
 * Last reply from: [tambovskya](https://wordpress.org/support/users/tambovskya/)
 * Last activity: [12 years, 8 months ago](https://wordpress.org/support/topic/shortcode-into-php-hardcode/#post-4195317)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
