ARVE Advanced Responsive Video Embedder (YouTube, Vimeo, HTML5 Video …) - Version 9.0.0-beta7

Version Description

Download this release

Release Info

Developer nico23
Plugin Icon 128x128 ARVE Advanced Responsive Video Embedder (YouTube, Vimeo, HTML5 Video …)
Version 9.0.0-beta7
Comparing to
See all releases

Code changes from version 9.0.0-beta6 to 9.0.0-beta7

advanced-responsive-video-embedder.php CHANGED
@@ -3,7 +3,7 @@
3
  * Plugin Name: ARVE Advanced Responsive Video Embedder
4
  * Plugin URI: https://nextgenthemes.com/plugins/arve-pro/
5
  * Description: Easy responsive video embeds via URL (like WordPress) or Shortcodes. Supports almost anything you can imagine.
6
- * Version: 9.0.0-beta6
7
  * Author: Nicolas Jonas
8
  * Author URI: https://nextgenthemes.com
9
  * License: GPL-3.0
@@ -21,7 +21,7 @@
21
 
22
  namespace Nextgenthemes\ARVE;
23
 
24
- const VERSION = '9.0.0-beta6';
25
  const PRO_VERSION_REQUIRED = '5.0.0-beta5';
26
  const NUM_TRACKS = 3;
27
  const PLUGIN_FILE = __FILE__;
3
  * Plugin Name: ARVE Advanced Responsive Video Embedder
4
  * Plugin URI: https://nextgenthemes.com/plugins/arve-pro/
5
  * Description: Easy responsive video embeds via URL (like WordPress) or Shortcodes. Supports almost anything you can imagine.
6
+ * Version: 9.0.0-beta7
7
  * Author: Nicolas Jonas
8
  * Author URI: https://nextgenthemes.com
9
  * License: GPL-3.0
21
 
22
  namespace Nextgenthemes\ARVE;
23
 
24
+ const VERSION = '9.0.0-beta7';
25
  const PRO_VERSION_REQUIRED = '5.0.0-beta5';
26
  const NUM_TRACKS = 3;
27
  const PLUGIN_FILE = __FILE__;
php/functions-misc.php CHANGED
@@ -36,17 +36,17 @@ function check_filetype( $url, $ext ) {
36
  }
37
 
38
  /**
39
- * Calculates seconds based on youtube times
40
  *
41
- * @param string $yttime The '1h25m13s' part of youtube URLs.
42
  *
43
  * @return int Starttime in seconds.
44
  */
