Commit 8c702379 authored by Simon's avatar Simon

In progress

parent 8f1008a5
PROJECT=dev-biuro
IMAGE_NGINX=kbenassm/nginx-brotli-tls13
IMAGE_NGINX=fholzer/nginx-brotli
IMAGE_MYSQL=mariadb:10.3
IMAGE_WORDPRESS=wordpress:php7.3-fpm
IMAGE_WORDPRESS_CLI=wordpress:cli-php7.3
......
......@@ -2,7 +2,7 @@
Contributors: matt, ryan, andy, mdawaffe, tellyworth, josephscott, lessbloat, eoigal, cfinke, automattic, jgs, procifer, stephdau
Tags: akismet, comments, spam, antispam, anti-spam, anti spam, comment moderation, comment spam, contact form spam, spam comments
Requires at least: 4.0
Tested up to: 5.2
Tested up to: 5.3
Stable tag: 4.1.3
License: GPLv2 or later
......
......@@ -3,7 +3,7 @@
Plugin Name: Pods - Custom Content Types and Fields
Plugin URI: https://pods.io/
Description: Pods is a framework for creating, managing, and deploying customized content types and fields
Version: 2.7.16.1
Version: 2.7.16.2
Author: Pods Framework Team
Author URI: https://pods.io/about/
Text Domain: pods
......@@ -36,7 +36,7 @@ if ( defined( 'PODS_VERSION' ) || defined( 'PODS_DIR' ) ) {
add_action( 'init', 'pods_deactivate_pods_ui' );
} else {
// Current version
define( 'PODS_VERSION', '2.7.16.1' );
define( 'PODS_VERSION', '2.7.16.2' );
// Version tracking between DB updates themselves
define( 'PODS_DB_VERSION', '2.3.5' );
......
......@@ -5,7 +5,7 @@ Tags: pods, custom post types, custom taxonomies, content types, custom fields,
Requires at least: 4.5
Tested up to: 5.3
Requires PHP: 5.3
Stable tag: 2.7.16.1
Stable tag: 2.7.16.2
License: GPLv2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
......@@ -190,6 +190,10 @@ We are also available through our [Live Slack Chat](https://pods.io/chat/) to he
== Changelog ==
= 2.7.16.2 - November 14th 2019 =
* Fixed: The last SVN tag was temporarily missing files, this release just ensures people get the update that has all files.
= 2.7.16.1 - November 13th 2019 =
* Fixed: Reverted changes in #5289 to auto templates that introduced breaking changes. We will revisit this in a future maintenance release. #5531
......
......@@ -81,6 +81,7 @@ class PLL_Admin_Classic_Editor {
$dropdown_html = $dropdown->walk(
$this->model->get_languages_list(),
-1,
array(
'name' => $id,
'class' => 'post_lang_choice tags-input',
......
......@@ -188,7 +188,7 @@ class PLL_Admin_Filters_Columns {
</div>
</fieldset>',
esc_html__( 'Language', 'polylang' ),
$dropdown->walk( $elements, array( 'name' => 'inline_lang_choice', 'id' => '' ) ) // phpcs:ignore WordPress.Security.EscapeOutput
$dropdown->walk( $elements, -1, array( 'name' => 'inline_lang_choice', 'id' => '' ) ) // phpcs:ignore WordPress.Security.EscapeOutput
);
}
return $column;
......
......@@ -57,6 +57,7 @@ class PLL_Admin_Filters_Media extends PLL_Admin_Filters_Post_Base {
'input' => 'html',
'html' => $dropdown->walk(
$this->model->get_languages_list(),
-1,
array(
'name' => sprintf( 'attachments[%d][language]', $post_id ),
'class' => 'media_lang_choice',
......
......@@ -79,6 +79,7 @@ class PLL_Admin_Filters_Term {
$dropdown_html = $dropdown->walk(
$this->model->get_languages_list(),
-1,
array(
'name' => 'term_lang_choice',
'value' => 'term_id',
......@@ -145,6 +146,7 @@ class PLL_Admin_Filters_Term {
$dropdown_html = $dropdown->walk(
$this->model->get_languages_list(),
-1,
array(
'name' => 'term_lang_choice',
'value' => 'term_id',
......
......@@ -66,6 +66,7 @@ class PLL_Admin_Filters extends PLL_Filters {
array( (object) array( 'slug' => 0, 'name' => __( 'All languages', 'polylang' ) ) ),
$this->model->get_languages_list()
),
-1,
array(
'name' => $widget->id . '_lang_choice',
'class' => 'tags-input pll-lang-choice',
......
......@@ -33,7 +33,7 @@ class Polylang {
$install = new PLL_Install( POLYLANG_BASENAME );
// Stopping here if we are going to deactivate the plugin ( avoids breaking rewrite rules )
if ( $install->is_deactivation() ) {
if ( $install->is_deactivation() || ! $install->can_activate() ) {
return;
}
......
......@@ -184,7 +184,7 @@ class PLL_Switcher {
* @param string $html html returned/outputted by the template tag
* @param array $args arguments passed to the template tag
*/
$out = apply_filters( 'pll_the_languages', $walker->walk( $elements, $args ), $args );
$out = apply_filters( 'pll_the_languages', $walker->walk( $elements, -1, $args ), $args );
// Javascript to switch the language when using a dropdown list
if ( $args['dropdown'] ) {
......
......@@ -52,6 +52,7 @@ class PLL_Walker_Dropdown extends Walker {
* Starts the output of the dropdown list
*
* @since 1.2
* @since 2.6.7 Use $max_depth and ...$args parameters to follow the move of WP 5.3
*
* List of parameters accepted in $args:
*
......@@ -63,12 +64,30 @@ class PLL_Walker_Dropdown extends Walker {
* class => the class attribute
* disabled => disables the dropdown if set to 1
*
* @param array $elements elements to display
* @param array $args
* @return string
* @param array $elements An array of elements.
* @param int $max_depth The maximum hierarchical depth.
* @param mixed ...$args Additional arguments.
* @return string The hierarchical item output.
*/
public function walk( $elements, $args = array() ) {
public function walk( $elements, $max_depth, ...$args ) { // // phpcs:ignore WordPressVIPMinimum.Classes.DeclarationCompatibility.DeclarationCompatibility
$output = '';
if ( is_array( $max_depth ) ) {
// Backward compatibility with Polylang < 2.6.7
if ( WP_DEBUG ) {
trigger_error( // phpcs:ignore WordPress.PHP.DevelopmentFunctions
sprintf(
'%s was called incorrectly. The method expects an integer as second parameter since Polylang 2.6.7',
__METHOD__
)
);
}
$args = $max_depth;
$max_depth = -1;
} else {
$args = isset( $args[0] ) ? $args[0] : array();
}
$args = wp_parse_args( $args, array( 'value' => 'slug', 'name' => 'lang_choice' ) );
if ( ! empty( $args['flag'] ) ) {
......@@ -86,7 +105,7 @@ class PLL_Walker_Dropdown extends Walker {
isset( $args['id'] ) && ! $args['id'] ? '' : ' id="' . ( empty( $args['id'] ) ? $name : esc_attr( $args['id'] ) ) . '"',
empty( $args['class'] ) ? '' : ' class="' . esc_attr( $args['class'] ) . '"',
disabled( empty( $args['disabled'] ), false, false ),
parent::walk( $elements, -1, $args )
parent::walk( $elements, $max_depth, $args )
);
return $output;
......
......@@ -54,12 +54,30 @@ class PLL_Walker_List extends Walker {
* Overrides Walker:walk to set depth argument
*
* @since 1.2
* @since 2.6.7 Use $max_depth and ...$args parameters to follow the move of WP 5.3
*
* @param array $elements elements to display
* @param array $args
* @return string
* @param array $elements An array of elements.
* @param int $max_depth The maximum hierarchical depth.
* @param mixed ...$args Additional arguments.
* @return string The hierarchical item output.
*/
public function walk( $elements, $args = array() ) {
return parent::walk( $elements, -1, $args );
public function walk( $elements, $max_depth, ...$args ) { // phpcs:ignore WordPressVIPMinimum.Classes.DeclarationCompatibility.DeclarationCompatibility
if ( is_array( $max_depth ) ) {
// Backward compatibility with Polylang < 2.6.7
if ( WP_DEBUG ) {
trigger_error( // phpcs:ignore WordPress.PHP.DevelopmentFunctions
sprintf(
'%s was called incorrectly. The method expects an integer as second parameter since Polylang 2.6.7',
__METHOD__
)
);
}
$args = $max_depth;
$max_depth = -1;
} else {
$args = isset( $args[0] ) ? $args[0] : array();
}
return parent::walk( $elements, $max_depth, $args );
}
}
......@@ -8,34 +8,67 @@
class PLL_Install extends PLL_Install_Base {
/**
* Plugin activation for multisite
* Checks min PHP and WP version, displays a notice if a requirement is not met.
*
* @since 0.1
*
* @param bool $networkwide
* @since 2.6.7
*/
public function activate( $networkwide ) {
public function can_activate() {
global $wp_version;
Polylang::define_constants();
load_plugin_textdomain( 'polylang', false, basename( POLYLANG_DIR ) . '/languages' ); // plugin i18n
if ( version_compare( PHP_VERSION, PLL_MIN_PHP_VERSION, '<' ) ) {
add_action( 'admin_notices', array( $this, 'php_version_notice' ) );
return false;
}
if ( version_compare( $wp_version, PLL_MIN_WP_VERSION, '<' ) ) {
die(
add_action( 'admin_notices', array( $this, 'wp_version_notice' ) );
return false;
}
return true;
}
/**
* Displays a notice if PHP min version is not met.
*
* @since 2.6.7
*/
public function php_version_notice() {
load_plugin_textdomain( 'polylang', false, basename( POLYLANG_DIR ) . '/languages' ); // Plugin i18n.
printf(
'<div class="error"><p>%s</p></div>',
sprintf(
'<p style = "font-family: sans-serif; font-size: 12px; color: #333; margin: -5px">%s</p>',
/* translators: 1: Plugin name 2: Current PHP version 3: Required PHP version */
esc_html__( '%1$s has deactivated itself because you are using an old PHP version. You are using using PHP %2$s. %1$s requires PHP %3$s.', 'polylang' ),
esc_html( POLYLANG ),
PHP_VERSION,
esc_html( PLL_MIN_PHP_VERSION )
)
);
}
/**
* Displays a notice if WP min version is not met.
*
* @since 2.6.7
*/
public function wp_version_notice() {
global $wp_version;
load_plugin_textdomain( 'polylang', false, basename( POLYLANG_DIR ) . '/languages' ); // Plugin i18n.
printf(
'<div class="error"><p>%s</p></div>',
sprintf(
/* translators: %1$s and %2$s are WordPress version numbers */
esc_html__( 'You are using WordPress %1$s. Polylang requires at least WordPress %2$s.', 'polylang' ),
/* translators: 1: Plugin name 2: Current WordPress version 3: Required WordPress version */
esc_html__( '%1$s has deactivated itself because you are using an old WordPress version. You are using using WordPress %2$s. %1$s requires at least WordPress %3$s.', 'polylang' ),
esc_html( POLYLANG ),
esc_html( $wp_version ),
PLL_MIN_WP_VERSION // phpcs:ignore WordPress.Security.EscapeOutput
)
esc_html( PLL_MIN_WP_VERSION )
)
);
}
$this->do_for_all_blogs( 'activate', $networkwide );
}
/**
* Get default Polylang options
......
......@@ -3,7 +3,7 @@
/**
Plugin Name: Polylang
Plugin URI: https://polylang.pro
Version: 2.6.6
Version: 2.6.7
Author: WP SYNTEX
Author uri: https://polylang.pro
Description: Adds multilingual capability to WordPress
......@@ -51,8 +51,9 @@ if ( defined( 'POLYLANG_BASENAME' ) ) {
}
} else {
// Go on loading the plugin
define( 'POLYLANG_VERSION', '2.6.6' );
define( 'POLYLANG_VERSION', '2.6.7' );
define( 'PLL_MIN_WP_VERSION', '4.7' );
define( 'PLL_MIN_PHP_VERSION', '5.6' );
define( 'POLYLANG_FILE', __FILE__ ); // this file
define( 'POLYLANG_BASENAME', plugin_basename( POLYLANG_FILE ) ); // plugin name as known by WP
......
......@@ -4,7 +4,8 @@ Donate link: https://polylang.pro
Tags: multilingual, bilingual, translate, translation, language, multilanguage, international, localization
Requires at least: 4.7
Tested up to: 5.3
Stable tag: 2.6.6
Requires PHP: 5.6
Stable tag: 2.6.7
License: GPLv3 or later
Making WordPress multilingual
......@@ -41,7 +42,7 @@ Don't hesitate to [give your feedback](http://wordpress.org/support/view/plugin-
== Installation ==
1. Make sure you are using WordPress 4.7 or later and that your server is running PHP 5.2.4 or later (same requirement as WordPress itself)
1. Make sure you are using WordPress 4.7 or later and that your server is running PHP 5.6 or later (same requirement as WordPress itself)
1. If you tried other multilingual plugins, deactivate them before activating Polylang, otherwise, you may get unexpected results!
1. Install and activate the plugin as usual from the 'Plugins' menu in WordPress.
1. Go to the languages settings page and create the languages you need
......@@ -76,6 +77,11 @@ Don't hesitate to [give your feedback](http://wordpress.org/support/view/plugin-
== Changelog ==
= 2.6.7 (2019-11-14) =
* Require PHP 5.6
* Fix PHP warning in WP 5.3
= 2.6.6 (2019-11-12) =
* Pro: Fix wrong ajax url when using one domain per language
......
......@@ -701,10 +701,10 @@ class WPSEO_OpenGraph {
$post = get_post();
$pub = mysql2date( DATE_W3C, $post->post_date_gmt, false );
$pub = mysql2date( DATE_W3C, $post->post_date, false );
$this->og_tag( 'article:published_time', $pub );
$mod = mysql2date( DATE_W3C, $post->post_modified_gmt, false );
$mod = mysql2date( DATE_W3C, $post->post_modified, false );
if ( $mod !== $pub ) {
$this->og_tag( 'article:modified_time', $mod );
$this->og_tag( 'og:updated_time', $mod );
......
......@@ -59,8 +59,8 @@ class WPSEO_Schema_Article implements WPSEO_Graph_Piece {
'isPartOf' => array( '@id' => $this->context->canonical . WPSEO_Schema_IDs::WEBPAGE_HASH ),
'author' => array( '@id' => WPSEO_Schema_Utils::get_user_schema_id( $post->post_author, $this->context ) ),
'headline' => get_the_title(),
'datePublished' => mysql2date( DATE_W3C, $post->post_date_gmt, false ),
'dateModified' => mysql2date( DATE_W3C, $post->post_modified_gmt, false ),
'datePublished' => mysql2date( DATE_W3C, $post->post_date, false ),
'dateModified' => mysql2date( DATE_W3C, $post->post_modified, false ),
'commentCount' => $comment_count['approved'],
'mainEntityOfPage' => array( '@id' => $this->context->canonical . WPSEO_Schema_IDs::WEBPAGE_HASH ),
);
......
......@@ -68,8 +68,8 @@ class WPSEO_Schema_WebPage implements WPSEO_Graph_Piece {
$this->add_image( $data );
$post = get_post( $this->context->id );
$data['datePublished'] = mysql2date( DATE_W3C, $post->post_date_gmt, false );
$data['dateModified'] = mysql2date( DATE_W3C, $post->post_modified_gmt, false );
$data['datePublished'] = mysql2date( DATE_W3C, $post->post_date, false );
$data['dateModified'] = mysql2date( DATE_W3C, $post->post_modified, false );
if ( get_post_type( $post ) === 'post' ) {
$data = $this->add_author( $data, $post );
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment