Sync plugins from current page

Signed-off-by: Adrian Nöthlich <git@promasu.tech>
This commit is contained in:
2019-09-11 19:08:46 +02:00
parent 85d41e4216
commit 8515ff9587
1847 changed files with 505469 additions and 0 deletions

View File

@@ -0,0 +1,21 @@
MIT License
Copyright (c) 2019 Alexander Goller
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

View File

@@ -0,0 +1 @@
1.1.5

View File

@@ -0,0 +1,36 @@
=== Version Info ===
Contributors: alpipego
Tags: admin, version, php, mysql, server, support
Stable tag: 1.1.5
License: MIT
Requires at least: 2.3.0
Tested up to: 5.2
Show current WordPress, PHP, Web Server and MySQL versions in admin footer
== Description ==
This plugin displays the current WordPress version number along with the following environment in the admin footer:
* Current WordPress version info, when there is an update available it displays the current version and the latest version side by side
* PHP version
* Web Server used
* MySQL version
= What's the reason for building this Plugin =
I always disliked the fact that WordPress does not display the current version number in the footer whenever there is a new release.
If you are a plugin developer and a user experiences a problem, they could install this plugin and send you a screenshot of their admin footer (or copy the text of course) to inform you about the cornerstones of their setup.
I built this [Multivariate Virtual Machine for Debugging WordPress Plugin](https://github.com/alpipego/wp-version) that allows you to quickly change PHP versions, the used web server (nginx or Apache) and WordPress core, plugin and theme versions. As it is intended to quickly change environment variables, this plugin helped me keep track of what exactly I am testing at the moment.
== Screenshots ==
1. Default admin footer showing you the current (latest) Wordpress version
2. After activation you will get a lot more info in your admin footer
3. Default admin footer when you are not running the latest version of WordPress
4. If this plugin is active, you will see your currently installed version along the update info (and the additional info this plugin provides)
== Installation ==
1. Upload the plugin to your plugins directory (possibly `/wp-content/plugins/`), or install the plugin through the WordPress plugins screen directly.
1. Activate the plugin through the 'Plugins' screen in WordPress

View File

@@ -0,0 +1,46 @@
<?php
/**
* WordPress Version Info
*
* @package wp-version-info
* @author Alexander Goller <alpipego@gmail.com>
* @copyright 2019 Alexander Goller
* @license MIT
*
* @wordpress-plugin
*
* Plugin Name: WordPress Version Info
* Plugin URI: https://wordpress.org/plugins/version-info
* Description: Show current WordPress, PHP, Web Server and MySQL versions in admin footer
* Author: alpipego
* Author URI: http://alpipego.com/
* Version: 1.1.5
* License: MIT
* GitHub Plugin URI: https://github.com/alpipego/wp-version-info
* Text Domain: version-info
*/
// pseudo namespace
class VersionInfo {
private $db;
public function __construct( \wpdb $wpdb ) {
$this->db = $wpdb;
add_action( 'plugins_loaded', array( $this, 'load_text_domain' ) );
add_filter( 'update_footer', array( $this, 'version_in_footer' ), 11 );
}
public function load_text_domain() {
load_plugin_textdomain( 'version-info' );
}
public function version_in_footer() {
$update = core_update_footer();
$wp_version = strpos( $update, '<strong>' ) === 0 ? get_bloginfo( 'version' ) . ' (' . $update . ')' : get_bloginfo( 'version' );
return sprintf( esc_attr__( 'You are running WordPress %s | PHP %s | %s | MySQL %s', 'version-info' ), $wp_version, phpversion(), $_SERVER['SERVER_SOFTWARE'], $this->db->get_var('SELECT VERSION();') );
}
}
global $wpdb;
new VersionInfo( $wpdb );