Automattic / Automattic/jetpack

Shortcodes: Testimonial: add "id" attribute

Open
#9,829 1 comment 1 reaction 0 assignees View on GitHub
[Feature] Custom Content Types [Feature] Shortcodes / Embeds [Pri] Low Customer Report [LEGACY] Enhancement
Dominant language
PHP
Stars
1.8k
Forks
898
Avg merge
1d 18h
Merged PRs (30d)
774

Description

Add the ability to return specific posts when using a shortcode to display a [testimonials] Custom Content Type.

Current attributes are only: display_content, image, columns, showposts, order, orderby, date
https://github.com/Automattic/jetpack/blob/master/modules/custom-post-types/testimonial.php#L528

Can we add an ID attribute?

Requested by a user in 1246884-zen

Contributor guide

Open the contributing guide

Research direction

Start in modules/custom-post-types/testimonial.php around line 528, where the testimonial shortcode attributes are defined. Trace how the existing attributes select posts and add an id attribute that returns the requested testimonial posts. Verify the shortcode still supports the current attributes and that an ID selects the intended post.

Written by the indexing model from the issue text.

Assessment

Tech stack
php, wordpress
Domain
backend, content
Issue type
Feature
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.