-
Notifications
You must be signed in to change notification settings - Fork 805
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Include opengraph/twitter metadata on AMP Story posts #13416
Include opengraph/twitter metadata on AMP Story posts #13416
Conversation
Thank you for the great PR description! When this PR is ready for review, please apply the Scheduled Jetpack release: October 1, 2019. |
class.jetpack.php
Outdated
@@ -657,6 +657,7 @@ private function __construct() { | |||
* They check for external files or plugins, so they need to run as late as possible. | |||
*/ | |||
add_action( 'wp_head', array( $this, 'check_open_graph' ), 1 ); | |||
add_action( 'amp_story_head', array( $this, 'check_open_graph' ),1 ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
add_action( 'amp_story_head', array( $this, 'check_open_graph' ),1 ); | |
add_action( 'amp_story_head', array( $this, 'check_open_graph' ), 1 ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oops.
But I just realized that if this is applied, then the result would not be aligned:
add_action( 'wp_head', array( $this, 'check_open_graph' ), 1 );
add_action( 'amp_story_head', array( $this, 'check_open_graph' ), 1 );
add_action( 'plugins_loaded', array( $this, 'check_twitter_tags' ), 999 );
add_action( 'plugins_loaded', array( $this, 'check_rest_api_compat' ), 1000 );
So I just went ahead and removed the alignment: 2351a5a
This should be okay short of a minor nitpick. |
1ee745d
to
2351a5a
Compare
Caution: This PR has changes that must be merged to WordPress.com |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Had to rebase. Still works well. Merging.
* Changelog: initial set of changes for 7.8 * Changelog: add #13310 * Changelog: add #13103 * Changelog: add #13426 * Changelog: add #13389 * Changelog: add #13449 * Changelog: add #13461 * Changelog: add #13460 * Changelog: add #13441 * Changelog: add #13454 * Changelog: add #13457 * Changelog: add #13425 * Changelog: add #13473 * Changelog: add #13355 * Changelog: add #13451 * Changelog: add #13358 * Changelog: add #13464 * Changelog: add #13416 * Changelog: add #13494 * Changelog: add #13465 * Changelog: add #13424 * Changelog: add #13432 * Changelog: add #13471 * Changelog: add 7.7.2 entry * Changelog: add #13446 * Add more testing elements
* Changelog: initial set of changes for 7.8 * Changelog: add #13310 * Changelog: add #13103 * Changelog: add #13426 * Changelog: add #13389 * Changelog: add #13449 * Changelog: add #13461 * Changelog: add #13460 * Changelog: add #13441 * Changelog: add #13454 * Changelog: add #13457 * Changelog: add #13425 * Changelog: add #13473 * Changelog: add #13355 * Changelog: add #13451 * Changelog: add #13358 * Changelog: add #13464 * Changelog: add #13416 * Changelog: add #13494 * Changelog: add #13465 * Changelog: add #13424 * Changelog: add #13432 * Changelog: add #13471 * Changelog: add 7.7.2 entry * Changelog: add #13446 * Add more testing elements
See #9730.
Changes proposed in this Pull Request:
amp_story_head
action was introduced for plugins to output additional page metadata on AMP Story posts. This action is functionally the same aswp_head
and is analogous to the coreembed_head
action. This PR adds outputting of thejetpack_og_tags()
on theamp_story
post type which has a template which does theamp_story_head
.head
for optimal performance, thus the comments would no longer appear before/after the tags.Is this a new feature or does it add/remove features to an existing part of Jetpack?
Testing instructions:
develop
branch.meta
tags are present:Proposed changelog entry for your changes: