Instant Articles for WP - Version 4.0.1

Version Description

Download this release

Release Info

Developer diegoquinteiro
Plugin Icon 128x128 Instant Articles for WP
Version 4.0.1
Comparing to
See all releases

Code changes from version 4.0.0 to 4.0.1

CHANGELOG.md ADDED
@@ -0,0 +1,168 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ## Change Log
2
+
3
+ ### 4.0.1 (2017/06/28 18:41 +00:00)
4
+ - [#706](https://github.com/automattic/facebook-instant-articles-wp/pull/706) Check for array index before using it (@diegoquinteiro)
5
+ - [#705](https://github.com/automattic/facebook-instant-articles-wp/pull/705) Enable deletion of JSON AMP Style and removes an undef index (@vkama)
6
+ - [#704](https://github.com/automattic/facebook-instant-articles-wp/pull/704) Fixed several php notices. Also fixed a bug in should_subit_post() (@vkama)
7
+
8
+ ### 4.0.0 (2017/06/27 17:55 +00:00)
9
+ - [#702](https://github.com/automattic/facebook-instant-articles-wp/pull/702) V4.0 (@vkama, @diegoquinteiro, @everton-rosario, @sakatam, @abdusfauzi)
10
+ - [#647](https://github.com/automattic/facebook-instant-articles-wp/pull/647) Fix "Empty string supplied as input" bug (@abdusfauzi)
11
+ - [#680](https://github.com/automattic/facebook-instant-articles-wp/pull/680) Adding support to IA->AMP conversion (@vkama)
12
+ - [#649](https://github.com/automattic/facebook-instant-articles-wp/pull/649) allow markups in footer/copyright (@sakatam)
13
+ - [#643](https://github.com/automattic/facebook-instant-articles-wp/pull/643) Open Graph Ingestion Flow (@diegoquinteiro, @everton-rosario)
14
+ - [#629](https://github.com/automattic/facebook-instant-articles-wp/pull/629) Update Google Analytics compat (@dlackty)
15
+
16
+ ### 3.3.4 (2017/05/10 23:17 +00:00)
17
+ - [#602](https://github.com/automattic/facebook-instant-articles-wp/pull/602) Add post ID to `instant_articles_content` filter (@carlalexander)
18
+ - [#622](https://github.com/automattic/facebook-instant-articles-wp/pull/622) Adds ver=<VERSION_TOKEN> to invalidate plugin resource files (@everton-rosario)
19
+ - [#645](https://github.com/automattic/facebook-instant-articles-wp/pull/645) Fix wp_is_post_autosave() parameter value (@abdusfauzi)
20
+ - [#623](https://github.com/automattic/facebook-instant-articles-wp/pull/623) Allow for alternative file path for json rules (@andykillen)
21
+ - [#624](https://github.com/automattic/facebook-instant-articles-wp/pull/624) fix merge damage (@sakatam)
22
+ - [#616](https://github.com/automattic/facebook-instant-articles-wp/pull/616) Extracted anonymous inline function (@everton-rosario)
23
+ - [#609](https://github.com/automattic/facebook-instant-articles-wp/pull/609) Apester plugin support (@oraricha)
24
+ - [#617](https://github.com/automattic/facebook-instant-articles-wp/pull/617) Switch on/off configuration for enabling comments/likes by default (@everton-rosario)
25
+ - [#612](https://github.com/automattic/facebook-instant-articles-wp/pull/612) Add an option to set a footer (@sakatam)
26
+
27
+ ### 3.3.2 (2017/02/13 19:10 +00:00)
28
+ - [#418](https://github.com/automattic/facebook-instant-articles-wp/pull/418) Call instant_articles_post_published hook to determine published status (@apeschar)
29
+ - [#611](https://github.com/automattic/facebook-instant-articles-wp/pull/611) capability to toggle RTL option (@sakatam)
30
+ - [#604](https://github.com/automattic/facebook-instant-articles-wp/pull/604) Fix typo for $provider_url at L42, L44 and L46 (@abdusfauzi)
31
+
32
+ ### 3.3.1 (2017/01/31 17:33 +00:00)
33
+ - [#598](https://github.com/automattic/facebook-instant-articles-wp/pull/598) Fix typo on script (@diegoquinteiro)
34
+ - [#595](https://github.com/automattic/facebook-instant-articles-wp/pull/595) Add transformer rule for cite element (@davebonds)
35
+ - [#59](https://github.com/automattic/facebook-instant-articles-wp/pull/59) add vimeo.com into oEmbed $provider_name (@abdusfauzi)
36
+ - [#597](https://github.com/automattic/facebook-instant-articles-wp/pull/597) Don't try to load embeds compat unless we're in Instant Articles context (@diegoquinteiro, @rinatkhaziev)
37
+ - [#568](https://github.com/automattic/facebook-instant-articles-wp/pull/568) Add `is_transforming_instant_article()` conditional (@goldenapples)
38
+ - [#287](https://github.com/automattic/facebook-instant-articles-wp/pull/287) Ad de_DE (@swissky)
39
+ - [#578](https://github.com/automattic/facebook-instant-articles-wp/pull/578) Change save_post priority (@cmjaimet)
40
+ - [#592](https://github.com/automattic/facebook-instant-articles-wp/pull/592) Add missing information to composer.json (@onnimonni)
41
+ - [#562](https://github.com/automattic/facebook-instant-articles-wp/pull/562) Add release script (@diegoquinteiro)
42
+
43
+ ### 3.3 (2016/12/16 02:20 +00:00)
44
+ - [#560](https://github.com/automattic/facebook-instant-articles-wp/pull/560) Remove deprecated rules and add rules for imgs inside links (@diegoquinteiro)
45
+ - [#525](https://github.com/automattic/facebook-instant-articles-wp/pull/525) Update WordPress.com stats code to use FBIA SDK. (@philipjohn)
46
+ - [#535](https://github.com/automattic/facebook-instant-articles-wp/pull/535) Fixes #515 - Enables Playbuzz plugin out of the box (@everton-rosario)
47
+
48
+ ### 3.2.2 (2016/11/29 05:15 +00:00)
49
+ - [#543](https://github.com/automattic/facebook-instant-articles-wp/pull/543) Fix variable name (@diegoquinteiro)
50
+
51
+ ### 3.2.1 (2016/11/25 02:58 +00:00)
52
+ - [#538](https://github.com/automattic/facebook-instant-articles-wp/pull/538) Show message on meta-box when post is filtered out (@diegoquinteiro)
53
+ - [#504](https://github.com/automattic/facebook-instant-articles-wp/pull/504) Add instant_articles_should_submit_post filter hook to allow developers control of whether the post should be submitted to IA (@rinatkhaziev)
54
+ - [#498](https://github.com/automattic/facebook-instant-articles-wp/pull/498) Release v3.2 (@philipjohn)
55
+ - [#437](https://github.com/automattic/facebook-instant-articles-wp/pull/437) Blocks publishing of articles with transformation warnings (@diegoquinteiro, @everton-rosario)
56
+ - [#423](https://github.com/automattic/facebook-instant-articles-wp/pull/423) Fixes #205 - Caption in <p> tag (@everton-rosario)
57
+ - [#435](https://github.com/automattic/facebook-instant-articles-wp/pull/435) Setup Wizard copy updates (@demoive)
58
+ - [#497](https://github.com/automattic/facebook-instant-articles-wp/pull/497) Getter was renamed on SDK, updating here too (@diegoquinteiro)
59
+ - [#417](https://github.com/automattic/facebook-instant-articles-wp/pull/417) Support for Playbuzz plugin (@everton-rosario)
60
+ - [#416](https://github.com/automattic/facebook-instant-articles-wp/pull/416) Use the instant_articles_post_types filter when registering metaboxes (@technosailor)
61
+
62
+ ### 3.2 (2016/10/05 14:23 +00:00)
63
+ - [#484](https://github.com/automattic/facebook-instant-articles-wp/pull/484) Apply the second argument to `the_title` (@srtfisher)
64
+ - [#481](https://github.com/automattic/facebook-instant-articles-wp/pull/481) Token Invalidation flow (@everton-rosario)
65
+ - [#462](https://github.com/automattic/facebook-instant-articles-wp/pull/462) Migration from old facebook sdk (@everton-rosario)
66
+ - [#436](https://github.com/automattic/facebook-instant-articles-wp/pull/436) Wp tests migration (@everton-rosario)
67
+ - [#421](https://github.com/automattic/facebook-instant-articles-wp/pull/421) Fixes #408 adding rules for gallery (@everton-rosario)
68
+ - [#376](https://github.com/automattic/facebook-instant-articles-wp/pull/376) Added rule configuration for Instagram embed (@everton-rosario)
69
+ - [#316](https://github.com/automattic/facebook-instant-articles-wp/pull/316) Add development mode support to status meta box (@simonengelhardt)
70
+
71
+ ### 3.1.3 (2016/09/19 17:55 +00:00)
72
+ - [#469](https://github.com/automattic/facebook-instant-articles-wp/pull/469) Release stuff for v3.1.3 (@philipjohn)
73
+ - [#450](https://github.com/automattic/facebook-instant-articles-wp/pull/450) Do not block page selection if URL is not claimed (@diegoquinteiro)
74
+ - [#464](https://github.com/automattic/facebook-instant-articles-wp/pull/464) Fixes #452 - Use of empty() on PHP prior to v5.5 (@demoive)
75
+ - [#465](https://github.com/automattic/facebook-instant-articles-wp/pull/465) Relative CSS to fix missing icons (@everton-rosario)
76
+ - [#458](https://github.com/automattic/facebook-instant-articles-wp/pull/458) Fix expiring token blocking users on page selection state (@diegoquinteiro)
77
+ - [#403](https://github.com/automattic/facebook-instant-articles-wp/pull/403) fix travis.ci build (@sakatam)
78
+ - [#425](https://github.com/automattic/facebook-instant-articles-wp/pull/425) Final release of v3.1 (@philipjohn)
79
+ - [#385](https://github.com/automattic/facebook-instant-articles-wp/pull/385) Implemented compat for the get-the-image plugin (@everton-rosario)
80
+ - [#392](https://github.com/automattic/facebook-instant-articles-wp/pull/392) Load functions which rely on `plugins_loaded` action hook in wp.com e… (@nprasath002)
81
+ - [#402](https://github.com/automattic/facebook-instant-articles-wp/pull/402) Properly implemented the get_cover_media function. (@menzow)
82
+ - [#420](https://github.com/automattic/facebook-instant-articles-wp/pull/420) Article with password protection (@everton-rosario)
83
+ - [#409](https://github.com/automattic/facebook-instant-articles-wp/pull/409) Check for undefined index (@gemedet)
84
+
85
+ ### 3.1 (2016/08/17 20:17 +00:00)
86
+ - [#413](https://github.com/automattic/facebook-instant-articles-wp/pull/413) Fix lingering reference to the old settings page on meta-box (@diegoquinteiro)
87
+ - [#412](https://github.com/automattic/facebook-instant-articles-wp/pull/412) Content update (@diegoquinteiro)
88
+ - [#400](https://github.com/automattic/facebook-instant-articles-wp/pull/400) New flow (@diegoquinteiro, @everton-rosario)
89
+ - [#399](https://github.com/automattic/facebook-instant-articles-wp/pull/399) Revert "Redirect settings" (@philipjohn)
90
+ - [#394](https://github.com/automattic/facebook-instant-articles-wp/pull/394) Apply "the_title" filter (@everton-rosario)
91
+ - [#389](https://github.com/automattic/facebook-instant-articles-wp/pull/389) Redirect settings (@everton-rosario)
92
+ - [#387](https://github.com/automattic/facebook-instant-articles-wp/pull/387) Fix loadHTML warning (@gemedet)
93
+ - [#378](https://github.com/automattic/facebook-instant-articles-wp/pull/378) Added rules for jetpack carousel component (@everton-rosario)
94
+ - [#379](https://github.com/automattic/facebook-instant-articles-wp/pull/379) Don't call wpautop directly when trying to prepare content for transformation. (@rinatkhaziev)
95
+ - [#383](https://github.com/automattic/facebook-instant-articles-wp/pull/383) Fix updating published posts result in error (@chrisadas)
96
+ - [#375](https://github.com/automattic/facebook-instant-articles-wp/pull/375) Commit blocker option - No warnings in transformer to publish (@everton-rosario)
97
+ - [#374](https://github.com/automattic/facebook-instant-articles-wp/pull/374) Jetpack plugin compatibility - Transformation rules (@everton-rosario)
98
+ - [#371](https://github.com/automattic/facebook-instant-articles-wp/pull/371) Migrated take_live parameter to the published (@everton-rosario)
99
+ - [#366](https://github.com/automattic/facebook-instant-articles-wp/pull/366) InteractiveInsideParagraphRule support and configuration (@everton-rosario)
100
+ - [#367](https://github.com/automattic/facebook-instant-articles-wp/pull/367) Add subtitle to $header when rendering post to IA (@jacobarriola)
101
+ - [#360](https://github.com/automattic/facebook-instant-articles-wp/pull/360) Improve rules for Images inside Paragraphs and Interactive elements (@everton-rosario)
102
+ - [#356](https://github.com/automattic/facebook-instant-articles-wp/pull/356) Ensure that relative URL checking has a host and a path. (@srtfisher)
103
+
104
+ ### 3.0.1 (2016/07/13 10:19 +00:00)
105
+ - [#359](https://github.com/automattic/facebook-instant-articles-wp/pull/359) Release 3.0.1 (@philipjohn)
106
+ - [#358](https://github.com/automattic/facebook-instant-articles-wp/pull/358) Revert "escaping and sanitization fixes" (@philipjohn, @diegoquinteiro)
107
+
108
+ ### 3.0 (2016/07/12 12:45 +00:00)
109
+ - [#355](https://github.com/automattic/facebook-instant-articles-wp/pull/355) Release v3.0 (@philipjohn)
110
+ - [#354](https://github.com/automattic/facebook-instant-articles-wp/pull/354) Remove to avoid breaking elements. See #331 (@philipjohn)
111
+ - [#353](https://github.com/automattic/facebook-instant-articles-wp/pull/353) Store and use submission ID when available to fetch the status (@diegoquinteiro)
112
+ - [#329](https://github.com/automattic/facebook-instant-articles-wp/pull/329) always use HTTPS to load JavaScript SDK; update to 2.6 (@paulschreiber)
113
+ - [#327](https://github.com/automattic/facebook-instant-articles-wp/pull/327) use v2.6 of Facebook API (@paulschreiber)
114
+ - [#263](https://github.com/automattic/facebook-instant-articles-wp/pull/263) Escape ampersands before displaying on settings page (@gemedet)
115
+ - [#301](https://github.com/automattic/facebook-instant-articles-wp/pull/301) Check if the global $post object has been set (@srtfisher)
116
+ - [#290](https://github.com/automattic/facebook-instant-articles-wp/pull/290) Fix relative URL issue with oembeds not using absolute URLs (@stuartshields)
117
+ - [#255](https://github.com/automattic/facebook-instant-articles-wp/pull/255) Support <mark> tag (@demoive)
118
+ - [#313](https://github.com/automattic/facebook-instant-articles-wp/pull/313) Fixed statically-called loadHTML() (@gemedet)
119
+ - [#258](https://github.com/automattic/facebook-instant-articles-wp/pull/258) Width and Height for Interactive in default rules (@gemedet)
120
+ - [#343](https://github.com/automattic/facebook-instant-articles-wp/pull/343) Only publish posts (ignores pages and other post types) (@diegoquinteiro)
121
+ - [#342](https://github.com/automattic/facebook-instant-articles-wp/pull/342) Replace SocialEmbed rules with Interactive rules (@diegoquinteiro)
122
+ - [#330](https://github.com/automattic/facebook-instant-articles-wp/pull/330) fix whitespace in select/optgroup tags (@paulschreiber)
123
+ - [#331](https://github.com/automattic/facebook-instant-articles-wp/pull/331) WordPress coding standards fixes (@paulschreiber)
124
+ - [#328](https://github.com/automattic/facebook-instant-articles-wp/pull/328) Fix whitespace to match WordPress coding standards (@paulschreiber)
125
+ - [#285](https://github.com/automattic/facebook-instant-articles-wp/pull/285) Remove hyperlinks beginning with a # (@markbarnes)
126
+ - [#341](https://github.com/automattic/facebook-instant-articles-wp/pull/341) Avoid crawler to cache a 404 (@diegoquinteiro)
127
+ - [#305](https://github.com/automattic/facebook-instant-articles-wp/pull/305) Allow filtering of the post types used in the feed (@philipjohn)
128
+ - [#308](https://github.com/automattic/facebook-instant-articles-wp/pull/308) Fixed error message: Deprecated: Non-static method DOMDocument::loadH… (@everton-rosario)
129
+ - [#286](https://github.com/automattic/facebook-instant-articles-wp/pull/286) Add GitHub Issue and PR templates (@simonengelhardt)
130
+ - [#177](https://github.com/automattic/facebook-instant-articles-wp/pull/177) Use H1 for header title and cover image caption (@gemedet)
131
+
132
+ ### 2.11 (2016/05/17 15:25 +00:00)
133
+ - [#257](https://github.com/automattic/facebook-instant-articles-wp/pull/257) Fix scheduled posts with empty IA content (@Aioros)
134
+ - [#273](https://github.com/automattic/facebook-instant-articles-wp/pull/273) Copy updated to align better with scheduled posts (@demoive)
135
+ - [#271](https://github.com/automattic/facebook-instant-articles-wp/pull/271) Checks if it have the node to be shown as warning body (@everton-rosario)
136
+ - [#264](https://github.com/automattic/facebook-instant-articles-wp/pull/264) Add new application header (@diegoquinteiro)
137
+
138
+ ### 2.10 (2016/04/29 00:01 +00:00)
139
+ - [#179](https://github.com/automattic/facebook-instant-articles-wp/pull/179) Graphics for banner and icon (@demoive)
140
+ - [#183](https://github.com/automattic/facebook-instant-articles-wp/pull/183) Wordpress -> WordPress (@lesterchan)
141
+ - [#213](https://github.com/automattic/facebook-instant-articles-wp/pull/213) Labels and documentation changes re: custom transformer rules (@demoive)
142
+
143
+ ### 2.9 (2016/04/19 17:05 +00:00)
144
+ - [#174](https://github.com/automattic/facebook-instant-articles-wp/pull/174) Prevents <figcaptions> from being added to images that were not saved with captions (@bobderrico80)
145
+ - [#176](https://github.com/automattic/facebook-instant-articles-wp/pull/176) Remove unused image.caption property from ImageRule (@demoive)
146
+ - [#180](https://github.com/automattic/facebook-instant-articles-wp/pull/180) Fix empty articles being uploaded on bulk update (@diegoquinteiro)
147
+ - [#167](https://github.com/automattic/facebook-instant-articles-wp/pull/167) Fixes #116 encoding problem (@everton-rosario)
148
+ - [#173](https://github.com/automattic/facebook-instant-articles-wp/pull/173) Fixed empty link to Instant Articles signup (@demoive)
149
+
150
+ ### 2.8 (2016/04/14 23:23 +00:00)
151
+ - [#151](https://github.com/automattic/facebook-instant-articles-wp/pull/151) Stop publishing drafts (@diegoquinteiro)
152
+
153
+ ### 2.6 (2016/04/13 16:24 +00:00)
154
+ - [#115](https://github.com/automattic/facebook-instant-articles-wp/pull/115) Added information about initial publishing (@msurguy)
155
+ - [#105](https://github.com/automattic/facebook-instant-articles-wp/pull/105) Update template-settings-info.php (@piscis)
156
+
157
+ ### 2.1 (2016/04/11 20:55 +00:00)
158
+ - [#98](https://github.com/automattic/facebook-instant-articles-wp/pull/98) Fixes #72 (@diegoquinteiro)
159
+ - [#90](https://github.com/automattic/facebook-instant-articles-wp/pull/90) Change readme.txt to reflect changes in 2.0 (@diegoquinteiro)
160
+ - [#87](https://github.com/automattic/facebook-instant-articles-wp/pull/87) Clean unused files + fixes for 5.4 compatibility (@diegoquinteiro)
161
+
162
+ ### 2.0 (2016/04/06 17:45 +00:00)
163
+ - [#70](https://github.com/automattic/facebook-instant-articles-wp/pull/70) Use SDK engine (@diegoquinteiro)
164
+
165
+ ### 0.2 (2016/03/09 19:44 +00:00)
166
+ - [#41](https://github.com/automattic/facebook-instant-articles-wp/pull/41) Add support for subtitles through the filter instant_articles_subtitle (@bjornjohansen)
167
+ - [#39](https://github.com/automattic/facebook-instant-articles-wp/pull/39) Jetpack compat: YouTube and Facebook embeds (@bjornjohansen)
168
+ - [#22](https://github.com/automattic/facebook-instant-articles-wp/pull/22) Migrate the wpcom-helper.php from WordPress.com. (@philipjohn)
class-instant-articles-post.php CHANGED
@@ -693,7 +693,7 @@ class Instant_Articles_Post {
693
  Image::setDefaultCommentEnabled( $settings_publishing[ 'comments_on_media' ] );
694
  Video::setDefaultCommentEnabled( $settings_publishing[ 'comments_on_media' ] );
695
  }
696
-
697
  $the_content = $this->get_the_content();
698
  if (!Type::isTextEmpty($the_content)) {
699
  $transformer->transformString( $this->instant_article, $the_content, get_option( 'blog_charset' ) );
@@ -879,12 +879,12 @@ class Instant_Articles_Post {
879
  $post = get_post( $this->get_the_id() );
880
 
881
  $fb_page_settings = Instant_Articles_Option_FB_Page::get_option_decoded();
882
- if ( ! $fb_page_settings[ "page_id" ] ) {
883
  return false;
884
  }
885
 
886
  // Don't process if this is just a revision or an autosave.
887
- if ( wp_is_post_revision( $this->post ) || wp_is_post_autosave( $this->post ) ) {
888
  return false;
889
  }
890
 
693
  Image::setDefaultCommentEnabled( $settings_publishing[ 'comments_on_media' ] );
694
  Video::setDefaultCommentEnabled( $settings_publishing[ 'comments_on_media' ] );
695
  }
696
+
697
  $the_content = $this->get_the_content();
698
  if (!Type::isTextEmpty($the_content)) {
699
  $transformer->transformString( $this->instant_article, $the_content, get_option( 'blog_charset' ) );
879
  $post = get_post( $this->get_the_id() );
880
 
881
  $fb_page_settings = Instant_Articles_Option_FB_Page::get_option_decoded();
882
+ if ( isset( $fb_page_settings[ 'page_id' ] ) && !$fb_page_settings[ 'page_id' ] ) {
883
  return false;
884
  }
885
 
886
  // Don't process if this is just a revision or an autosave.
887
+ if ( wp_is_post_revision( $post ) || wp_is_post_autosave( $post ) ) {
888
  return false;
889
  }
890
 
facebook-instant-articles.php CHANGED
@@ -4,7 +4,7 @@
4
  * Description: Add support for Instant Articles for Facebook to your WordPress site.
5
  * Author: Automattic, Dekode, Facebook
6
  * Author URI: https://vip.wordpress.com/plugins/instant-articles/
7
- * Version: 4.0.0
8
  * Text Domain: instant-articles
9
  * License: GPLv2
10
  * License URI: http://www.gnu.org/licenses/gpl-2.0.html
@@ -68,7 +68,7 @@ if ( version_compare( PHP_VERSION, '5.4', '<' ) ) {
68
 
69
  defined( 'ABSPATH' ) || die( 'Shame on you' );
70
 
71
- define( 'IA_PLUGIN_VERSION', '4.0.0' );
72
  define( 'IA_PLUGIN_PATH_FULL', __FILE__ );
73
  define( 'IA_PLUGIN_PATH', plugin_basename( __FILE__ ) );
74
  define( 'IA_PLUGIN_FILE_BASENAME', pathinfo( __FILE__, PATHINFO_FILENAME ) );
4
  * Description: Add support for Instant Articles for Facebook to your WordPress site.
5
  * Author: Automattic, Dekode, Facebook
6
  * Author URI: https://vip.wordpress.com/plugins/instant-articles/
7
+ * Version: 4.0.1
8
  * Text Domain: instant-articles
9
  * License: GPLv2
10
  * License URI: http://www.gnu.org/licenses/gpl-2.0.html
68
 
69
  defined( 'ABSPATH' ) || die( 'Shame on you' );
70
 
71
+ define( 'IA_PLUGIN_VERSION', '4.0.1' );
72
  define( 'IA_PLUGIN_PATH_FULL', __FILE__ );
73
  define( 'IA_PLUGIN_PATH', plugin_basename( __FILE__ ) );
74
  define( 'IA_PLUGIN_FILE_BASENAME', pathinfo( __FILE__, PATHINFO_FILENAME ) );
meta-box/class-instant-articles-meta-box.php CHANGED
@@ -102,7 +102,7 @@ class Instant_Articles_Meta_Box {
102
  $settings_page_href = Instant_Articles_Wizard::get_url();
103
 
104
  $publishing_settings = Instant_Articles_Option_Publishing::get_option_decoded();
105
- $publish_with_warnings = $publishing_settings[ 'publish_with_warnings' ];
106
  $fb_page_settings = Instant_Articles_Option_FB_Page::get_option_decoded();
107
  $publishing_settings = Instant_Articles_Option_Publishing::get_option_decoded();
108
 
102
  $settings_page_href = Instant_Articles_Wizard::get_url();
103
 
104
  $publishing_settings = Instant_Articles_Option_Publishing::get_option_decoded();
105
+ $publish_with_warnings = isset( $publishing_settings[ 'publish_with_warnings' ] ) ? $publishing_settings[ 'publish_with_warnings' ] : false;
106
  $fb_page_settings = Instant_Articles_Option_FB_Page::get_option_decoded();
107
  $publishing_settings = Instant_Articles_Option_Publishing::get_option_decoded();
108
 
readme.txt CHANGED
@@ -2,8 +2,8 @@
2
  Contributors: trrine, olethomas, bjornjohansen, dekode, automattic, facebook
3
  Tags: instant articles, facebook, mobile
4
  Requires at least: 4.3
5
- Tested up to: 4.6
6
- Stable tag: 4.0.0
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
@@ -85,73 +85,169 @@ Usually simply visiting the permalinks settings page in the WordPress dashboard
85
 
86
  == Changelog ==
87
 
88
- = 3.2 =
89
- * Adds development mode support to post meta box (props simonengelhardt)
90
- * Adds rule configuration for Instagram blockquotes (props everton-rosario)
91
- * Adds rules for galleries (props everton-rosario)
92
- * Migrates some unit tests (props everton-rosario)
93
- * Switches to Facebook Graph SDK (props everton-rosario)
94
- * Improves token invalidation flow (props everton-rosario)
95
- * Fixes use of `the_title` filter (props srtfisher)
96
- * Improves encoding handling (props yssk22)
97
- * Adds post type filter to the post meta box (props technosailor)
98
- * Adds Playbuzz support (props everton-rosario)
99
- * Rename SDK getter to avert apocalypse (props diegoquinteiro)
100
- * Wizard copy improvements (props demoive)
101
- * Fixes issue with captions (props everton-rosario)
102
- * Adds publication block for articles with transformation warnings (props everton-rosario)
103
- * Fix https src attribute on some scripts (props goldenapples)
104
-
105
- = 3.1.3 =
106
- * Fix for expiring token issue
107
- * Fix missing icons
108
- * Fix for empty() array check
109
- * Fix for setup limbo
110
-
111
- = 3.1 =
112
- * New on-boarding flow wizard
113
- * Automattic URL claiming
114
- * Submit for review from wizard
115
- * Improved transformation rules
116
- * Option to submit only articles without warnings
117
- * Jetpack compatibility
118
- * Added Jetpack carousel rules
119
- * Compatibility layer for Get The Image plugin
120
- * Fix for relative URL checking
121
- * Fix for missing subtitles
122
- * Fix for double call of wpautop
123
- * Fix for loadHTML warnings
124
- * Fix for get_cover_media function
125
- * Fix to prevent publishing of password protected posts
126
-
127
- props diegoquinteiro everton-rosario gemedet jacobarriola menzow rinatkhaziev srtfisher
128
-
129
- = 3.0.1 =
130
-
131
- * Fix overzealous escaping
132
-
133
- = 3.0 =
134
-
135
- * Fix versioning - use WP style
136
- * Ignore hyperlinks with a #
137
- * Allow filtering of post types used in the feed
138
- * Use v2.6 of the Facebook API
139
- * Coding standards & whitespace fixes
140
- * Load Facebook SDK over HTTPS
141
- * Avoid crawling of 404s
142
- * Replace social embeds with interactives
143
- * Use submission ID to check status in the admin
144
- * Fix over-zealous escaping
145
-
146
- props markbarnes, paulschreiber, diegoquinteiro, gemedet
147
-
148
- = 2.1 =
149
- * Fixes compatibility with PHP 5.4+
150
- * Bug fixes
151
-
152
- = 2.0 =
153
- * Using Facebook Instant Articles SDK for PHP
154
- * Added API integration
155
-
156
- = 0.1 =
157
- * Initial version
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2
  Contributors: trrine, olethomas, bjornjohansen, dekode, automattic, facebook
3
  Tags: instant articles, facebook, mobile
4
  Requires at least: 4.3
5
+ Tested up to: 4.8
6
+ Stable tag: 4.0.1
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
85
 
86
  == Changelog ==
87
 
88
+ ### 4.0.1 (2017/06/28 18:41 +00:00)
89
+ - [#706](https://github.com/automattic/facebook-instant-articles-wp/pull/706) Check for array index before using it (@diegoquinteiro)
90
+ - [#705](https://github.com/automattic/facebook-instant-articles-wp/pull/705) Enable deletion of JSON AMP Style and removes an undef index (@vkama)
91
+ - [#704](https://github.com/automattic/facebook-instant-articles-wp/pull/704) Fixed several php notices. Also fixed a bug in should_subit_post() (@vkama)
92
+
93
+ ### 4.0.0 (2017/06/27 17:55 +00:00)
94
+ - [#702](https://github.com/automattic/facebook-instant-articles-wp/pull/702) V4.0 (@vkama, @diegoquinteiro, @everton-rosario, @sakatam, @abdusfauzi)
95
+ - [#647](https://github.com/automattic/facebook-instant-articles-wp/pull/647) Fix "Empty string supplied as input" bug (@abdusfauzi)
96
+ - [#680](https://github.com/automattic/facebook-instant-articles-wp/pull/680) Adding support to IA->AMP conversion (@vkama)
97
+ - [#649](https://github.com/automattic/facebook-instant-articles-wp/pull/649) allow markups in footer/copyright (@sakatam)
98
+ - [#643](https://github.com/automattic/facebook-instant-articles-wp/pull/643) Open Graph Ingestion Flow (@diegoquinteiro, @everton-rosario)
99
+ - [#629](https://github.com/automattic/facebook-instant-articles-wp/pull/629) Update Google Analytics compat (@dlackty)
100
+
101
+ ### 3.3.4 (2017/05/10 23:17 +00:00)
102
+ - [#602](https://github.com/automattic/facebook-instant-articles-wp/pull/602) Add post ID to `instant_articles_content` filter (@carlalexander)
103
+ - [#622](https://github.com/automattic/facebook-instant-articles-wp/pull/622) Adds ver=<VERSION_TOKEN> to invalidate plugin resource files (@everton-rosario)
104
+ - [#645](https://github.com/automattic/facebook-instant-articles-wp/pull/645) Fix wp_is_post_autosave() parameter value (@abdusfauzi)
105
+ - [#623](https://github.com/automattic/facebook-instant-articles-wp/pull/623) Allow for alternative file path for json rules (@andykillen)
106
+ - [#624](https://github.com/automattic/facebook-instant-articles-wp/pull/624) fix merge damage (@sakatam)
107
+ - [#616](https://github.com/automattic/facebook-instant-articles-wp/pull/616) Extracted anonymous inline function (@everton-rosario)
108
+ - [#609](https://github.com/automattic/facebook-instant-articles-wp/pull/609) Apester plugin support (@oraricha)
109
+ - [#617](https://github.com/automattic/facebook-instant-articles-wp/pull/617) Switch on/off configuration for enabling comments/likes by default (@everton-rosario)
110
+ - [#612](https://github.com/automattic/facebook-instant-articles-wp/pull/612) Add an option to set a footer (@sakatam)
111
+
112
+ ### 3.3.2 (2017/02/13 19:10 +00:00)
113
+ - [#418](https://github.com/automattic/facebook-instant-articles-wp/pull/418) Call instant_articles_post_published hook to determine published status (@apeschar)
114
+ - [#611](https://github.com/automattic/facebook-instant-articles-wp/pull/611) capability to toggle RTL option (@sakatam)
115
+ - [#604](https://github.com/automattic/facebook-instant-articles-wp/pull/604) Fix typo for $provider_url at L42, L44 and L46 (@abdusfauzi)
116
+
117
+ ### 3.3.1 (2017/01/31 17:33 +00:00)
118
+ - [#598](https://github.com/automattic/facebook-instant-articles-wp/pull/598) Fix typo on script (@diegoquinteiro)
119
+ - [#595](https://github.com/automattic/facebook-instant-articles-wp/pull/595) Add transformer rule for cite element (@davebonds)
120
+ - [#59](https://github.com/automattic/facebook-instant-articles-wp/pull/59) add vimeo.com into oEmbed $provider_name (@abdusfauzi)
121
+ - [#597](https://github.com/automattic/facebook-instant-articles-wp/pull/597) Don't try to load embeds compat unless we're in Instant Articles context (@diegoquinteiro, @rinatkhaziev)
122
+ - [#568](https://github.com/automattic/facebook-instant-articles-wp/pull/568) Add `is_transforming_instant_article()` conditional (@goldenapples)
123
+ - [#287](https://github.com/automattic/facebook-instant-articles-wp/pull/287) Ad de_DE (@swissky)
124
+ - [#578](https://github.com/automattic/facebook-instant-articles-wp/pull/578) Change save_post priority (@cmjaimet)
125
+ - [#592](https://github.com/automattic/facebook-instant-articles-wp/pull/592) Add missing information to composer.json (@onnimonni)
126
+ - [#562](https://github.com/automattic/facebook-instant-articles-wp/pull/562) Add release script (@diegoquinteiro)
127
+
128
+ ### 3.3 (2016/12/16 02:20 +00:00)
129
+ - [#560](https://github.com/automattic/facebook-instant-articles-wp/pull/560) Remove deprecated rules and add rules for imgs inside links (@diegoquinteiro)
130
+ - [#525](https://github.com/automattic/facebook-instant-articles-wp/pull/525) Update WordPress.com stats code to use FBIA SDK. (@philipjohn)
131
+ - [#535](https://github.com/automattic/facebook-instant-articles-wp/pull/535) Fixes #515 - Enables Playbuzz plugin out of the box (@everton-rosario)
132
+
133
+ ### 3.2.2 (2016/11/29 05:15 +00:00)
134
+ - [#543](https://github.com/automattic/facebook-instant-articles-wp/pull/543) Fix variable name (@diegoquinteiro)
135
+
136
+ ### 3.2.1 (2016/11/25 02:58 +00:00)
137
+ - [#538](https://github.com/automattic/facebook-instant-articles-wp/pull/538) Show message on meta-box when post is filtered out (@diegoquinteiro)
138
+ - [#504](https://github.com/automattic/facebook-instant-articles-wp/pull/504) Add instant_articles_should_submit_post filter hook to allow developers control of whether the post should be submitted to IA (@rinatkhaziev)
139
+ - [#498](https://github.com/automattic/facebook-instant-articles-wp/pull/498) Release v3.2 (@philipjohn)
140
+ - [#437](https://github.com/automattic/facebook-instant-articles-wp/pull/437) Blocks publishing of articles with transformation warnings (@diegoquinteiro, @everton-rosario)
141
+ - [#423](https://github.com/automattic/facebook-instant-articles-wp/pull/423) Fixes #205 - Caption in <p> tag (@everton-rosario)
142
+ - [#435](https://github.com/automattic/facebook-instant-articles-wp/pull/435) Setup Wizard copy updates (@demoive)
143
+ - [#497](https://github.com/automattic/facebook-instant-articles-wp/pull/497) Getter was renamed on SDK, updating here too (@diegoquinteiro)
144
+ - [#417](https://github.com/automattic/facebook-instant-articles-wp/pull/417) Support for Playbuzz plugin (@everton-rosario)
145
+ - [#416](https://github.com/automattic/facebook-instant-articles-wp/pull/416) Use the instant_articles_post_types filter when registering metaboxes (@technosailor)
146
+
147
+ ### 3.2 (2016/10/05 14:23 +00:00)
148
+ - [#484](https://github.com/automattic/facebook-instant-articles-wp/pull/484) Apply the second argument to `the_title` (@srtfisher)
149
+ - [#481](https://github.com/automattic/facebook-instant-articles-wp/pull/481) Token Invalidation flow (@everton-rosario)
150
+ - [#462](https://github.com/automattic/facebook-instant-articles-wp/pull/462) Migration from old facebook sdk (@everton-rosario)
151
+ - [#436](https://github.com/automattic/facebook-instant-articles-wp/pull/436) Wp tests migration (@everton-rosario)
152
+ - [#421](https://github.com/automattic/facebook-instant-articles-wp/pull/421) Fixes #408 adding rules for gallery (@everton-rosario)
153
+ - [#376](https://github.com/automattic/facebook-instant-articles-wp/pull/376) Added rule configuration for Instagram embed (@everton-rosario)
154
+ - [#316](https://github.com/automattic/facebook-instant-articles-wp/pull/316) Add development mode support to status meta box (@simonengelhardt)
155
+
156
+ ### 3.1.3 (2016/09/19 17:55 +00:00)
157
+ - [#469](https://github.com/automattic/facebook-instant-articles-wp/pull/469) Release stuff for v3.1.3 (@philipjohn)
158
+ - [#450](https://github.com/automattic/facebook-instant-articles-wp/pull/450) Do not block page selection if URL is not claimed (@diegoquinteiro)
159
+ - [#464](https://github.com/automattic/facebook-instant-articles-wp/pull/464) Fixes #452 - Use of empty() on PHP prior to v5.5 (@demoive)
160
+ - [#465](https://github.com/automattic/facebook-instant-articles-wp/pull/465) Relative CSS to fix missing icons (@everton-rosario)
161
+ - [#458](https://github.com/automattic/facebook-instant-articles-wp/pull/458) Fix expiring token blocking users on page selection state (@diegoquinteiro)
162
+ - [#403](https://github.com/automattic/facebook-instant-articles-wp/pull/403) fix travis.ci build (@sakatam)
163
+ - [#425](https://github.com/automattic/facebook-instant-articles-wp/pull/425) Final release of v3.1 (@philipjohn)
164
+ - [#385](https://github.com/automattic/facebook-instant-articles-wp/pull/385) Implemented compat for the get-the-image plugin (@everton-rosario)
165
+ - [#392](https://github.com/automattic/facebook-instant-articles-wp/pull/392) Load functions which rely on `plugins_loaded` action hook in wp.com e… (@nprasath002)
166
+ - [#402](https://github.com/automattic/facebook-instant-articles-wp/pull/402) Properly implemented the get_cover_media function. (@menzow)
167
+ - [#420](https://github.com/automattic/facebook-instant-articles-wp/pull/420) Article with password protection (@everton-rosario)
168
+ - [#409](https://github.com/automattic/facebook-instant-articles-wp/pull/409) Check for undefined index (@gemedet)
169
+
170
+ ### 3.1 (2016/08/17 20:17 +00:00)
171
+ - [#413](https://github.com/automattic/facebook-instant-articles-wp/pull/413) Fix lingering reference to the old settings page on meta-box (@diegoquinteiro)
172
+ - [#412](https://github.com/automattic/facebook-instant-articles-wp/pull/412) Content update (@diegoquinteiro)
173
+ - [#400](https://github.com/automattic/facebook-instant-articles-wp/pull/400) New flow (@diegoquinteiro, @everton-rosario)
174
+ - [#399](https://github.com/automattic/facebook-instant-articles-wp/pull/399) Revert "Redirect settings" (@philipjohn)
175
+ - [#394](https://github.com/automattic/facebook-instant-articles-wp/pull/394) Apply "the_title" filter (@everton-rosario)
176
+ - [#389](https://github.com/automattic/facebook-instant-articles-wp/pull/389) Redirect settings (@everton-rosario)
177
+ - [#387](https://github.com/automattic/facebook-instant-articles-wp/pull/387) Fix loadHTML warning (@gemedet)
178
+ - [#378](https://github.com/automattic/facebook-instant-articles-wp/pull/378) Added rules for jetpack carousel component (@everton-rosario)
179
+ - [#379](https://github.com/automattic/facebook-instant-articles-wp/pull/379) Don't call wpautop directly when trying to prepare content for transformation. (@rinatkhaziev)
180
+ - [#383](https://github.com/automattic/facebook-instant-articles-wp/pull/383) Fix updating published posts result in error (@chrisadas)
181
+ - [#375](https://github.com/automattic/facebook-instant-articles-wp/pull/375) Commit blocker option - No warnings in transformer to publish (@everton-rosario)
182
+ - [#374](https://github.com/automattic/facebook-instant-articles-wp/pull/374) Jetpack plugin compatibility - Transformation rules (@everton-rosario)
183
+ - [#371](https://github.com/automattic/facebook-instant-articles-wp/pull/371) Migrated take_live parameter to the published (@everton-rosario)
184
+ - [#366](https://github.com/automattic/facebook-instant-articles-wp/pull/366) InteractiveInsideParagraphRule support and configuration (@everton-rosario)
185
+ - [#367](https://github.com/automattic/facebook-instant-articles-wp/pull/367) Add subtitle to $header when rendering post to IA (@jacobarriola)
186
+ - [#360](https://github.com/automattic/facebook-instant-articles-wp/pull/360) Improve rules for Images inside Paragraphs and Interactive elements (@everton-rosario)
187
+ - [#356](https://github.com/automattic/facebook-instant-articles-wp/pull/356) Ensure that relative URL checking has a host and a path. (@srtfisher)
188
+
189
+ ### 3.0.1 (2016/07/13 10:19 +00:00)
190
+ - [#359](https://github.com/automattic/facebook-instant-articles-wp/pull/359) Release 3.0.1 (@philipjohn)
191
+ - [#358](https://github.com/automattic/facebook-instant-articles-wp/pull/358) Revert "escaping and sanitization fixes" (@philipjohn, @diegoquinteiro)
192
+
193
+ ### 3.0 (2016/07/12 12:45 +00:00)
194
+ - [#355](https://github.com/automattic/facebook-instant-articles-wp/pull/355) Release v3.0 (@philipjohn)
195
+ - [#354](https://github.com/automattic/facebook-instant-articles-wp/pull/354) Remove to avoid breaking elements. See #331 (@philipjohn)
196
+ - [#353](https://github.com/automattic/facebook-instant-articles-wp/pull/353) Store and use submission ID when available to fetch the status (@diegoquinteiro)
197
+ - [#329](https://github.com/automattic/facebook-instant-articles-wp/pull/329) always use HTTPS to load JavaScript SDK; update to 2.6 (@paulschreiber)
198
+ - [#327](https://github.com/automattic/facebook-instant-articles-wp/pull/327) use v2.6 of Facebook API (@paulschreiber)
199
+ - [#263](https://github.com/automattic/facebook-instant-articles-wp/pull/263) Escape ampersands before displaying on settings page (@gemedet)
200
+ - [#301](https://github.com/automattic/facebook-instant-articles-wp/pull/301) Check if the global $post object has been set (@srtfisher)
201
+ - [#290](https://github.com/automattic/facebook-instant-articles-wp/pull/290) Fix relative URL issue with oembeds not using absolute URLs (@stuartshields)
202
+ - [#255](https://github.com/automattic/facebook-instant-articles-wp/pull/255) Support <mark> tag (@demoive)
203
+ - [#313](https://github.com/automattic/facebook-instant-articles-wp/pull/313) Fixed statically-called loadHTML() (@gemedet)
204
+ - [#258](https://github.com/automattic/facebook-instant-articles-wp/pull/258) Width and Height for Interactive in default rules (@gemedet)
205
+ - [#343](https://github.com/automattic/facebook-instant-articles-wp/pull/343) Only publish posts (ignores pages and other post types) (@diegoquinteiro)
206
+ - [#342](https://github.com/automattic/facebook-instant-articles-wp/pull/342) Replace SocialEmbed rules with Interactive rules (@diegoquinteiro)
207
+ - [#330](https://github.com/automattic/facebook-instant-articles-wp/pull/330) fix whitespace in select/optgroup tags (@paulschreiber)
208
+ - [#331](https://github.com/automattic/facebook-instant-articles-wp/pull/331) WordPress coding standards fixes (@paulschreiber)
209
+ - [#328](https://github.com/automattic/facebook-instant-articles-wp/pull/328) Fix whitespace to match WordPress coding standards (@paulschreiber)
210
+ - [#285](https://github.com/automattic/facebook-instant-articles-wp/pull/285) Remove hyperlinks beginning with a # (@markbarnes)
211
+ - [#341](https://github.com/automattic/facebook-instant-articles-wp/pull/341) Avoid crawler to cache a 404 (@diegoquinteiro)
212
+ - [#305](https://github.com/automattic/facebook-instant-articles-wp/pull/305) Allow filtering of the post types used in the feed (@philipjohn)
213
+ - [#308](https://github.com/automattic/facebook-instant-articles-wp/pull/308) Fixed error message: Deprecated: Non-static method DOMDocument::loadH… (@everton-rosario)
214
+ - [#286](https://github.com/automattic/facebook-instant-articles-wp/pull/286) Add GitHub Issue and PR templates (@simonengelhardt)
215
+ - [#177](https://github.com/automattic/facebook-instant-articles-wp/pull/177) Use H1 for header title and cover image caption (@gemedet)
216
+
217
+ ### 2.11 (2016/05/17 15:25 +00:00)
218
+ - [#257](https://github.com/automattic/facebook-instant-articles-wp/pull/257) Fix scheduled posts with empty IA content (@Aioros)
219
+ - [#273](https://github.com/automattic/facebook-instant-articles-wp/pull/273) Copy updated to align better with scheduled posts (@demoive)
220
+ - [#271](https://github.com/automattic/facebook-instant-articles-wp/pull/271) Checks if it have the node to be shown as warning body (@everton-rosario)
221
+ - [#264](https://github.com/automattic/facebook-instant-articles-wp/pull/264) Add new application header (@diegoquinteiro)
222
+
223
+ ### 2.10 (2016/04/29 00:01 +00:00)
224
+ - [#179](https://github.com/automattic/facebook-instant-articles-wp/pull/179) Graphics for banner and icon (@demoive)
225
+ - [#183](https://github.com/automattic/facebook-instant-articles-wp/pull/183) Wordpress -> WordPress (@lesterchan)
226
+ - [#213](https://github.com/automattic/facebook-instant-articles-wp/pull/213) Labels and documentation changes re: custom transformer rules (@demoive)
227
+
228
+ ### 2.9 (2016/04/19 17:05 +00:00)
229
+ - [#174](https://github.com/automattic/facebook-instant-articles-wp/pull/174) Prevents <figcaptions> from being added to images that were not saved with captions (@bobderrico80)
230
+ - [#176](https://github.com/automattic/facebook-instant-articles-wp/pull/176) Remove unused image.caption property from ImageRule (@demoive)
231
+ - [#180](https://github.com/automattic/facebook-instant-articles-wp/pull/180) Fix empty articles being uploaded on bulk update (@diegoquinteiro)
232
+ - [#167](https://github.com/automattic/facebook-instant-articles-wp/pull/167) Fixes #116 encoding problem (@everton-rosario)
233
+ - [#173](https://github.com/automattic/facebook-instant-articles-wp/pull/173) Fixed empty link to Instant Articles signup (@demoive)
234
+
235
+ ### 2.8 (2016/04/14 23:23 +00:00)
236
+ - [#151](https://github.com/automattic/facebook-instant-articles-wp/pull/151) Stop publishing drafts (@diegoquinteiro)
237
+
238
+ ### 2.6 (2016/04/13 16:24 +00:00)
239
+ - [#115](https://github.com/automattic/facebook-instant-articles-wp/pull/115) Added information about initial publishing (@msurguy)
240
+ - [#105](https://github.com/automattic/facebook-instant-articles-wp/pull/105) Update template-settings-info.php (@piscis)
241
+
242
+ ### 2.1 (2016/04/11 20:55 +00:00)
243
+ - [#98](https://github.com/automattic/facebook-instant-articles-wp/pull/98) Fixes #72 (@diegoquinteiro)
244
+ - [#90](https://github.com/automattic/facebook-instant-articles-wp/pull/90) Change readme.txt to reflect changes in 2.0 (@diegoquinteiro)
245
+ - [#87](https://github.com/automattic/facebook-instant-articles-wp/pull/87) Clean unused files + fixes for 5.4 compatibility (@diegoquinteiro)
246
+
247
+ ### 2.0 (2016/04/06 17:45 +00:00)
248
+ - [#70](https://github.com/automattic/facebook-instant-articles-wp/pull/70) Use SDK engine (@diegoquinteiro)
249
+
250
+ ### 0.2 (2016/03/09 19:44 +00:00)
251
+ - [#41](https://github.com/automattic/facebook-instant-articles-wp/pull/41) Add support for subtitles through the filter instant_articles_subtitle (@bjornjohansen)
252
+ - [#39](https://github.com/automattic/facebook-instant-articles-wp/pull/39) Jetpack compat: YouTube and Facebook embeds (@bjornjohansen)
253
+ - [#22](https://github.com/automattic/facebook-instant-articles-wp/pull/22) Migrate the wpcom-helper.php from WordPress.com. (@philipjohn)
wizard/class-instant-articles-option-amp.php CHANGED
@@ -37,6 +37,7 @@ class Instant_Articles_Option_AMP extends Instant_Articles_Option {
37
  Instant_Articles_AMP_Markup::SETTING_STYLE => array(
38
  'label' => 'Instant Article JSON Style',
39
  'description' => 'Please paste the contents of the Style JSON file (<a href="https://developers.facebook.com/docs/instant-articles/other-formats#style" target="_blank">downloaded from the Publishing Tools</a>)',
 
40
  'render' => 'textarea',
41
  ),
42
 
@@ -63,7 +64,7 @@ class Instant_Articles_Option_AMP extends Instant_Articles_Option {
63
  public function sanitize_option_fields( $field_values ) {
64
  $old_settings = Instant_Articles_AMP_Markup::get_settings();
65
 
66
- if ( isset( $field_values[ Instant_Articles_AMP_Markup::SETTING_STYLE ] ) ) {
67
  if ( ! Instant_Articles_AMP_Markup::validate_json( $field_values[ Instant_Articles_AMP_Markup::SETTING_STYLE ] ) ) {
68
  add_settings_error(
69
  Instant_Articles_AMP_Markup::SETTING_STYLE,
@@ -72,7 +73,9 @@ class Instant_Articles_Option_AMP extends Instant_Articles_Option {
72
  );
73
 
74
  $field_values[ Instant_Articles_AMP_Markup::SETTING_STYLE ] =
75
- $old_settings[ Instant_Articles_AMP_Markup::SETTING_STYLE ];
 
 
76
  }
77
  }
78
 
37
  Instant_Articles_AMP_Markup::SETTING_STYLE => array(
38
  'label' => 'Instant Article JSON Style',
39
  'description' => 'Please paste the contents of the Style JSON file (<a href="https://developers.facebook.com/docs/instant-articles/other-formats#style" target="_blank">downloaded from the Publishing Tools</a>)',
40
+ 'default' => '',
41
  'render' => 'textarea',
42
  ),
43
 
64
  public function sanitize_option_fields( $field_values ) {
65
  $old_settings = Instant_Articles_AMP_Markup::get_settings();
66
 
67
+ if ( isset( $field_values[ Instant_Articles_AMP_Markup::SETTING_STYLE ] ) && !empty($field_values[ Instant_Articles_AMP_Markup::SETTING_STYLE ]) ) {
68
  if ( ! Instant_Articles_AMP_Markup::validate_json( $field_values[ Instant_Articles_AMP_Markup::SETTING_STYLE ] ) ) {
69
  add_settings_error(
70
  Instant_Articles_AMP_Markup::SETTING_STYLE,
73
  );
74
 
75
  $field_values[ Instant_Articles_AMP_Markup::SETTING_STYLE ] =
76
+ isset($old_settings[ Instant_Articles_AMP_Markup::SETTING_STYLE ])
77
+ ? $old_settings[ Instant_Articles_AMP_Markup::SETTING_STYLE ]
78
+ : '';
79
  }
80
  }
81
 
wizard/templates/advanced-template.php CHANGED
@@ -21,7 +21,7 @@
21
  <?php settings_fields( Instant_Articles_Option::PAGE_OPTION_GROUP ); ?>
22
  <?php do_settings_sections( Instant_Articles_Option_FB_Page::OPTION_KEY ); ?>
23
  <?php $fb_page_settings = Instant_Articles_Option_FB_Page::get_option_decoded(); ?>
24
- <div <?php if ( ! $fb_page_settings[ "page_id" ] ) : ?>style="display: none;"<?php endif; ?>>
25
  <hr />
26
  <p>Configure settings for your styles, ads, analytics and publishing in Instant Articles. Review our <a href="https://developers.facebook.com/docs/instant-articles" target="_blank">developer documentation</a> to learn more.</p>
27
  <hr />
21
  <?php settings_fields( Instant_Articles_Option::PAGE_OPTION_GROUP ); ?>
22
  <?php do_settings_sections( Instant_Articles_Option_FB_Page::OPTION_KEY ); ?>
23
  <?php $fb_page_settings = Instant_Articles_Option_FB_Page::get_option_decoded(); ?>
24
+ <div <?php if ( isset( $fb_page_settings[ 'page_id' ] ) && ! $fb_page_settings[ 'page_id' ] ) : ?>style="display: none;"<?php endif; ?>>
25
  <hr />
26
  <p>Configure settings for your styles, ads, analytics and publishing in Instant Articles. Review our <a href="https://developers.facebook.com/docs/instant-articles" target="_blank">developer documentation</a> to learn more.</p>
27
  <hr />