Skip to content

Commit

Permalink
General: various updates to docs (#30272)
Browse files Browse the repository at this point in the history
* removing Twitter re Social/API
  • Loading branch information
kraftbj authored May 25, 2023
1 parent 7cd00df commit 9ff9c36
Show file tree
Hide file tree
Showing 18 changed files with 45 additions and 32 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#### Publicize

- [ ] Publish a post with Twitter integration
- [ ] Publish a post with Facebook integration
- [ ] Publish a post to all integrations at once
4 changes: 4 additions & 0 deletions projects/plugins/crm/changelog/remove-twitter-api
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: minor
Type: deprecated

Minor changes around upcoming functionality change in Twitter.
2 changes: 1 addition & 1 deletion projects/plugins/jetpack/_inc/client/sharing/publicize.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ export const Publicize = withModuleSettingsFormHelpers(
module={ { module: 'publicize' } }
support={ {
text: __(
'Allows you to automatically share your newest content on social media sites, including Facebook and Twitter.',
'Allows you to automatically share your newest content on social media sites, including Facebook and LinkedIn.',
'jetpack'
),
link: getRedirectUrl( 'jetpack-support-publicize' ),
Expand Down
2 changes: 1 addition & 1 deletion projects/plugins/jetpack/_inc/client/writing/widgets.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ class Widgets extends Component {
toggleModule={ this.props.toggleModuleNow }
>
{ __(
'Make extra widgets available for use on your site including subscription forms and Twitter streams',
'Make extra widgets available for use on your site including subscription forms and more',
'jetpack'
) }
</ModuleToggle>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ public static function init() {
'facebook' => array(
'for' => 'publicize',
),
// @todo Remove when Twitter has been dropped from Publicize.
'twitter' => array(
'for' => 'publicize',
),
Expand Down
4 changes: 4 additions & 0 deletions projects/plugins/jetpack/changelog/remove-twitter-api
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: minor
Type: other

Various updates around Twitter functionality changes
6 changes: 3 additions & 3 deletions projects/plugins/jetpack/class.jetpack-cli.php
Original file line number Diff line number Diff line change
Expand Up @@ -1690,13 +1690,13 @@ public function get_stats( $args, $named_args ) {
* $ wp jetpack publicize list
*
* # List publicize connections for a given service.
* $ wp jetpack publicize list twitter
* $ wp jetpack publicize list linkedin
*
* # List all publicize connections for a given user.
* $ wp --user=1 jetpack publicize list
*
* # List all publicize connections for a given user and service.
* $ wp --user=1 jetpack publicize list twitter
* $ wp --user=1 jetpack publicize list linkedin
*
* # Display details for a given connection.
* $ wp jetpack publicize list 123456
Expand All @@ -1708,7 +1708,7 @@ public function get_stats( $args, $named_args ) {
* $ wp jetpack publicize disconnect all
*
* # Disconnect all connections for a given service.
* $ wp jetpack publicize disconnect twitter
* $ wp jetpack publicize disconnect linkedin
*
* @param array $args Positional args.
* @param array $named_args Named args.
Expand Down
2 changes: 1 addition & 1 deletion projects/plugins/jetpack/class.jetpack-twitter-cards.php
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public static function twitter_cards_tags( $og_tags ) {
/**
* Filter the default Twitter card image, used when no image can be found in a post.
*
* @module sharedaddy, publicize
* @module sharedaddy
*
* @since 5.9.0
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ abstract class WPCOM_JSON_API_Post_Endpoint extends WPCOM_JSON_API_Endpoint {
'format' => array(), // see constructor
'geo' => '(object>geo|false)',
'menu_order' => '(int) (Pages Only) The order pages should appear in.',
'publicize_URLs' => '(array:URL) Array of Twitter and Facebook URLs published by this post.',
'publicize_URLs' => '(array:URL) Array of Facebook URLs published by this post.',
'tags' => '(object:tag) Hash of tags (keyed by tag name) applied to the post.',
'categories' => '(object:category) Hash of categories (keyed by category name) applied to the post.',
'attachments' => '(object:attachment) Hash of post attachments (keyed by attachment ID).',
Expand Down Expand Up @@ -391,6 +391,7 @@ public function get_post_by( $field, $field_value, $context = 'display' ) {
if ( $publicize ) {
foreach ( $publicize as $service => $data ) {
switch ( $service ) {
// @todo Explore removing once Twitter has been removed from Publicize.
case 'twitter':
foreach ( $data as $datum ) {
$publicize_urls[] = esc_url_raw( "https://twitter.com/{$datum['user_id']}/status/{$datum['post_id']}" );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ abstract class WPCOM_JSON_API_Post_v1_1_Endpoint extends WPCOM_JSON_API_Endpoint
'geo' => '(object>geo|false)',
'menu_order' => '(int) (Pages Only) The order pages should appear in.',
'page_template' => '(string) (Pages Only) The page template this page is using.',
'publicize_URLs' => '(array:URL) Array of Twitter and Facebook URLs published by this post.',
'publicize_URLs' => '(array:URL) Array of Facebook URLs published by this post.',
'terms' => '(object) Hash of taxonomy names mapping to a hash of terms keyed by term name.',
'tags' => '(object:tag) Hash of tags (keyed by tag name) applied to the post.',
'categories' => '(object:category) Hash of categories (keyed by category name) applied to the post.',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -679,12 +679,12 @@ public function write_post( $path, $blog_id, $post_id ) {
*
* We do support mixed arrays: mixed integer and string keys (see 3rd example below).
*
* EG: array( 'twitter', 'facebook') will only publicize to those, ignoring the other available services
* Form data: publicize[]=twitter&publicize[]=facebook
* EG: array( 'twitter' => '(int) $pub_conn_id_0, (int) $pub_conn_id_3', 'facebook' => (int) $pub_conn_id_7 ) will publicize to two Twitter accounts, and one Facebook connection, of potentially many.
* Form data: publicize[twitter]=$pub_conn_id_0,$pub_conn_id_3&publicize[facebook]=$pub_conn_id_7
* EG: array( 'twitter', 'facebook' => '(int) $pub_conn_id_0, (int) $pub_conn_id_3' ) will publicize to all available Twitter accounts, but only 2 of potentially many Facebook connections
* Form data: publicize[]=twitter&publicize[facebook]=$pub_conn_id_0,$pub_conn_id_3
* EG: array( 'linkedin', 'facebook') will only publicize to those, ignoring the other available services
* Form data: publicize[]=linkedin&publicize[]=facebook
* EG: array( 'linkedin' => '(int) $pub_conn_id_0, (int) $pub_conn_id_3', 'facebook' => (int) $pub_conn_id_7 ) will publicize to two LinkedIn accounts, and one Facebook connection, of potentially many.
* Form data: publicize[linkedin]=$pub_conn_id_0,$pub_conn_id_3&publicize[facebook]=$pub_conn_id_7
* EG: array( 'linkedin', 'facebook' => '(int) $pub_conn_id_0, (int) $pub_conn_id_3' ) will publicize to all available LinkedIn accounts, but only 2 of potentially many Facebook connections
* Form data: publicize[]=linkedin&publicize[facebook]=$pub_conn_id_0,$pub_conn_id_3
*/

// Delete any stale SKIP value for the service by name. We'll add it back by ID.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -756,12 +756,12 @@ public function write_post( $path, $blog_id, $post_id ) {
*
* We do support mixed arrays: mixed integer and string keys (see 3rd example below).
*
* EG: array( 'twitter', 'facebook') will only publicize to those, ignoring the other available services
* Form data: publicize[]=twitter&publicize[]=facebook
* EG: array( 'twitter' => '(int) $pub_conn_id_0, (int) $pub_conn_id_3', 'facebook' => (int) $pub_conn_id_7 ) will publicize to two Twitter accounts, and one Facebook connection, of potentially many.
* Form data: publicize[twitter]=$pub_conn_id_0,$pub_conn_id_3&publicize[facebook]=$pub_conn_id_7
* EG: array( 'twitter', 'facebook' => '(int) $pub_conn_id_0, (int) $pub_conn_id_3' ) will publicize to all available Twitter accounts, but only 2 of potentially many Facebook connections
* Form data: publicize[]=twitter&publicize[facebook]=$pub_conn_id_0,$pub_conn_id_3
* EG: array( 'linkedin', 'facebook') will only publicize to those, ignoring the other available services
* Form data: publicize[]=linkedin&publicize[]=facebook
* EG: array( 'linkedin' => '(int) $pub_conn_id_0, (int) $pub_conn_id_3', 'facebook' => (int) $pub_conn_id_7 ) will publicize to two LinkedIn accounts, and one Facebook connection, of potentially many.
* Form data: publicize[linkedin]=$pub_conn_id_0,$pub_conn_id_3&publicize[facebook]=$pub_conn_id_7
* EG: array( 'linkedin', 'facebook' => '(int) $pub_conn_id_0, (int) $pub_conn_id_3' ) will publicize to all available LinkedIn accounts, but only 2 of potentially many Facebook connections
* Form data: publicize[]=linkedin&publicize[facebook]=$pub_conn_id_0,$pub_conn_id_3
*/

// Delete any stale SKIP value for the service by name. We'll add it back by ID.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -728,12 +728,12 @@ public function write_post( $path, $blog_id, $post_id ) {
*
* We do support mixed arrays: mixed integer and string keys (see 3rd example below).
*
* EG: array( 'twitter', 'facebook') will only publicize to those, ignoring the other available services
* Form data: publicize[]=twitter&publicize[]=facebook
* EG: array( 'twitter' => '(int) $pub_conn_id_0, (int) $pub_conn_id_3', 'facebook' => (int) $pub_conn_id_7 ) will publicize to two Twitter accounts, and one Facebook connection, of potentially many.
* Form data: publicize[twitter]=$pub_conn_id_0,$pub_conn_id_3&publicize[facebook]=$pub_conn_id_7
* EG: array( 'twitter', 'facebook' => '(int) $pub_conn_id_0, (int) $pub_conn_id_3' ) will publicize to all available Twitter accounts, but only 2 of potentially many Facebook connections
* Form data: publicize[]=twitter&publicize[facebook]=$pub_conn_id_0,$pub_conn_id_3
* EG: array( 'linkedin', 'facebook') will only publicize to those, ignoring the other available services
* Form data: publicize[]=linkedin&publicize[]=facebook
* EG: array( 'linkedin' => '(int) $pub_conn_id_0, (int) $pub_conn_id_3', 'facebook' => (int) $pub_conn_id_7 ) will publicize to two LinkedIn accounts, and one Facebook connection, of potentially many.
* Form data: publicize[linkedin]=$pub_conn_id_0,$pub_conn_id_3&publicize[facebook]=$pub_conn_id_7
* EG: array( 'linkedin', 'facebook' => '(int) $pub_conn_id_0, (int) $pub_conn_id_3' ) will publicize to all available LinkedIn accounts, but only 2 of potentially many Facebook connections
* Form data: publicize[]=linkedin&publicize[facebook]=$pub_conn_id_0,$pub_conn_id_3
*/

// Delete any stale SKIP value for the service by name. We'll add it back by ID.
Expand Down
2 changes: 1 addition & 1 deletion projects/plugins/jetpack/modules/module-info.php
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ function publicize_load_more_link() {
*/
function publicize_more_info() {
esc_html_e(
'Automatically share and promote newly published posts to Facebook, Twitter, Tumblr,
'Automatically share and promote newly published posts to Facebook, Tumblr,
and LinkedIn. You can add connections for yourself or for all users on your site.',
'jetpack'
);
Expand Down
2 changes: 1 addition & 1 deletion projects/plugins/jetpack/modules/publicize.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* Auto Activate: No
* Module Tags: Social, Recommended
* Feature: Engagement
* Additional Search Queries: facebook, jetpack publicize, twitter, tumblr, linkedin, social, tweet, connections, sharing, social media, automated, automated sharing, auto publish, auto tweet and like, auto tweet, facebook auto post, facebook posting
* Additional Search Queries: facebook, jetpack publicize, tumblr, linkedin, social, tweet, connections, sharing, social media, automated, automated sharing, auto publish, auto tweet and like, auto tweet, facebook auto post, facebook posting
*
* @package automattic/jetpack
*/
Expand Down
1 change: 1 addition & 0 deletions projects/plugins/jetpack/sal/class.json-api-post-base.php
Original file line number Diff line number Diff line change
Expand Up @@ -423,6 +423,7 @@ public function get_publicize_urls() {
if ( $publicize ) {
foreach ( $publicize as $service => $data ) {
switch ( $service ) {
// @todo explore removing once Twitter is removed from Publicize.
case 'twitter':
foreach ( $data as $datum ) {
$publicize_urls[] = esc_url_raw( "https://twitter.com/{$datum['user_id']}/status/{$datum['post_id']}" );
Expand Down
4 changes: 4 additions & 0 deletions projects/plugins/social/changelog/remove-twitter-api
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: minor
Type: deprecated

Minor changes around upcoming functionality change in Twitter.
5 changes: 2 additions & 3 deletions projects/plugins/social/readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Write once, publish everywhere. Reach your target audience by sharing your conte

**Grow your following by sharing your content with Jetpack Social!**

It’s important to publish on both your website & social media in order to reach your whole audience. If you only publish on social media, you’re missing up to 60% of adults on a daily basis. Jetpack Social makes it easy to automatically share your site’s posts on popular social media channels such as Facebook and Twitter. Increase your audience by engaging your site's viewers & your social followers.
It’s important to publish on both your website & social media in order to reach your whole audience. If you only publish on social media, you’re missing up to 60% of adults on a daily basis. Jetpack Social makes it easy to automatically share your site’s posts on popular social media channels such as Facebook and Tumblr. Increase your audience by engaging your site's viewers & your social followers.

**Manage all channels from a single hub to save time**

Expand Down Expand Up @@ -61,7 +61,6 @@ From your site’s WP Admin:
You can connect to any of the following networks:

* Facebook Pages
* Twitter
* Tumblr
* LinkedIn

Expand All @@ -71,7 +70,7 @@ To make the connection available to all users, check the box labeled "Connection

= To which social media platforms can I post using Jetpack Social? =

You can post to Facebook, Twitter, Tumblr, and Linkedin. We are working hard to increase our social share integrations.
You can post to Facebook, Tumblr, and Linkedin. We are working hard to increase our social share integrations.

= How do I share a post on social media using Jetpack Social? =

Expand Down

0 comments on commit 9ff9c36

Please sign in to comment.