-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathzu-translate.php
35 lines (29 loc) · 1.1 KB
/
zu-translate.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<?php
/*
Plugin Name: Zu Translate
Plugin URI: https://github.com/picasso/zu-translate
GitHub Plugin URI: https://github.com/picasso/zu-translate
Description: Enhances "qTranslate-XT" with some features and Gutenberg support (WordPress Block Editor).
Version: 1.3.5
Author: Dmitry Rudakov
Author URI: https://github.com/picasso
Text Domain: zu-translate
Domain Path: /lang/
Requires at least: 5.8.0
Requires PHP: 7.2.0
*/
// Prohibit direct script loading
defined('ABSPATH') || die('No direct script access allowed!');
// Always load Zukit even if we don't use it later ('wp_doing_ajax' or 'wp_doing_cron')
// as other plugins or themes may want to use it
require_once('zukit/load.php');
// Exit early if a WordPress heartbeat comes
if(wp_doing_ajax() && isset($_POST['action']) && ($_POST['action'] === 'heartbeat')) return;
// Let's not load plugin during cron events
if(wp_doing_cron()) return;
// Start! ---------------------------------------------------------------------]
// compatibility check for Zukit
if(Zukit::is_compatible(__FILE__)) {
require_once('includes/zutranslate-plugin.php');
zutranslate(__FILE__);
}