Title: Passing an Argument in Shortcode Attribute
Last modified: August 24, 2016

---

# Passing an Argument in Shortcode Attribute

 *  [krishaamer](https://wordpress.org/support/users/krishaamer/)
 * (@krishaamer)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/passing-an-argument-in-shortcode-attribute/)
 * Hi! It would be very useful to pass in data using shortcode attributes. For example
   I’m listing media (photos) on user pages and instead of having to create a new
   shortcode for each user I could pass in the user ID/Name as an argument and this
   way get photos only from that user.
 * Best regards,
    Kris
 * [https://wordpress.org/plugins/w4-post-list/](https://wordpress.org/plugins/w4-post-list/)

The topic ‘Passing an Argument in Shortcode Attribute’ is closed to new replies.

 * ![](https://ps.w.org/w4-post-list/assets/icon-128x128.png?rev=3034626)
 * [W4 Post List](https://wordpress.org/plugins/w4-post-list/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/w4-post-list/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/w4-post-list/)
 * [Active Topics](https://wordpress.org/support/plugin/w4-post-list/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/w4-post-list/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/w4-post-list/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [krishaamer](https://wordpress.org/support/users/krishaamer/)
 * Last activity: [11 years, 3 months ago](https://wordpress.org/support/topic/passing-an-argument-in-shortcode-attribute/)
 * Status: not resolved