45
  function youtube_time_to_seconds( $yttime ) {
46
 
47
- $matches['h'] = 0;
48
- $matches['m'] = 0;
49
- $matches['s'] = 0;
50
 
51
  $pattern = '/' .
52
  '(?<h>[0-9]+h)?' .
@@ -55,6 +55,12 @@ function youtube_time_to_seconds( $yttime ) {
55
 
56
  preg_match( $pattern, $yttime, $matches );
57
 
 
 
 
 
 
 
58
  return ( (int) $matches['h'] * 60 * 60 ) +
59
  ( (int) $matches['m'] * 60 ) +
60
  (int) $matches['s'];
36
  }
37
 
38
  /**
39
+ * Calculates seconds based on youtube times if needed
40
  *
41
+ * @param string $yttime The 't=1h25m13s' or t=123 part of youtube URLs.
42
  *
43
  * @return int Starttime in seconds.
44
  */
45
  function youtube_time_to_seconds( $yttime ) {
46
 
47
+ if ( \is_numeric( $yttime ) ) {
48
+ return $yttime;
49
+ }
50
 
51
  $pattern = '/' .
52
  '(?<h>[0-9]+h)?' .
55
 
56
  preg_match( $pattern, $yttime, $matches );
57
 
58
+ foreach( [ 'h', 'm', 's' ] as $m ) {
59
+ if ( ! isset( $matches[ $m ] ) ) {
60
+ $matches[ $m ] = 0;
61
+ }
62
+ }
63
+
64
  return ( (int) $matches['h'] * 60 * 60 ) +
65
  ( (int) $matches['m'] * 60 ) +
66
  (int) $matches['s'];
readme.txt CHANGED
@@ -5,7 +5,7 @@ Tags: YouTube, Vimeo, lazyload, thumbnail, video, responsive, embeds, video-embe
5
  Requires at least: 4.4.0
6
  Tested up to: 5.6
7
  Requires PHP: 5.6
8
- Stable tag: 9.0.0-beta6
9
  License: GPL-3.0
10
  License URI: https://www.gnu.org/licenses/gpl-3.0.html
11
 
@@ -16,6 +16,10 @@ Easy responsive video embeds via URLs or shortcodes. Perfect drop-in replacement
16
  * [ARVE Pro addon changelog](https://nextgenthemes.com/plugins/arve-pro/changelog/)
17
  * [ARVE AMP addon changelog](https://nextgenthemes.com/plugins/arve-amp/)
18
 
 
 
 
 
19
  ### 2020-12-01 9.0.0-beta6 ###
20
 
21
  * Fix: Url parameters from settings page not working.
@@ -62,6 +66,57 @@ Removed:
62
 
63
  Probably things I forgot about, working on this for ~1 year
64
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
65
  ### 2019-01-23 - 8.10.4 ###
66
 
67
  * Fix: PHP compatibility lowered to official 5.3 as there was accidentally 5.4+ code used. Make sure you are on PHP 7.3 or at least 5.6 for the upcoming future as WP itself will require 5.6 this year. Its also insecure to run on those outdated versions: https://secure.php.net/supported-versions.php.
@@ -1157,8 +1212,6 @@ This plugin is financed by sales of the [Pro Addon](https://nextgenthemes.com/pl
1157
 
1158
  ### [Pro Addon](https://nextgenthemes.com/plugins/arve-pro/) ###
1159
 
1160
- Limited time price experiment: **44% off** first year with discount code `wporg`
1161
-
1162
  * **Disable links in embeds (killer feature!)**<br>
1163
  For example: Clicking on a title in a YouTube embed will not open a new popup/tab/window. **Prevent video hosts to lead your visitors away from your site!** Note this also breaks sharing functionality and is not possible when the provider requires flash. Try it on [this page](https://nextgenthemes.com/plugins/arve-pro/). Right click on links still works.
1164
  * **Lazyload mode**<br>
@@ -1171,12 +1224,12 @@ Limited time price experiment: **44% off** first year with discount code `wporg`
1171
  * Automatic or custom titles on top of your thumbnails
1172
  * 'Expand on click' feature
1173
  * 3 hover styles
1174
- * 2 play icon styles to choose from
1175
  * Responsive thumbnails using cutting edge HTML5 technology
1176
  * **Feel good about yourself**<br>
1177
- for supporting my 5+ years work on this plugin. Tons of hours, weekends … always worked on improving it.
1178
  * Show the latest video of a YouTube channel by using the channel URL (updated/cached hourly)
1179
- * **[Get the ARVE Pro Addon](https://nextgenthemes.com/plugins/arve-pro/)**
1180
 
1181
  ### ARVE AMP Addon ###
1182
 
5
  Requires at least: 4.4.0
6
  Tested up to: 5.6
7
  Requires PHP: 5.6
8
+ Stable tag: 9.0.0-beta7
9
  License: GPL-3.0
10
  License URI: https://www.gnu.org/licenses/gpl-3.0.html
11
 
16
  * [ARVE Pro addon changelog](https://nextgenthemes.com/plugins/arve-pro/changelog/)
17
  * [ARVE AMP addon changelog](https://nextgenthemes.com/plugins/arve-amp/)
18
 
19
+ ### 2020-12-02 9.0.0-beta7 ###
20
+
21
+ * Fix: YouTube timestamp urls not working with only seconds `t=1234`.
22
+
23
  ### 2020-12-01 9.0.0-beta6 ###
24
 
25
  * Fix: Url parameters from settings page not working.
66
 
67
  Probably things I forgot about, working on this for ~1 year
68
 
69
+ ### 2020-10-10 - 8.10.28 ###
70
+
71
+ * Tested and marked as compatible with WP 5.5.1
72
+
73
+ ### 2020-08-02 - 8.10.27 ###
74
+
75
+ * Fix: **SORRY!** message about beta testing was **not intended** to show hourly it was intended to show only once per user.
76
+ * Fix: Link in that messages was also to a 404 page, can it get worse?
77
+
78
+ ### 2020-07-25 - 8.10.24 ###
79
+
80
+ * Fix: `embedURL` SEO output.
81
+
82
+ ### 2020-05-14 - 8.10.23 ###
83
+
84
+ * Improved: Automatically set HTML5 videos that are set to autoplay to also be muted so they may play as browsers no longer allow unmuted autoplay.
85
+
86
+ ### 2019-11-05 - 8.10.20 ###
87
+
88
+ * Big version update with Gutenberg Block is coming [please help testing](https://nextgenthemes.com/plugins/arve/help-testing-the-beta-version/)
89
+
90
+ ### 2019-10-18 - 8.10.15 ###
91
+
92
+ * Fix: Force shortcode args to be array. To prevent issues.
93
+
94
+ ### 2019-10-09 - 8.10.13 ###
95
+
96
+ * Removed outdated link in widget.
97
+
98
+ ### 2019-10-01 - 8.10.12 ###
99
+
100
+ * Improved: Allow for manually srcset with `img_srcset` with the Pro Addon.
101
+
102
+ ### 2019-08-29 - 8.10.11 ###
103
+
104
+ * Removed vendor dir from Git versioning.
105
+
106
+ ### 2019-08-29 - 8.10.10 ###
107
+
108
+ Just a small readme update and checking new release script, making sure everything works and everyone is on the latest stable version.
109
+
110
+ ### 2019-08-19 - 8.10.8 ###
111
+
112
+ * Improved: Switch Youku embeds to https set to default 16:9 aspect ratio.
113
+ * Improved: added `allow-popups-to-escape-sandbox` to sandbox attribute. This eliminates the need for `sandbox="false"` for Vimeo action links to work. And just in general I think its a good idea.
114
+
115
+ ### 2019-07-31 - 8.10.6 ###
116
+
117
+ * Fix: Vimeo Action links not working correctly in Chrome when Sandbox is enabled. You can fix this by adding `sandbox="false"` to your shortcodes. But the ARVE Pro "disable links" option will no longer work.
118
+ * Improved: Deprecated `requires_flash` attribute and `Iframe Flash` option. Replaced is the new `sandbox` shortcode attribute.
119
+
120
  ### 2019-01-23 - 8.10.4 ###
121
 
122
  * Fix: PHP compatibility lowered to official 5.3 as there was accidentally 5.4+ code used. Make sure you are on PHP 7.3 or at least 5.6 for the upcoming future as WP itself will require 5.6 this year. Its also insecure to run on those outdated versions: https://secure.php.net/supported-versions.php.
1212
 
1213
  ### [Pro Addon](https://nextgenthemes.com/plugins/arve-pro/) ###
1214
 
 
 
1215
  * **Disable links in embeds (killer feature!)**<br>
1216
  For example: Clicking on a title in a YouTube embed will not open a new popup/tab/window. **Prevent video hosts to lead your visitors away from your site!** Note this also breaks sharing functionality and is not possible when the provider requires flash. Try it on [this page](https://nextgenthemes.com/plugins/arve-pro/). Right click on links still works.
1217
  * **Lazyload mode**<br>
1224
  * Automatic or custom titles on top of your thumbnails
1225
  * 'Expand on click' feature
1226
  * 3 hover styles
1227
+ * 3 play icon styles to choose from
1228
  * Responsive thumbnails using cutting edge HTML5 technology
1229
  * **Feel good about yourself**<br>
1230
+ for supporting my 8+ years work on this plugin. Tons of hours, weekends … always worked on improving it.
1231
  * Show the latest video of a YouTube channel by using the channel URL (updated/cached hourly)
1232
+ * **[Get the ARVE Pro Addon](https://nextgenthemes.com/plugins/arve-pro/)** 10% off first year with discount code `wporg`
1233
 
1234
  ### ARVE AMP Addon ###
1235