Title: Is author
Last modified: August 31, 2016

---

# Is author

 *  [websitehelperuk](https://wordpress.org/support/users/websitehelperuk/)
 * (@websitehelperuk)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/is-author/)
 * Hi I have a quick question, does the shoetcode is_author work?
 * I am trying is_author(8) but it does not seem to be working.
 * My aim is to show a text message to guests if the post belongs to author Id 8.
 * Could I be doing something wrong?
 * By the way I am using the correct shoetcode I think eg [s2if is_author(8)….
 * [https://wordpress.org/plugins/s2member/](https://wordpress.org/plugins/s2member/)

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

 *  [KTS915](https://wordpress.org/support/users/kts915/)
 * (@kts915)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/is-author/#post-7389388)
 * There is no such shortcode in s2Member. In any event. s2Member shortcodes are
   concerned with the current user, or what that user can access, and not with other
   matters on a site.
 * I think you are getting confused with the WordPress PHP conditional `is_author`.
   But that’s not a shortcode. It’s in PHP. And it doesn’t mean what you think: 
   it refers to an author’s archive page.
 * I think you want something more like the following PHP code: `if(post->post_author){`
 * If you don’t know how to use that, then ask on the [WP forum](https://wordpress.org/support/)
   or use Google, or hire a developer. This is not an s2Member issue.
 *  Thread Starter [websitehelperuk](https://wordpress.org/support/users/websitehelperuk/)
 * (@websitehelperuk)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/is-author/#post-7389392)
 * Oh ok thanks.
 *  I must of really misunderstood this then:
 * “Maybe you need to change the way something appears (or even what details are
   given), based on the current Post or Page, the current Post Type. Or, perhaps
   based on what Tags that content may have, what Category it’s in, what Sidebar
   it’s in, if it’s Sticky or not, who authored the content, etc.”
 * I was under the impression I could display something based on “who authored the
   content”- it is what it says on their conditional shortcodes page.
 *  [KTS915](https://wordpress.org/support/users/kts915/)
 * (@kts915)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/is-author/#post-7389395)
 * No, that’s about changing what appears according to the type of restriction that
   you have placed on that content.
 *  [KTS915](https://wordpress.org/support/users/kts915/)
 * (@kts915)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/is-author/#post-7389396)
 * So what you could do is tag the posts by a particular author, and then restrict
   by tag. But that doesn’t use a shortcode.
 *  Thread Starter [websitehelperuk](https://wordpress.org/support/users/websitehelperuk/)
 * (@websitehelperuk)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/is-author/#post-7389397)
 * Cool, thank you.
 *  Thread Starter [websitehelperuk](https://wordpress.org/support/users/websitehelperuk/)
 * (@websitehelperuk)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/is-author/#post-7389445)
 * Got it working with has_tag like you mentioned.
 * [s2If !current_user_can(access_s2member_level0)]
    [_s2If has_tag(join-us)]text
   message here[/_s2If] [/s2If]
 * Thanks for that.

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

The topic ‘Is author’ is closed to new replies.

 * ![](https://ps.w.org/s2member/assets/icon-256x256.png?rev=980067)
 * [s2Member – Excellent for All Kinds of Memberships, Content Restriction Paywalls & Member Access Subscriptions](https://wordpress.org/plugins/s2member/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/s2member/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/s2member/)
 * [Active Topics](https://wordpress.org/support/plugin/s2member/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/s2member/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/s2member/reviews/)

 * 6 replies
 * 2 participants
 * Last reply from: [websitehelperuk](https://wordpress.org/support/users/websitehelperuk/)
 * Last activity: [9 years, 10 months ago](https://wordpress.org/support/topic/is-author/#post-7389445)
 * Status: not resolved