Title: How insert permalink in shortcode
Last modified: May 20, 2018

---

# How insert permalink in shortcode

 *  Resolved [davidhelp](https://wordpress.org/support/users/davidhelp/)
 * (@davidhelp)
 * [8 years ago](https://wordpress.org/support/topic/how-insert-permalink-in-shortcode/)
 * Hi,
 * I would like insert permalink %postname% in short code [mbhi_hours location=”%
   postname%”]
 * For example:
    I have post on this URL – [http://www.forum.com/themes/this-is-test-post](http://www.forum.com/themes/this-is-test-post).
   I have same name as %postname% for Location in Business Hours Indicator (this-
   is-test-post). If i use this short [mbhi_hours location=”this-is-test-post”] 
   its working. But if I insert %postname% as location, dont work [mbhi_hours location
   =”%postname%”].
 * Please, is any opinion, what insert actualy URL from display post to mbhi [mbhi_hours
   location=”?????”]?
 * I try code from this post [https://wordpress.org/support/topic/how-display-permalink-in-posts-text/](https://wordpress.org/support/topic/how-display-permalink-in-posts-text/)
   but dont work.
 * Well thank you

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

 *  Plugin Author [Wombat Plugins](https://wordpress.org/support/users/maartenbelmans/)
 * (@maartenbelmans)
 * [8 years ago](https://wordpress.org/support/topic/how-insert-permalink-in-shortcode/#post-10304736)
 * Hi David,
 * I’m sorry, but what you are looking for is not possible at this point. Is there
   a specific reason you want to write location=”%postname%” and not just location
   =”test-post”?
 *  Thread Starter [davidhelp](https://wordpress.org/support/users/davidhelp/)
 * (@davidhelp)
 * [8 years ago](https://wordpress.org/support/topic/how-insert-permalink-in-shortcode/#post-10304962)
 * Yes, because i will be approximately 1000 posts and every posts need own open
   hours. The best identificator for this quantity is Location name set as URL postname,
   and into the post insert only one universal code in every posts [mbhi_hours location
   =”%postname%”]. Or is any other automaticaly method?
    Thanks
 *  [stesib](https://wordpress.org/support/users/stesib/)
 * (@stesib)
 * [7 years, 9 months ago](https://wordpress.org/support/topic/how-insert-permalink-in-shortcode/#post-10545912)
 * Having the same idea and hope for the plugin!

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

The topic ‘How insert permalink in shortcode’ is closed to new replies.

 * ![](https://ps.w.org/business-hours-indicator/assets/icon-256x256.png?rev=1551528)
 * [Business Hours Indicator](https://wordpress.org/plugins/business-hours-indicator/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/business-hours-indicator/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/business-hours-indicator/)
 * [Active Topics](https://wordpress.org/support/plugin/business-hours-indicator/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/business-hours-indicator/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/business-hours-indicator/reviews/)

 * 3 replies
 * 3 participants
 * Last reply from: [stesib](https://wordpress.org/support/users/stesib/)
 * Last activity: [7 years, 9 months ago](https://wordpress.org/support/topic/how-insert-permalink-in-shortcode/#post-10545912)
 * Status: resolved