update to v3.3.3

This commit is contained in:
spirit 2019-12-13 14:52:55 +08:00
parent dedda7185a
commit 15a6ab525b
10 changed files with 131 additions and 54 deletions

View File

@ -7,7 +7,7 @@
* @package Sakura * @package Sakura
*/ */
define( 'SAKURA_VERSION', '3.3.2' ); define( 'SAKURA_VERSION', '3.3.3' );
define( 'BUILD_VERSION', '3' ); define( 'BUILD_VERSION', '3' );
//ini_set('display_errors', true); //ini_set('display_errors', true);

View File

@ -224,26 +224,9 @@ function SMMS_API($image)
$Boundary = wp_generate_password(); $Boundary = wp_generate_password();
$bits = file_get_contents($filedata); $bits = file_get_contents($filedata);
$headers = array();
array_push($headers, "Content-Type: multipart/form-data; boundary=$Boundary");
array_push($headers, '');
array_push($headers, "Authorization: Basic " . $client_id);
array_push($headers, '');
array_push($headers, "User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/78.0.3904.97");
$headers = implode("\r\n", $headers);
$fields = array();
array_push($fields, "--" . $Boundary);
array_push($fields, "Content-Disposition: form-data; name=\"smfile\"; filename=\"$filename\"");
array_push($fields, '');
array_push($fields, $bits);
array_push($fields, '');
array_push($fields, "--" . $Boundary . "--");
$fields = implode("\r\n", $fields);
$args = array( $args = array(
'headers' => $headers, 'headers' => 'Content-Type: multipart/form-data; boundary=' . $Boundary . '\r\n\r\nAuthorization: Basic ' . $client_id . '\r\n\r\nUser-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/78.0.3904.97',
'body' => $fields, 'body' => '--' . $Boundary . '\r\nContent-Disposition: form-data; name="smfile"; filename="' . $filename . '"\r\n\r\n'.$bits.'\r\n\r\n--' . $Boundary . '--'
); );
$response = wp_remote_post($upload_url, $args); $response = wp_remote_post($upload_url, $args);

View File

