Title: Using a shortcode or php as an ad
Last modified: August 20, 2016

---

# Using a shortcode or php as an ad

 *  [Jason Tucker](https://wordpress.org/support/users/jasontucker/)
 * (@jasontucker)
 * [13 years, 6 months ago](https://wordpress.org/support/topic/using-a-shortcode-or-php-as-an-ad/)
 * I’d like to be able to use a shortcodes or php in the advert blocks, can this
   be done?
 * [http://wordpress.org/extend/plugins/ad-injection/](http://wordpress.org/extend/plugins/ad-injection/)

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

 *  Plugin Author [reviewmylife](https://wordpress.org/support/users/reviewmylife/)
 * (@reviewmylife)
 * [13 years, 6 months ago](https://wordpress.org/support/topic/using-a-shortcode-or-php-as-an-ad/#post-3210993)
 * Hi jasontucker, yes you can use PHP in the ad boxes. And you can use shortcodes,
   but only if the plugin processing the shortcodes runs after Ad Injection (you
   can change Ad Injection’s priority from the UI if necessary).
 *  [brettbum](https://wordpress.org/support/users/brettbum/)
 * (@brettbum)
 * [13 years, 6 months ago](https://wordpress.org/support/topic/using-a-shortcode-or-php-as-an-ad/#post-3211009)
 * Hey Jason,
 * Just a note or possible work around. I’ve also used this where I create a sidebar,
   call the sidebar via short code in Ad Injuection, then ad things to that sidebar
   via widgets (including php etc).
 * This is a pretty powerful plugin for lots of things besides just injecting ads.
   🙂 (Sometimes a little difficult with Supercache sites though)

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

The topic ‘Using a shortcode or php as an ad’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/ad-injection.svg)
 * [Ad Injection](https://wordpress.org/plugins/ad-injection/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/ad-injection/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/ad-injection/)
 * [Active Topics](https://wordpress.org/support/plugin/ad-injection/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/ad-injection/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/ad-injection/reviews/)

## Tags

 * [php](https://wordpress.org/support/topic-tag/php/)
 * [shortcode](https://wordpress.org/support/topic-tag/shortcode/)

 * 2 replies
 * 3 participants
 * Last reply from: [brettbum](https://wordpress.org/support/users/brettbum/)
 * Last activity: [13 years, 6 months ago](https://wordpress.org/support/topic/using-a-shortcode-or-php-as-an-ad/#post-3211009)
 * Status: not resolved