Title: Error 500 Create Short Code with URL Variable
Last modified: August 21, 2016

---

# Error 500 Create Short Code with URL Variable

 *  [andybenson129](https://wordpress.org/support/users/andybenson129/)
 * (@andybenson129)
 * [12 years, 9 months ago](https://wordpress.org/support/topic/error-500-create-short-code-with-url-variable/)
 * Hi,
 * I am having an issue creating a short code with this code. It works fine otherwise,
   I am just having an issue creating the short code. I believe the issue might 
   be with the use of a URL with a variable.
 *  ` $webyelp = get_field(‘yelp’, ‘option’);
    if (!empty($webyelp)) {
 * echo ‘<a href=”‘ the_field(‘yelp’, ‘option’); “><img src=”../reviewbadge/yelp.
   png” alt=”yelp” /></a>
 * } else { echo “”;}
    ` Any idea what I’m doing wrong? Thanks a lot for your time!
 * [http://wordpress.org/plugins/shortcode-exec-php/](http://wordpress.org/plugins/shortcode-exec-php/)

Viewing 1 replies (of 1 total)

 *  Thread Starter [andybenson129](https://wordpress.org/support/users/andybenson129/)
 * (@andybenson129)
 * [12 years, 9 months ago](https://wordpress.org/support/topic/error-500-create-short-code-with-url-variable/#post-3964147)
 * Hi,
 * Please disregard, the problem has been solved. For those who are curious, simply
   wrap any html parts like this ?><a href=”<?
 * use ?> at begining and >? at the end and everything will play nicely with the
   php in the short code.

Viewing 1 replies (of 1 total)

The topic ‘Error 500 Create Short Code with URL Variable’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/shortcode-exec-php.svg)
 * [Shortcode Exec PHP](https://wordpress.org/plugins/shortcode-exec-php/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/shortcode-exec-php/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/shortcode-exec-php/)
 * [Active Topics](https://wordpress.org/support/plugin/shortcode-exec-php/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/shortcode-exec-php/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/shortcode-exec-php/reviews/)

## Tags

 * [error 500](https://wordpress.org/support/topic-tag/error-500/)
 * [url](https://wordpress.org/support/topic-tag/url/)

 * 1 reply
 * 1 participant
 * Last reply from: [andybenson129](https://wordpress.org/support/users/andybenson129/)
 * Last activity: [12 years, 9 months ago](https://wordpress.org/support/topic/error-500-create-short-code-with-url-variable/#post-3964147)
 * Status: not a support question