@ -272,7 +272,7 @@ function optionsframework_page() { ?>
<?php settings_fields( 'optionsframework' ); ?> <?php settings_fields( 'optionsframework' ); ?>
<?php optionsframework_fields(); /* Settings */ ?> <?php optionsframework_fields(); /* Settings */ ?>
<div id="optionsframework-submit"> <div id="optionsframework-submit">
<input type="submit" class="button-primary" name="update" value="<?php esc_attr_e( 'Save', 'sakaura' ); ?>" /> <input type="submit" class="button-primary" name="update" value="<?php _e( 'Save', 'sakura' ); ?>" />
<input type="submit" class="reset-button button-secondary" name="reset" value="<?php esc_attr_e( 'Restore default', 'sakura' ); ?>" onclick="return confirm( '<?php print esc_js( __( 'All setting will be lost, sure?', 'sakura' ) ); ?>' );" /> <input type="submit" class="reset-button button-secondary" name="reset" value="<?php esc_attr_e( 'Restore default', 'sakura' ); ?>" onclick="return confirm( '<?php print esc_js( __( 'All setting will be lost, sure?', 'sakura' ) ); ?>' );" />
<div class="clear"></div> <div class="clear"></div>
</div> </div>

Binary file not shown.

View File

@ -1,8 +1,8 @@
msgid "" msgid ""
msgstr "" msgstr ""
"Project-Id-Version: Sakura\n" "Project-Id-Version: Sakura\n"
"POT-Creation-Date: 2019-12-04 15:07+0800\n" "POT-Creation-Date: 2019-12-13 14:51+0800\n"
"PO-Revision-Date: 2019-12-04 15:15+0800\n" "PO-Revision-Date: 2019-12-13 14:51+0800\n"
"Last-Translator: \n" "Last-Translator: \n"
"Language-Team: \n" "Language-Team: \n"
"Language: en_US\n" "Language: en_US\n"
@ -205,7 +205,7 @@ msgstr ""
msgid "QQ" msgid "QQ"
msgstr "" msgstr ""
#: functions.php:1654 #: functions.php:1664
msgid "Sidebar" msgid "Sidebar"
msgstr "" msgstr ""
@ -214,7 +214,7 @@ msgstr ""
msgid "page %s " msgid "page %s "
msgstr "" msgstr ""
#: inc/api.php:313 inc/theme_plus.php:727 #: inc/api.php:301 inc/theme_plus.php:727
msgid "The comment is private" msgid "The comment is private"
msgstr "" msgstr ""
@ -1341,7 +1341,13 @@ msgid "About"
msgstr "" msgstr ""
#: options.php:906 #: options.php:906
msgid "Theme Sakura v" #, php-format
msgid ""
"Theme Sakura v %s | <a href=\"https://2heng.xin/theme-sakura/\">Theme "
"document</a> | <a href=\"https://github.com/mashirozx/Sakura/\">Source "
"code</a><a href=\"https://github.com/mashirozx/Sakura/releases/latest\"><img "
"src=\"https://img.shields.io/github/release/mashirozx/Sakura.svg?style=flat-"
"square\" alt=\"GitHub release\"></a>"
msgstr "" msgstr ""
#: options.php:912 #: options.php:912
@ -1623,27 +1629,51 @@ msgid "Enable human verification"
msgstr "" msgstr ""
#: options.php:1139 #: options.php:1139
msgid "Comment UA infomation" msgid "QQ avatar link encryption"
msgstr "" msgstr ""
#: options.php:1140 #: options.php:1140
msgid "Do not display the user's qq avatar links directly."
msgstr ""
#: options.php:1145
msgid "Off (default)"
msgstr ""
#: options.php:1146
msgid "use redirect (general security)"
msgstr ""
#: options.php:1147
msgid "fetch data at backend (high security)"
msgstr ""
#: options.php:1148
msgid "fetch data at backend (high securityslow)"
msgstr ""
#: options.php:1152
msgid "Comment UA infomation"
msgstr ""
#: options.php:1153
msgid "" msgid ""
"Check to enable, display the user's browser, operating system information" "Check to enable, display the user's browser, operating system information"
msgstr "" msgstr ""
#: options.php:1146 #: options.php:1159
msgid "Enable disqus" msgid "Enable disqus"
msgstr "" msgstr ""
#: options.php:1147 #: options.php:1160
msgid "Enable disqus for comment" msgid "Enable disqus for comment"
msgstr "" msgstr ""
#: options.php:1153 #: options.php:1166
msgid "Time Zone adjustment" msgid "Time Zone adjustment"
msgstr "" msgstr ""
#: options.php:1154 #: options.php:1167
msgid "" msgid ""
"If the comment has a time difference problem adjust here, fill in an " "If the comment has a time difference problem adjust here, fill in an "
"integer, the calculation method: actual_time = display_error_time - " "integer, the calculation method: actual_time = display_error_time - "

View File

@ -3,7 +3,7 @@ msgid ""
msgstr "" msgstr ""
"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n" "Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
"Project-Id-Version: Sakura\n" "Project-Id-Version: Sakura\n"
"POT-Creation-Date: 2019-12-04 15:07+0800\n" "POT-Creation-Date: 2019-12-13 14:50+0800\n"
"PO-Revision-Date: 2019-11-01 14:27+0800\n" "PO-Revision-Date: 2019-11-01 14:27+0800\n"
"Last-Translator: \n" "Last-Translator: \n"
"Language-Team: \n" "Language-Team: \n"
@ -204,7 +204,7 @@ msgstr ""
msgid "QQ" msgid "QQ"
msgstr "" msgstr ""
#: functions.php:1654 #: functions.php:1664
msgid "Sidebar" msgid "Sidebar"
msgstr "" msgstr ""
@ -213,7 +213,7 @@ msgstr ""
msgid "page %s " msgid "page %s "
msgstr "" msgstr ""
#: inc/api.php:313 inc/theme_plus.php:727 #: inc/api.php:301 inc/theme_plus.php:727
msgid "The comment is private" msgid "The comment is private"
msgstr "" msgstr ""
@ -1322,7 +1322,12 @@ msgid "About"
msgstr "" msgstr ""
#: options.php:906 #: options.php:906
msgid "Theme Sakura v" #, php-format
msgid ""
"Theme Sakura v %s | <a href=\"https://2heng.xin/theme-sakura/\">Theme document</a> | <a "
"href=\"https://github.com/mashirozx/Sakura/\">Source code</a><a href=\"https://github.com/"
"mashirozx/Sakura/releases/latest\"><img src=\"https://img.shields.io/github/release/mashirozx/"
"Sakura.svg?style=flat-square\" alt=\"GitHub release\"></a>"
msgstr "" msgstr ""
#: options.php:912 #: options.php:912
@ -1592,26 +1597,50 @@ msgid "Enable human verification"
msgstr "" msgstr ""
#: options.php:1139 #: options.php:1139
msgid "Comment UA infomation" msgid "QQ avatar link encryption"
msgstr "" msgstr ""
#: options.php:1140 #: options.php:1140
msgid "Check to enable, display the user's browser, operating system information" msgid "Do not display the user's qq avatar links directly."
msgstr ""
#: options.php:1145
msgid "Off (default)"
msgstr "" msgstr ""
#: options.php:1146 #: options.php:1146
msgid "Enable disqus" msgid "use redirect (general security)"
msgstr "" msgstr ""
#: options.php:1147 #: options.php:1147
msgid "Enable disqus for comment" msgid "fetch data at backend (high security)"
msgstr ""
#: options.php:1148
msgid "fetch data at backend (high securityslow)"
msgstr ""
#: options.php:1152
msgid "Comment UA infomation"
msgstr "" msgstr ""
#: options.php:1153 #: options.php:1153
msgid "Check to enable, display the user's browser, operating system information"
msgstr ""
#: options.php:1159
msgid "Enable disqus"
msgstr ""
#: options.php:1160
msgid "Enable disqus for comment"
msgstr ""
#: options.php:1166
msgid "Time Zone adjustment" msgid "Time Zone adjustment"
msgstr "" msgstr ""
#: options.php:1154 #: options.php:1167
msgid "" msgid ""
"If the comment has a time difference problem adjust here, fill in an integer, the calculation " "If the comment has a time difference problem adjust here, fill in an integer, the calculation "
"method: actual_time = display_error_time - the_integer_you_entered (unit: hour)" "method: actual_time = display_error_time - the_integer_you_entered (unit: hour)"

Binary file not shown.

View File

@ -1,8 +1,8 @@
msgid "" msgid ""
msgstr "" msgstr ""
"Project-Id-Version: Sakura\n" "Project-Id-Version: Sakura\n"
"POT-Creation-Date: 2019-12-04 15:07+0800\n" "POT-Creation-Date: 2019-12-13 14:51+0800\n"
"PO-Revision-Date: 2019-12-04 15:07+0800\n" "PO-Revision-Date: 2019-12-13 14:51+0800\n"
"Last-Translator: \n" "Last-Translator: \n"
"Language-Team: \n" "Language-Team: \n"
"Language: zh_CN\n" "Language: zh_CN\n"
@ -207,7 +207,7 @@ msgstr ""
msgid "QQ" msgid "QQ"
msgstr "" msgstr ""
#: functions.php:1654 #: functions.php:1664
msgid "Sidebar" msgid "Sidebar"
msgstr "侧栏" msgstr "侧栏"
@ -216,7 +216,7 @@ msgstr "侧栏"
msgid "page %s " msgid "page %s "
msgstr "第 %s 页 " msgstr "第 %s 页 "
#: inc/api.php:313 inc/theme_plus.php:727 #: inc/api.php:301 inc/theme_plus.php:727
msgid "The comment is private" msgid "The comment is private"
msgstr "该评论为私密评论" msgstr "该评论为私密评论"
@ -1365,8 +1365,19 @@ msgid "About"
msgstr "关于" msgstr "关于"
#: options.php:906 #: options.php:906
msgid "Theme Sakura v" #, php-format
msgid ""
"Theme Sakura v %s | <a href=\"https://2heng.xin/theme-sakura/\">Theme "
"document</a> | <a href=\"https://github.com/mashirozx/Sakura/\">Source "
"code</a><a href=\"https://github.com/mashirozx/Sakura/releases/latest\"><img "
"src=\"https://img.shields.io/github/release/mashirozx/Sakura.svg?style=flat-"
"square\" alt=\"GitHub release\"></a>"
msgstr "" msgstr ""
"Theme Sakura v %s | <a href=\"https://2heng.xin/theme-sakura/\">主题说明</"
"a> | <a href=\"https://github.com/mashirozx/Sakura/\">源码</a><a href="
"\"https://github.com/mashirozx/Sakura/releases/latest\"><img src=\"https://"
"img.shields.io/github/release/mashirozx/Sakura.svg?style=flat-square\" alt="
"\"GitHub release\"></a>"
#: options.php:912 #: options.php:912
msgid "Check for Updates" msgid "Check for Updates"
@ -1667,27 +1678,51 @@ msgid "Enable human verification"
msgstr "开启机器人验证" msgstr "开启机器人验证"
#: options.php:1139 #: options.php:1139
msgid "QQ avatar link encryption"
msgstr "QQ头像链接加密"
#: options.php:1140
msgid "Do not display the user's qq avatar links directly."
msgstr "不直接暴露用户QQ头像链接"
#: options.php:1145
msgid "Off (default)"
msgstr "关闭(默认)"
#: options.php:1146
msgid "use redirect (general security)"
msgstr "使用重定向(安全性低)"
#: options.php:1147
msgid "fetch data at backend (high security)"
msgstr "后端获取头像数据(安全性高)"
#: options.php:1148
msgid "fetch data at backend (high securityslow)"
msgstr "后端解析QQ头像接口安全性高"
#: options.php:1152
msgid "Comment UA infomation" msgid "Comment UA infomation"
msgstr "评论UA信息" msgstr "评论UA信息"
#: options.php:1140 #: options.php:1153
msgid "" msgid ""
"Check to enable, display the user's browser, operating system information" "Check to enable, display the user's browser, operating system information"
msgstr "勾选开启,显示用户的浏览器,操作系统信息" msgstr "勾选开启,显示用户的浏览器,操作系统信息"
#: options.php:1146 #: options.php:1159
msgid "Enable disqus" msgid "Enable disqus"
msgstr "开启多说插件支持" msgstr "开启多说插件支持"
#: options.php:1147 #: options.php:1160
msgid "Enable disqus for comment" msgid "Enable disqus for comment"
msgstr "多说已经凉了~~" msgstr "多说已经凉了~~"
#: options.php:1153 #: options.php:1166
msgid "Time Zone adjustment" msgid "Time Zone adjustment"
msgstr "时区调整" msgstr "时区调整"
#: options.php:1154 #: options.php:1167
msgid "" msgid ""
"If the comment has a time difference problem adjust here, fill in an " "If the comment has a time difference problem adjust here, fill in an "
"integer, the calculation method: actual_time = display_error_time - " "integer, the calculation method: actual_time = display_error_time - "

View File

@ -903,7 +903,7 @@ function optionsframework_options() {
$options[] = array( $options[] = array(
'name' => __('About', 'sakura'),/*关于*/ 'name' => __('About', 'sakura'),/*关于*/
'desc' => __('Theme Sakura v'.SAKURA_VERSION.' | <a href="https://2heng.xin/theme-sakura/">Theme document</a> | <a href="https://github.com/mashirozx/Sakura/">Source code</a><a href="https://github.com/mashirozx/Sakura/releases/latest"><img src="https://img.shields.io/github/release/mashirozx/Sakura.svg?style=flat-square" alt="GitHub release"></a>', 'sakura'),/*Theme Sakura v'.SAKURA_VERSION.' | <a href="https://2heng.xin/theme-sakura/">主题说明</a> | <a href="https://github.com/mashirozx/Sakura/">源码</a><a href="https://github.com/mashirozx/Sakura/releases/latest"><img src="https://img.shields.io/github/release/mashirozx/Sakura.svg?style=flat-square" alt="GitHub release"></a>*/ 'desc' => sprintf(__('Theme Sakura v %s | <a href="https://2heng.xin/theme-sakura/">Theme document</a> | <a href="https://github.com/mashirozx/Sakura/">Source code</a><a href="https://github.com/mashirozx/Sakura/releases/latest"><img src="https://img.shields.io/github/release/mashirozx/Sakura.svg?style=flat-square" alt="GitHub release"></a>', 'sakura'), SAKURA_VERSION),/*Theme Sakura v'.SAKURA_VERSION.' | <a href="https://2heng.xin/theme-sakura/">主题说明</a> | <a href="https://github.com/mashirozx/Sakura/">源码</a><a href="https://github.com/mashirozx/Sakura/releases/latest"><img src="https://img.shields.io/github/release/mashirozx/Sakura.svg?style=flat-square" alt="GitHub release"></a>*/
'id' => 'theme_intro', 'id' => 'theme_intro',
'std' => '', 'std' => '',
'type' => 'typography '); 'type' => 'typography ');
@ -1140,7 +1140,7 @@ function optionsframework_options() {
'desc' => __('Do not display the user\'s qq avatar links directly.', 'sakura'),/*不直接暴露用户qq头像链接*/ 'desc' => __('Do not display the user\'s qq avatar links directly.', 'sakura'),/*不直接暴露用户qq头像链接*/
'id' => 'qq_avatar_link', 'id' => 'qq_avatar_link',
'std' => "off", 'std' => "off",
'type' => "radio", 'type' => "select",
'options' => array( 'options' => array(
'off' => __('Off (default)', 'sakura'),/*关闭(默认)*/ 'off' => __('Off (default)', 'sakura'),/*关闭(默认)*/
'type_1' => __('use redirect (general security)', 'sakura'),/*使用 重定向(安全性一般)'*/ 'type_1' => __('use redirect (general security)', 'sakura'),/*使用 重定向(安全性一般)'*/

View File

@ -5,7 +5,7 @@ Theme URI: https://github.com/mashirozx/Sakura/
Author: Mashiro, Spirit, Louie, Fuzzz Author: Mashiro, Spirit, Louie, Fuzzz
Author URI: http://2heng.xin Author URI: http://2heng.xin
Description: A wonderful branch of theme Akina Description: A wonderful branch of theme Akina
Version: 3.3.2 Version: 3.3.3
License: GNU General Public License v2 or later License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: sakura Text Domain: sakura