-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathtilda-wordpress-plugin.php
157 lines (95 loc) · 5.23 KB
/
tilda-wordpress-plugin.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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
<?php
/*
Plugin Name: Tilda Publishing
Description: Tilda позволяет делать яркую подачу материала, качественную верстку и эффектную типографику, близкую к журнальной. Каким бы ни был ваш контент — Tilda знает, как его показать. С чего начать: 1) Нажмите ссылку «Активировать» слева от этого описания; 2) <a href="http://www.tilda.cc/" target="_blank">Зарегистрируйтесь</a>, чтобы получить API-ключ; 3) Перейдите на страницу настройки Tilda Publishing и введите свой API-ключ. Читайте подробную инструкцию по подключению.
Version: 0.3.27
Requires PHP: 5.6
Requires at least: 3.0.1
Author: Tilda Publishing
License: GPLv2 or later
Text Domain: api tilda
Update 0.3.27 - add timestamp to JS/CSS file links to save up-to-date versions
Update 0.3.26 - fix nonces for new pages, dynamic JS & issue #33
Update 0.3.25 - add some checks to suppress php warnings
Update 0.3.24 - add nonces in admin-ajax.php
Update 0.3.23 - fix unicode in zero forms
Update 0.3.22 - fix cURL encoding
Update 0.3.21 - check permissions in admin-ajax.php
Update 0.3.20 - fix changing JS paths
Update 0.3.19 - fix saving images locally
Update 0.3.18 - add backward compatibility
Update 0.3.17 - change deprecated .andSelf() to .addBack()
Update 0.3.16 - fix for JS included in page body
Update 0.3.15 - fix cleaning projects/pages local data after keys removal
Update 0.3.14 - refactoring; use getprojectinfo instead of deprecated getprojectexport; change tilda API server IP
Update 0.3.13 - fix markup corruption on empty project_id
Update 0.3.12 - Improved network reliability
Update 0.3.11 - fix for nontilda pages
Update 0.3.10 - update en_US locale
Update 0.3.09 - fix unexpected array overwriting
Update 0.3.08 - fix incorrect image path and improve en_US translations
Update 0.3.07 - add en_US locale
Update 0.3.06 - fix missing async loaded js script and images
Update 0.3.05 - update webhook features according to API changes
Update 0.3.04 - hot fix for 0.3.03
Update 0.3.03 - fix warning on post meta without project_id
Update 0.3.02 - fix ZeroBlock's gallery import
Update 0.3.01 - modify storage sync page and connect with Tilda.cc
Update 0.2.33 - fix scripts
Update 0.2.32 - fix forms in zero
Update 0.2.31 - add version to css and js files
Update 0.2.30 - fix if no pages in project
Update 0.2.29 - fix custom types
Update 0.2.28 - fix upload images to local directory
Update 0.2.27 - added a switch to turn off the styles in the list; added settings for custom types; add checking exist curl library or allow_url_fopen option.
Update 0.2.26 - fix: resolve conflict with plugin modify meta box
Update 0.2.25 - fix: bug in WP4.9
Update 0.2.23 - fix: wpautop and add check rule
Update 0.2.22 - remove_filter wpautop
Update 0.2.21 - after sync not change status (draft->publish), thanks Anton Syuvaev; fix conflict with css from other version css and js
Update 0.2.20 - micro fixing
Update 0.2.19 - add css class [tilda-publishing] in tag body
Update 0.2.18 - fix clean html for rss/seo plugin
Update 0.2.17 - fix jQuery conflict with other js-framework
Update 0.2.16 - add password protected on pages/posts
Update 0.2.15.1 - Add new secure server
Update 0.2.15 - Bugfix vulnerability
Update 0.2.14 - Bugfix refresh list (bug viewed in WP4.5.2)
Update 0.2.13 - Add check error, add download image for socnet and other bugfix
Update 0.2.12 - modify sync (updated Tilda API)
Update 0.2.11 - bugfix synchronization
Update 0.2.10 - add support upload without curl library
Update 0.2.9 - add english language
*/
/*
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
// Turn off all error reporting
//error_reporting(0);
if ( ! function_exists( 'add_action' ) ) {
echo 'Hi there! I\'m just a plugin, not much I can do when called directly.';
exit;
}
define( 'TILDA_VERSION', '0.3.27' );
define( 'TILDA_MINIMUM_WP_VERSION', '3.0.1' );
define( 'TILDA_PLUGIN_URL', plugin_dir_url( __FILE__ ) );
define( 'TILDA_PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
define( 'TILDA_DELETE_LIMIT', 100000 );
require_once( TILDA_PLUGIN_DIR . 'class.tilda.php' );
register_activation_hook( __FILE__, [ 'Tilda', 'plugin_activation' ] );
register_deactivation_hook( __FILE__, [ 'Tilda', 'plugin_deactivation' ] );
add_action( 'init', [ 'Tilda', 'init' ] );
if ( is_admin() ) {
require_once( TILDA_PLUGIN_DIR . 'class.tilda-admin.php' );
add_action( 'init', [ 'Tilda_Admin', 'init' ] );
}