Version Description
- [ Add Widget ] Add Twitter Widget.
- [ Page Widget ][ Add function ] Improve the dropdown list order.
Download this release
Release Info
Developer | kurudrive |
Plugin | VK All in One Expansion Unit |
Version | 6.0.0 |
Comparing to | |
See all releases |
Code changes from version 5.9.8 to 6.0.0
- languages/vkExUnit-ja.mo +0 -0
- languages/vkExUnit-ja.po +67 -50
- plugins/other_widget/widget-page.php +68 -78
- plugins/sns/sns.php +3 -1
- plugins/sns/{function_fbPagePlugin.php → widget-fb-page-plugin.php} +0 -0
- plugins/sns/widget-twitter.php +151 -0
- plugins_admin/vk-admin/class-vk-admin.php +4 -0
- plugins_admin/vk-admin/images/fort-bnr.jpg +0 -0
- readme.txt +5 -1
- vkExUnit.php +1 -1
languages/vkExUnit-ja.mo
CHANGED
Binary file
|
languages/vkExUnit-ja.po
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
msgid ""
|
2 |
msgstr ""
|
3 |
"Project-Id-Version: \n"
|
4 |
-
"POT-Creation-Date: 2018-03-
|
5 |
"PO-Revision-Date: \n"
|
6 |
"Last-Translator: Kurudrive <kurudrive@gmail.com>\n"
|
7 |
"Language-Team: Vektor translate Team <info@vektor-inc.co.jp>\n"
|
@@ -9,7 +9,7 @@ msgstr ""
|
|
9 |
"MIME-Version: 1.0\n"
|
10 |
"Content-Type: text/plain; charset=UTF-8\n"
|
11 |
"Content-Transfer-Encoding: 8bit\n"
|
12 |
-
"X-Generator: Poedit 2.0.
|
13 |
"X-Poedit-Basepath: ..\n"
|
14 |
"X-Poedit-SourceCharset: UTF-8\n"
|
15 |
"X-Poedit-KeywordsList: __;_e;_x;_ex;_ex:1,2c;_x:1,2c;_n:1,2;esc_attr__\n"
|
@@ -41,9 +41,8 @@ msgid "Extension Setting"
|
|
41 |
msgstr "拡張設定"
|
42 |
|
43 |
#: admin_active_setting_page.php:85
|
44 |
-
#, fuzzy
|
45 |
msgid "Extention contents"
|
46 |
-
msgstr "
|
47 |
|
48 |
#: admin_active_setting_page.php:86
|
49 |
msgid "set extension contents to loop_end hook"
|
@@ -552,9 +551,8 @@ msgid "Show index page"
|
|
552 |
msgstr "一覧ページを表示する"
|
553 |
|
554 |
#: plugins/call-to-action/widget-call-to-action.php:21
|
555 |
-
#, fuzzy
|
556 |
msgid "CTA"
|
557 |
-
msgstr "CTA
|
558 |
|
559 |
#: plugins/call-to-action/widget-call-to-action.php:27
|
560 |
msgid "Select CTA and display it."
|
@@ -572,7 +570,7 @@ msgstr "選択してください"
|
|
572 |
msgid "Read more"
|
573 |
msgstr "詳しくはこちら"
|
574 |
|
575 |
-
#: plugins/child_page_index.php:139 plugins/other_widget/widget-page.php:
|
576 |
msgid "Display a child page index"
|
577 |
msgstr "子ページ一覧の表示"
|
578 |
|
@@ -1033,7 +1031,7 @@ msgstr "3PR エリア設定"
|
|
1033 |
#: plugins/other_widget/widget-pr-blocks.php:89
|
1034 |
#: plugins/other_widget/widget-profile.php:48
|
1035 |
#: plugins/related_posts/related_posts.php:252
|
1036 |
-
#: plugins/sns/
|
1037 |
msgid "Title:"
|
1038 |
msgstr "タイトル"
|
1039 |
|
@@ -1294,16 +1292,11 @@ msgstr "固定ページのタイトルを表示する"
|
|
1294 |
msgid "Do not display titles"
|
1295 |
msgstr "タイトルを表示しない"
|
1296 |
|
1297 |
-
#: plugins/other_widget/widget-page.php:
|
1298 |
-
#: plugins/other_widget/widget-taxonomies.php:74
|
1299 |
-
msgid "Display page"
|
1300 |
-
msgstr "ページを表示"
|
1301 |
-
|
1302 |
-
#: plugins/other_widget/widget-page.php:183 plugins/pageList_ancestor.php:96
|
1303 |
msgid "Display a page list from ancestor"
|
1304 |
msgstr "現在のページの先祖階層からの子ページリストを表示"
|
1305 |
|
1306 |
-
#: plugins/other_widget/widget-page.php:
|
1307 |
msgid "Edit"
|
1308 |
msgstr "編集"
|
1309 |
|
@@ -1385,7 +1378,7 @@ msgid "Solid color"
|
|
1385 |
msgstr "塗りつぶし"
|
1386 |
|
1387 |
#: plugins/other_widget/widget-pr-blocks.php:129
|
1388 |
-
#: plugins/other_widget/widget-profile.php:143 plugins/sns/sns.php:
|
1389 |
msgid "No background"
|
1390 |
msgstr "背景なし"
|
1391 |
|
@@ -1495,6 +1488,10 @@ msgstr "カテゴリーやカスタム分類のリストを表示します。"
|
|
1495 |
msgid "Label to display"
|
1496 |
msgstr "表示するラベル"
|
1497 |
|
|
|
|
|
|
|
|
|
1498 |
#: plugins/other_widget/widget-taxonomies.php:83
|
1499 |
msgid "Do not display terms without posts"
|
1500 |
msgstr "投稿のない分類項目を表示しない"
|
@@ -1658,26 +1655,6 @@ msgstr "HTMLサイトマップ"
|
|
1658 |
msgid "Display a HTML sitemap"
|
1659 |
msgstr "HTMLサイトマップの表示"
|
1660 |
|
1661 |
-
#: plugins/sns/function_fbPagePlugin.php:13
|
1662 |
-
msgid "Displays a Facebook Page Plugin"
|
1663 |
-
msgstr "Facebook ページプラグインを表示します。"
|
1664 |
-
|
1665 |
-
#: plugins/sns/function_fbPagePlugin.php:89
|
1666 |
-
msgid "Height"
|
1667 |
-
msgstr "高さ"
|
1668 |
-
|
1669 |
-
#: plugins/sns/function_fbPagePlugin.php:94
|
1670 |
-
msgid "Show Friend's Faces"
|
1671 |
-
msgstr "アイコンを表示する"
|
1672 |
-
|
1673 |
-
#: plugins/sns/function_fbPagePlugin.php:99
|
1674 |
-
msgid "Hide Cover Photo"
|
1675 |
-
msgstr "カバー画像を表示しない"
|
1676 |
-
|
1677 |
-
#: plugins/sns/function_fbPagePlugin.php:104
|
1678 |
-
msgid "Show Page Posts"
|
1679 |
-
msgstr "タイムラインを表示"
|
1680 |
-
|
1681 |
#: plugins/sns/function_follow.php:16
|
1682 |
msgid "Follow me"
|
1683 |
msgstr "このサイトをフォローする"
|
@@ -1717,11 +1694,11 @@ msgctxt "facebook language code"
|
|
1717 |
msgid "en_US"
|
1718 |
msgstr "ja_JP"
|
1719 |
|
1720 |
-
#: plugins/sns/sns.php:
|
1721 |
msgid "SNS Settings"
|
1722 |
msgstr "SNS設定"
|
1723 |
|
1724 |
-
#: plugins/sns/sns.php:
|
1725 |
msgid "Btn color"
|
1726 |
msgstr "ボタンの色:"
|
1727 |
|
@@ -1853,16 +1830,12 @@ msgid "Share button for display"
|
|
1853 |
msgstr "表示するボタン"
|
1854 |
|
1855 |
#: plugins/sns/sns_admin.php:111
|
1856 |
-
#, fuzzy
|
1857 |
-
#| msgid "Facebook URL:"
|
1858 |
msgid "Facebook"
|
1859 |
-
msgstr "
|
1860 |
|
1861 |
#: plugins/sns/sns_admin.php:112
|
1862 |
-
#, fuzzy
|
1863 |
-
#| msgid "Twitter URL:"
|
1864 |
msgid "Twitter"
|
1865 |
-
msgstr "
|
1866 |
|
1867 |
#: plugins/sns/sns_admin.php:113
|
1868 |
msgid "Hatena"
|
@@ -1876,6 +1849,54 @@ msgstr ""
|
|
1876 |
msgid "LINE (mobile only)"
|
1877 |
msgstr ""
|
1878 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1879 |
#: plugins/template-tags/template-tags.php:95
|
1880 |
#, php-format
|
1881 |
msgid "Author: %s"
|
@@ -1899,7 +1920,6 @@ msgid "F j, Y"
|
|
1899 |
msgstr "Y年Fj日"
|
1900 |
|
1901 |
#: plugins/template-tags/template-tags.php:104
|
1902 |
-
#, fuzzy
|
1903 |
msgctxt "post format archive title"
|
1904 |
msgid "Asides"
|
1905 |
msgstr "サイド"
|
@@ -2053,11 +2073,11 @@ msgstr "ExUnit 設定"
|
|
2053 |
msgid "Edit Guide"
|
2054 |
msgstr "編集ガイド"
|
2055 |
|
2056 |
-
#: plugins_admin/vk-admin/class-vk-admin.php:
|
2057 |
msgid "Sorry, there is no post"
|
2058 |
msgstr "お知らせはありません。"
|
2059 |
|
2060 |
-
#: plugins_admin/vk-admin/class-vk-admin.php:
|
2061 |
msgid "Vektor WordPress Information"
|
2062 |
msgstr ""
|
2063 |
|
@@ -2405,9 +2425,6 @@ msgstr "%s がサポートしているPHPのバージョンは5.6以降です。
|
|
2405 |
#~ msgid "Media float setting:"
|
2406 |
#~ msgstr "メイン設定"
|
2407 |
|
2408 |
-
#~ msgid "Other Widgets"
|
2409 |
-
#~ msgstr "Other ウィジェット"
|
2410 |
-
|
2411 |
#~ msgid "Do not output the OG"
|
2412 |
#~ msgstr "OGタグ出力設定"
|
2413 |
|
1 |
msgid ""
|
2 |
msgstr ""
|
3 |
"Project-Id-Version: \n"
|
4 |
+
"POT-Creation-Date: 2018-03-13 09:15+0900\n"
|
5 |
"PO-Revision-Date: \n"
|
6 |
"Last-Translator: Kurudrive <kurudrive@gmail.com>\n"
|
7 |
"Language-Team: Vektor translate Team <info@vektor-inc.co.jp>\n"
|
9 |
"MIME-Version: 1.0\n"
|
10 |
"Content-Type: text/plain; charset=UTF-8\n"
|
11 |
"Content-Transfer-Encoding: 8bit\n"
|
12 |
+
"X-Generator: Poedit 2.0.6\n"
|
13 |
"X-Poedit-Basepath: ..\n"
|
14 |
"X-Poedit-SourceCharset: UTF-8\n"
|
15 |
"X-Poedit-KeywordsList: __;_e;_x;_ex;_ex:1,2c;_x:1,2c;_n:1,2;esc_attr__\n"
|
41 |
msgstr "拡張設定"
|
42 |
|
43 |
#: admin_active_setting_page.php:85
|
|
|
44 |
msgid "Extention contents"
|
45 |
+
msgstr "拡張コンテンツ"
|
46 |
|
47 |
#: admin_active_setting_page.php:86
|
48 |
msgid "set extension contents to loop_end hook"
|
551 |
msgstr "一覧ページを表示する"
|
552 |
|
553 |
#: plugins/call-to-action/widget-call-to-action.php:21
|
|
|
554 |
msgid "CTA"
|
555 |
+
msgstr "CTA"
|
556 |
|
557 |
#: plugins/call-to-action/widget-call-to-action.php:27
|
558 |
msgid "Select CTA and display it."
|
570 |
msgid "Read more"
|
571 |
msgstr "詳しくはこちら"
|
572 |
|
573 |
+
#: plugins/child_page_index.php:139 plugins/other_widget/widget-page.php:165
|
574 |
msgid "Display a child page index"
|
575 |
msgstr "子ページ一覧の表示"
|
576 |
|
1031 |
#: plugins/other_widget/widget-pr-blocks.php:89
|
1032 |
#: plugins/other_widget/widget-profile.php:48
|
1033 |
#: plugins/related_posts/related_posts.php:252
|
1034 |
+
#: plugins/sns/widget-fb-page-plugin.php:79 plugins/sns/widget-twitter.php:84
|
1035 |
msgid "Title:"
|
1036 |
msgstr "タイトル"
|
1037 |
|
1292 |
msgid "Do not display titles"
|
1293 |
msgstr "タイトルを表示しない"
|
1294 |
|
1295 |
+
#: plugins/other_widget/widget-page.php:174 plugins/pageList_ancestor.php:96
|
|
|
|
|
|
|
|
|
|
|
1296 |
msgid "Display a page list from ancestor"
|
1297 |
msgstr "現在のページの先祖階層からの子ページリストを表示"
|
1298 |
|
1299 |
+
#: plugins/other_widget/widget-page.php:242
|
1300 |
msgid "Edit"
|
1301 |
msgstr "編集"
|
1302 |
|
1378 |
msgstr "塗りつぶし"
|
1379 |
|
1380 |
#: plugins/other_widget/widget-pr-blocks.php:129
|
1381 |
+
#: plugins/other_widget/widget-profile.php:143 plugins/sns/sns.php:191
|
1382 |
msgid "No background"
|
1383 |
msgstr "背景なし"
|
1384 |
|
1488 |
msgid "Label to display"
|
1489 |
msgstr "表示するラベル"
|
1490 |
|
1491 |
+
#: plugins/other_widget/widget-taxonomies.php:74
|
1492 |
+
msgid "Display page"
|
1493 |
+
msgstr "ページを表示"
|
1494 |
+
|
1495 |
#: plugins/other_widget/widget-taxonomies.php:83
|
1496 |
msgid "Do not display terms without posts"
|
1497 |
msgstr "投稿のない分類項目を表示しない"
|
1655 |
msgid "Display a HTML sitemap"
|
1656 |
msgstr "HTMLサイトマップの表示"
|
1657 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1658 |
#: plugins/sns/function_follow.php:16
|
1659 |
msgid "Follow me"
|
1660 |
msgstr "このサイトをフォローする"
|
1694 |
msgid "en_US"
|
1695 |
msgstr "ja_JP"
|
1696 |
|
1697 |
+
#: plugins/sns/sns.php:177 plugins/sns/sns_admin.php:1
|
1698 |
msgid "SNS Settings"
|
1699 |
msgstr "SNS設定"
|
1700 |
|
1701 |
+
#: plugins/sns/sns.php:207
|
1702 |
msgid "Btn color"
|
1703 |
msgstr "ボタンの色:"
|
1704 |
|
1830 |
msgstr "表示するボタン"
|
1831 |
|
1832 |
#: plugins/sns/sns_admin.php:111
|
|
|
|
|
1833 |
msgid "Facebook"
|
1834 |
+
msgstr ""
|
1835 |
|
1836 |
#: plugins/sns/sns_admin.php:112
|
|
|
|
|
1837 |
msgid "Twitter"
|
1838 |
+
msgstr ""
|
1839 |
|
1840 |
#: plugins/sns/sns_admin.php:113
|
1841 |
msgid "Hatena"
|
1849 |
msgid "LINE (mobile only)"
|
1850 |
msgstr ""
|
1851 |
|
1852 |
+
#: plugins/sns/widget-fb-page-plugin.php:13
|
1853 |
+
msgid "Displays a Facebook Page Plugin"
|
1854 |
+
msgstr "Facebook ページプラグインを表示します。"
|
1855 |
+
|
1856 |
+
#: plugins/sns/widget-fb-page-plugin.php:89
|
1857 |
+
msgid "Height"
|
1858 |
+
msgstr "高さ"
|
1859 |
+
|
1860 |
+
#: plugins/sns/widget-fb-page-plugin.php:94
|
1861 |
+
msgid "Show Friend's Faces"
|
1862 |
+
msgstr "アイコンを表示する"
|
1863 |
+
|
1864 |
+
#: plugins/sns/widget-fb-page-plugin.php:99
|
1865 |
+
msgid "Hide Cover Photo"
|
1866 |
+
msgstr "カバー画像を表示しない"
|
1867 |
+
|
1868 |
+
#: plugins/sns/widget-fb-page-plugin.php:104
|
1869 |
+
msgid "Show Page Posts"
|
1870 |
+
msgstr "タイムラインを表示"
|
1871 |
+
|
1872 |
+
#: plugins/sns/widget-twitter.php:9
|
1873 |
+
msgid "Twitter widget"
|
1874 |
+
msgstr "Twitter ウィジェット"
|
1875 |
+
|
1876 |
+
#: plugins/sns/widget-twitter.php:13
|
1877 |
+
msgid "Display Twitter timeline."
|
1878 |
+
msgstr "Twitter のタイムラインを表示します。"
|
1879 |
+
|
1880 |
+
#: plugins/sns/widget-twitter.php:89
|
1881 |
+
msgid "Account:<br>Please enter your Twitter account."
|
1882 |
+
msgstr "アカウント:<br>Twitter アカウントを入力してください。"
|
1883 |
+
|
1884 |
+
#: plugins/sns/widget-twitter.php:90
|
1885 |
+
msgid "@"
|
1886 |
+
msgstr ""
|
1887 |
+
|
1888 |
+
#: plugins/sns/widget-twitter.php:94
|
1889 |
+
msgid "Height:<br>Please enter an arbitrary number.(Example: 300)"
|
1890 |
+
msgstr "高さ:<br>任意の数値を入力してください(例:300)"
|
1891 |
+
|
1892 |
+
#: plugins/sns/widget-twitter.php:99
|
1893 |
+
msgid "Background color:"
|
1894 |
+
msgstr "アイコンの色:"
|
1895 |
+
|
1896 |
+
#: plugins/sns/widget-twitter.php:122
|
1897 |
+
msgid "Link color:"
|
1898 |
+
msgstr "リンクの色:"
|
1899 |
+
|
1900 |
#: plugins/template-tags/template-tags.php:95
|
1901 |
#, php-format
|
1902 |
msgid "Author: %s"
|
1920 |
msgstr "Y年Fj日"
|
1921 |
|
1922 |
#: plugins/template-tags/template-tags.php:104
|
|
|
1923 |
msgctxt "post format archive title"
|
1924 |
msgid "Asides"
|
1925 |
msgstr "サイド"
|
2073 |
msgid "Edit Guide"
|
2074 |
msgstr "編集ガイド"
|
2075 |
|
2076 |
+
#: plugins_admin/vk-admin/class-vk-admin.php:267
|
2077 |
msgid "Sorry, there is no post"
|
2078 |
msgstr "お知らせはありません。"
|
2079 |
|
2080 |
+
#: plugins_admin/vk-admin/class-vk-admin.php:321
|
2081 |
msgid "Vektor WordPress Information"
|
2082 |
msgstr ""
|
2083 |
|
2425 |
#~ msgid "Media float setting:"
|
2426 |
#~ msgstr "メイン設定"
|
2427 |
|
|
|
|
|
|
|
2428 |
#~ msgid "Do not output the OG"
|
2429 |
#~ msgstr "OGタグ出力設定"
|
2430 |
|
plugins/other_widget/widget-page.php
CHANGED
@@ -23,15 +23,15 @@ class WP_Widget_vkExUnit_widget_page extends WP_Widget {
|
|
23 |
$input 保存されてる値
|
24 |
$value 今のinputタグのvalueの値
|
25 |
*/
|
26 |
-
static public function echo_checked( $input, $value){
|
27 |
if ( $input === $value ) {
|
28 |
echo ' checked';
|
29 |
}
|
30 |
}
|
31 |
|
32 |
-
static public function is_active_child_page_index( $options ){
|
33 |
if (
|
34 |
-
! isset( $options['active_childPageIndex'] )|| // 5.7.4 以前を利用で一度も有効化設定を保存していないユーザー
|
35 |
isset( $options['active_childPageIndex'] ) && $options['active_childPageIndex'] // Activate User
|
36 |
) {
|
37 |
return true;
|
@@ -40,7 +40,7 @@ class WP_Widget_vkExUnit_widget_page extends WP_Widget {
|
|
40 |
}
|
41 |
}
|
42 |
|
43 |
-
static public function is_active_page_list_ancestor( $options ){
|
44 |
if (
|
45 |
! isset( $options['active_pageList_ancestor'] ) || // 5.7.4 以前を利用で一度も有効化設定を保存していないユーザー
|
46 |
isset( $options['active_pageList_ancestor'] ) && $options['active_pageList_ancestor'] // Activate User
|
@@ -57,36 +57,36 @@ class WP_Widget_vkExUnit_widget_page extends WP_Widget {
|
|
57 |
$widget_title['display'] : 表示するかどうか // → 5.4.3以降は不要のはず。
|
58 |
$widget_title['title'] : ウィジェットのタイトルとして表示する文字
|
59 |
*/
|
60 |
-
static public function widget_title( $instance ){
|
61 |
|
62 |
$pageid = $instance['page_id'];
|
63 |
-
$page
|
64 |
|
65 |
// Set display
|
66 |
/*-------------------------------------------*/
|
67 |
// 5.3以前のユーザーで、タイトル表示にチェックしていなかった場合
|
68 |
-
if ( $instance['set_title'] == null ){
|
69 |
$widget_title['display'] = false;
|
70 |
|
71 |
-
|
72 |
-
}
|
73 |
$widget_title['display'] = true;
|
74 |
|
75 |
-
}
|
76 |
$widget_title['display'] = false;
|
77 |
|
78 |
-
|
79 |
-
}
|
80 |
|
81 |
// ウィジェットタイトルが未入力の場合
|
82 |
-
if ( empty( $instance['title'] ) ){
|
83 |
$widget_title['display'] = false;
|
84 |
} else {
|
85 |
$widget_title['display'] = true;
|
86 |
}
|
87 |
|
88 |
-
|
89 |
-
}
|
90 |
$widget_title['display'] = true;
|
91 |
|
92 |
} else {
|
@@ -98,9 +98,9 @@ class WP_Widget_vkExUnit_widget_page extends WP_Widget {
|
|
98 |
// ウィジェットタイトルを選択していて、タイトル入力欄に入力がある場合
|
99 |
if ( $instance['set_title'] == 'title-widget' && isset( $instance['title'] ) && $instance['title'] ) {
|
100 |
$widget_title['title'] = $instance['title'];
|
101 |
-
|
102 |
-
|
103 |
-
}
|
104 |
$widget_title['title'] = $page->post_title;
|
105 |
} else {
|
106 |
$widget_title['title'] = null;
|
@@ -120,81 +120,72 @@ class WP_Widget_vkExUnit_widget_page extends WP_Widget {
|
|
120 |
);
|
121 |
|
122 |
$instance = wp_parse_args( (array) $instance, $defaults ); ?>
|
123 |
-
|
124 |
|
125 |
<?php //タイトル ?>
|
126 |
<label for="<?php echo $this->get_field_id( 'title' ); ?>"><?php _e( 'Title:' ); ?></label><br/>
|
127 |
<input type="text" id="<?php echo $this->get_field_id( 'title' ); ?>" name="<?php echo $this->get_field_name( 'title' ); ?>" value="<?php echo esc_attr( $instance['title'] ); ?>" />
|
128 |
-
|
129 |
<br />
|
130 |
|
131 |
<?php /* タイトルの表示形式の選択 */ ?>
|
132 |
|
133 |
<label>
|
134 |
-
<input type="radio" name="<?php echo $this->get_field_name( 'set_title' ); ?>" value="title-widget" <?php $this->echo_checked( $instance['set_title']
|
135 |
<?php _e( 'Display the entered title', 'vkExUnit' ); ?></label><br/>
|
136 |
|
137 |
<label>
|
138 |
-
<input type="radio" name="<?php echo $this->get_field_name( 'set_title' ); ?>" value="title-page" <?php $this->echo_checked( $instance['set_title']
|
139 |
<?php _e( 'Display the title of page', 'vkExUnit' ); ?></label><br/>
|
140 |
|
141 |
<label>
|
142 |
-
<input type="radio" name="<?php echo $this->get_field_name( 'set_title' ); ?>" value="title-hidden" <?php $this->echo_checked( $instance['set_title']
|
143 |
<?php _e( 'Do not display titles', 'vkExUnit' ); ?></label><br/>
|
144 |
-
|
145 |
-
|
146 |
-
|
147 |
-
|
148 |
-
|
149 |
-
|
150 |
-
|
151 |
-
|
152 |
-
|
153 |
-
|
154 |
-
|
155 |
-
|
156 |
-
|
157 |
-
|
158 |
-
<select name="<?php echo $this->get_field_name( 'page_id' ); ?>" id="<?php echo $this->get_field_name( 'page_id' ); ?>" >
|
159 |
-
<?php
|
160 |
-
// option項目の生成
|
161 |
-
// $pages に格納されている固定ページのデータをループしながらoptionを出力
|
162 |
-
foreach ( $pages as $page ) { ?>
|
163 |
-
<option value="<?php echo $page->ID; ?>" <?php if ( $instance['page_id'] == $page->ID ) { echo 'selected="selected"'; } ?> ><?php echo $page->post_title; ?></option>
|
164 |
-
<?php } ?>
|
165 |
-
</select>
|
166 |
-
</p>
|
167 |
|
168 |
<?php $options = vkExUnit_get_common_options(); ?>
|
169 |
|
170 |
-
<?php if ( $this->is_active_child_page_index( $options )
|
171 |
<p>
|
172 |
<label for="<?php echo $this->get_field_name( 'child_page_index' ); ?>">
|
173 |
-
<input type="checkbox" id="<?php echo $this->get_field_name( 'child_page_index' ); ?>" name="<?php echo $this->get_field_name( 'child_page_index' ); ?>"<?php echo ( ! empty($instance['child_page_index'] ) ) ? ' checked' : ''; ?> />
|
174 |
-
<?php _e( 'Display a child page index', 'vkExUnit' )
|
175 |
</label>
|
176 |
</p>
|
177 |
<?php endif; ?>
|
178 |
|
179 |
-
<?php if ( $this->is_active_page_list_ancestor( $options )
|
180 |
<p>
|
181 |
<label for="<?php echo $this->get_field_name( 'page_list_ancestor' ); ?>">
|
182 |
-
<input type="checkbox" id="<?php echo $this->get_field_name( 'page_list_ancestor' ); ?>" name="<?php echo $this->get_field_name( 'page_list_ancestor' ); ?>"<?php echo ( ! empty($instance['page_list_ancestor'] ) ) ? ' checked' : ''; ?> />
|
183 |
-
<?php _e( 'Display a page list from ancestor', 'vkExUnit' )
|
184 |
</label>
|
185 |
</p>
|
186 |
-
<?php endif; ?>
|
187 |
-
|
188 |
<?php
|
|
|
|
|
189 |
}
|
190 |
|
191 |
// 保存・更新する値
|
192 |
function update( $new_instance, $old_instance ) {
|
193 |
-
$instance
|
194 |
-
$instance['title']
|
195 |
-
$instance['page_id']
|
196 |
-
$instance['set_title']
|
197 |
-
$instance['child_page_index']
|
198 |
$instance['page_list_ancestor'] = $new_instance['page_list_ancestor'];
|
199 |
return $instance;
|
200 |
}
|
@@ -212,8 +203,6 @@ class WP_Widget_vkExUnit_widget_page extends WP_Widget {
|
|
212 |
}
|
213 |
|
214 |
|
215 |
-
|
216 |
-
|
217 |
/*-------------------------------------------*/
|
218 |
/* display_page
|
219 |
/*-------------------------------------------*/
|
@@ -229,36 +218,37 @@ class WP_Widget_vkExUnit_widget_page extends WP_Widget {
|
|
229 |
|
230 |
$widget_title = $this->widget_title( $instance );
|
231 |
|
232 |
-
echo PHP_EOL.'<div id="widget-page-'
|
233 |
if ( $widget_title['display'] ) {
|
234 |
echo $args['before_title'] . $widget_title['title'] . $args['after_title'] . PHP_EOL;
|
235 |
}
|
236 |
echo apply_filters( 'the_content', $page->post_content );
|
237 |
|
238 |
-
|
239 |
$options = vkExUnit_get_common_options();
|
240 |
-
if ( $this->is_active_child_page_index( $options ) ){
|
241 |
-
if ( ! empty( $instance['child_page_index'] ) ){
|
242 |
-
echo "\n".apply_filters('the_content', '[vkExUnit_childs]' );
|
243 |
}
|
244 |
}
|
245 |
-
if ( $this->is_active_page_list_ancestor( $options ) ){
|
246 |
-
if ( ! empty( $instance['page_list_ancestor'] ) ){
|
247 |
-
echo "\n".apply_filters('the_content', '[pageList_ancestor]' );
|
248 |
}
|
249 |
}
|
250 |
|
251 |
-
if (
|
252 |
-
|
253 |
-
|
254 |
-
|
255 |
-
|
256 |
-
|
|
|
|
|
257 |
echo $args['after_widget'];
|
258 |
}
|
259 |
}
|
260 |
|
261 |
-
add_action('widgets_init', 'vkExUnit_widget_register_page');
|
262 |
-
function vkExUnit_widget_register_page(){
|
263 |
-
return register_widget(
|
264 |
}
|
23 |
$input 保存されてる値
|
24 |
$value 今のinputタグのvalueの値
|
25 |
*/
|
26 |
+
static public function echo_checked( $input, $value ) {
|
27 |
if ( $input === $value ) {
|
28 |
echo ' checked';
|
29 |
}
|
30 |
}
|
31 |
|
32 |
+
static public function is_active_child_page_index( $options ) {
|
33 |
if (
|
34 |
+
! isset( $options['active_childPageIndex'] ) || // 5.7.4 以前を利用で一度も有効化設定を保存していないユーザー
|
35 |
isset( $options['active_childPageIndex'] ) && $options['active_childPageIndex'] // Activate User
|
36 |
) {
|
37 |
return true;
|
40 |
}
|
41 |
}
|
42 |
|
43 |
+
static public function is_active_page_list_ancestor( $options ) {
|
44 |
if (
|
45 |
! isset( $options['active_pageList_ancestor'] ) || // 5.7.4 以前を利用で一度も有効化設定を保存していないユーザー
|
46 |
isset( $options['active_pageList_ancestor'] ) && $options['active_pageList_ancestor'] // Activate User
|
57 |
$widget_title['display'] : 表示するかどうか // → 5.4.3以降は不要のはず。
|
58 |
$widget_title['title'] : ウィジェットのタイトルとして表示する文字
|
59 |
*/
|
60 |
+
static public function widget_title( $instance ) {
|
61 |
|
62 |
$pageid = $instance['page_id'];
|
63 |
+
$page = get_page( $pageid );
|
64 |
|
65 |
// Set display
|
66 |
/*-------------------------------------------*/
|
67 |
// 5.3以前のユーザーで、タイトル表示にチェックしていなかった場合
|
68 |
+
if ( $instance['set_title'] == null ) {
|
69 |
$widget_title['display'] = false;
|
70 |
|
71 |
+
// 5.3以前のユーザーで、タイトル表示にチェックがはいっていた場合
|
72 |
+
} elseif ( $instance['set_title'] === true ) {
|
73 |
$widget_title['display'] = true;
|
74 |
|
75 |
+
} elseif ( $instance['set_title'] == 'title-hidden' ) {
|
76 |
$widget_title['display'] = false;
|
77 |
|
78 |
+
// ウィジェットのタイトルが選択されている場合は
|
79 |
+
} elseif ( $instance['set_title'] == 'title-widget' ) {
|
80 |
|
81 |
// ウィジェットタイトルが未入力の場合
|
82 |
+
if ( empty( $instance['title'] ) ) {
|
83 |
$widget_title['display'] = false;
|
84 |
} else {
|
85 |
$widget_title['display'] = true;
|
86 |
}
|
87 |
|
88 |
+
// 固定ページのタイトルが選択されている場合は
|
89 |
+
} elseif ( $instance['set_title'] == 'title-page' ) {
|
90 |
$widget_title['display'] = true;
|
91 |
|
92 |
} else {
|
98 |
// ウィジェットタイトルを選択していて、タイトル入力欄に入力がある場合
|
99 |
if ( $instance['set_title'] == 'title-widget' && isset( $instance['title'] ) && $instance['title'] ) {
|
100 |
$widget_title['title'] = $instance['title'];
|
101 |
+
// 旧バージョンで タイトルを表示になっていた場合に
|
102 |
+
// タイトル表示形式フラグに 固定ページのタイトルを表示するvalueにしておく
|
103 |
+
} elseif ( ( $instance['set_title'] === true ) || ( $instance['set_title'] == 'title-page' ) ) {
|
104 |
$widget_title['title'] = $page->post_title;
|
105 |
} else {
|
106 |
$widget_title['title'] = null;
|
120 |
);
|
121 |
|
122 |
$instance = wp_parse_args( (array) $instance, $defaults ); ?>
|
123 |
+
<p>
|
124 |
|
125 |
<?php //タイトル ?>
|
126 |
<label for="<?php echo $this->get_field_id( 'title' ); ?>"><?php _e( 'Title:' ); ?></label><br/>
|
127 |
<input type="text" id="<?php echo $this->get_field_id( 'title' ); ?>" name="<?php echo $this->get_field_name( 'title' ); ?>" value="<?php echo esc_attr( $instance['title'] ); ?>" />
|
128 |
+
<br />
|
129 |
<br />
|
130 |
|
131 |
<?php /* タイトルの表示形式の選択 */ ?>
|
132 |
|
133 |
<label>
|
134 |
+
<input type="radio" name="<?php echo $this->get_field_name( 'set_title' ); ?>" value="title-widget" <?php $this->echo_checked( $instance['set_title'], 'title-widget' ); ?> />
|
135 |
<?php _e( 'Display the entered title', 'vkExUnit' ); ?></label><br/>
|
136 |
|
137 |
<label>
|
138 |
+
<input type="radio" name="<?php echo $this->get_field_name( 'set_title' ); ?>" value="title-page" <?php $this->echo_checked( $instance['set_title'], 'title-page' ); ?> />
|
139 |
<?php _e( 'Display the title of page', 'vkExUnit' ); ?></label><br/>
|
140 |
|
141 |
<label>
|
142 |
+
<input type="radio" name="<?php echo $this->get_field_name( 'set_title' ); ?>" value="title-hidden" <?php $this->echo_checked( $instance['set_title'], 'title-hidden' ); ?> />
|
143 |
<?php _e( 'Do not display titles', 'vkExUnit' ); ?></label><br/>
|
144 |
+
<br/>
|
145 |
+
|
146 |
+
<?php
|
147 |
+
// 固定ページリスト
|
148 |
+
$selected = ( isset( $instance['page_id'] ) ) ? $instance['page_id'] : '';
|
149 |
+
$args = array(
|
150 |
+
'name' => $this->get_field_name( 'page_id' ),
|
151 |
+
'selected' => $selected, // 該当する ID のページを「selected」にし、そのページが選択された状態にする
|
152 |
+
'sort_order' => 'ASC',
|
153 |
+
'post_status' => 'publish,private', // 公開と非公開の記事を取得
|
154 |
+
);
|
155 |
+
wp_dropdown_pages( $args ); // ページのリストのセレクトボックス (つまり、ドロップダウン) を表示する関数
|
156 |
+
?>
|
157 |
+
</p>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
158 |
|
159 |
<?php $options = vkExUnit_get_common_options(); ?>
|
160 |
|
161 |
+
<?php if ( $this->is_active_child_page_index( $options ) ) : ?>
|
162 |
<p>
|
163 |
<label for="<?php echo $this->get_field_name( 'child_page_index' ); ?>">
|
164 |
+
<input type="checkbox" id="<?php echo $this->get_field_name( 'child_page_index' ); ?>" name="<?php echo $this->get_field_name( 'child_page_index' ); ?>"<?php echo ( ! empty( $instance['child_page_index'] ) ) ? ' checked' : ''; ?> />
|
165 |
+
<?php _e( 'Display a child page index', 'vkExUnit' ); ?>
|
166 |
</label>
|
167 |
</p>
|
168 |
<?php endif; ?>
|
169 |
|
170 |
+
<?php if ( $this->is_active_page_list_ancestor( $options ) ) : ?>
|
171 |
<p>
|
172 |
<label for="<?php echo $this->get_field_name( 'page_list_ancestor' ); ?>">
|
173 |
+
<input type="checkbox" id="<?php echo $this->get_field_name( 'page_list_ancestor' ); ?>" name="<?php echo $this->get_field_name( 'page_list_ancestor' ); ?>"<?php echo ( ! empty( $instance['page_list_ancestor'] ) ) ? ' checked' : ''; ?> />
|
174 |
+
<?php _e( 'Display a page list from ancestor', 'vkExUnit' ); ?>
|
175 |
</label>
|
176 |
</p>
|
|
|
|
|
177 |
<?php
|
178 |
+
endif;
|
179 |
+
|
180 |
}
|
181 |
|
182 |
// 保存・更新する値
|
183 |
function update( $new_instance, $old_instance ) {
|
184 |
+
$instance = $old_instance;
|
185 |
+
$instance['title'] = $new_instance['title'];
|
186 |
+
$instance['page_id'] = $new_instance['page_id'];
|
187 |
+
$instance['set_title'] = $new_instance['set_title'];
|
188 |
+
$instance['child_page_index'] = $new_instance['child_page_index'];
|
189 |
$instance['page_list_ancestor'] = $new_instance['page_list_ancestor'];
|
190 |
return $instance;
|
191 |
}
|
203 |
}
|
204 |
|
205 |
|
|
|
|
|
206 |
/*-------------------------------------------*/
|
207 |
/* display_page
|
208 |
/*-------------------------------------------*/
|
218 |
|
219 |
$widget_title = $this->widget_title( $instance );
|
220 |
|
221 |
+
echo PHP_EOL . '<div id="widget-page-' . $pageid . '" class="widget_pageContent">' . PHP_EOL;
|
222 |
if ( $widget_title['display'] ) {
|
223 |
echo $args['before_title'] . $widget_title['title'] . $args['after_title'] . PHP_EOL;
|
224 |
}
|
225 |
echo apply_filters( 'the_content', $page->post_content );
|
226 |
|
|
|
227 |
$options = vkExUnit_get_common_options();
|
228 |
+
if ( $this->is_active_child_page_index( $options ) ) {
|
229 |
+
if ( ! empty( $instance['child_page_index'] ) ) {
|
230 |
+
echo "\n" . apply_filters( 'the_content', '[vkExUnit_childs]' );
|
231 |
}
|
232 |
}
|
233 |
+
if ( $this->is_active_page_list_ancestor( $options ) ) {
|
234 |
+
if ( ! empty( $instance['page_list_ancestor'] ) ) {
|
235 |
+
echo "\n" . apply_filters( 'the_content', '[pageList_ancestor]' );
|
236 |
}
|
237 |
}
|
238 |
|
239 |
+
if ( current_user_can( 'edit_pages' ) ) {
|
240 |
+
?>
|
241 |
+
<div class="veu_adminEdit">
|
242 |
+
<a href="<?php echo site_url(); ?>/wp-admin/post.php?post=<?php echo $pageid; ?>&action=edit" class="btn btn-default btn-sm"><?php _e( 'Edit', 'vkExUnit' ); ?></a>
|
243 |
+
</div>
|
244 |
+
<?php
|
245 |
+
}
|
246 |
+
echo '</div>' . PHP_EOL;
|
247 |
echo $args['after_widget'];
|
248 |
}
|
249 |
}
|
250 |
|
251 |
+
add_action( 'widgets_init', 'vkExUnit_widget_register_page' );
|
252 |
+
function vkExUnit_widget_register_page() {
|
253 |
+
return register_widget( 'WP_Widget_vkExUnit_widget_page' );
|
254 |
}
|
plugins/sns/sns.php
CHANGED
@@ -131,7 +131,8 @@ $fbAppId = (isset( $options['fbAppId'] )) ? $options['fbAppId'] : '';
|
|
131 |
|
132 |
$vkExUnit_sns_options = veu_get_sns_options();
|
133 |
|
134 |
-
require vkExUnit_get_directory() . '/plugins/sns/
|
|
|
135 |
|
136 |
if ( $vkExUnit_sns_options['enableOGTags'] == true ) {
|
137 |
require vkExUnit_get_directory() . '/plugins/sns/function_og.php'; }
|
@@ -144,6 +145,7 @@ if ( $vkExUnit_sns_options['enableFollowMe'] == true ) {
|
|
144 |
|
145 |
require vkExUnit_get_directory() . '/plugins/sns/function_meta_box.php';
|
146 |
|
|
|
147 |
/*-------------------------------------------*/
|
148 |
/* Add setting page
|
149 |
/*-------------------------------------------*/
|
131 |
|
132 |
$vkExUnit_sns_options = veu_get_sns_options();
|
133 |
|
134 |
+
require vkExUnit_get_directory() . '/plugins/sns/widget-fb-page-plugin.php';
|
135 |
+
require vkExUnit_get_directory() . '/plugins/sns/widget-twitter.php';
|
136 |
|
137 |
if ( $vkExUnit_sns_options['enableOGTags'] == true ) {
|
138 |
require vkExUnit_get_directory() . '/plugins/sns/function_og.php'; }
|
145 |
|
146 |
require vkExUnit_get_directory() . '/plugins/sns/function_meta_box.php';
|
147 |
|
148 |
+
|
149 |
/*-------------------------------------------*/
|
150 |
/* Add setting page
|
151 |
/*-------------------------------------------*/
|
plugins/sns/{function_fbPagePlugin.php → widget-fb-page-plugin.php}
RENAMED
File without changes
|
plugins/sns/widget-twitter.php
ADDED
@@ -0,0 +1,151 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
class VK_Twitter_Widget extends WP_Widget {
|
4 |
+
|
5 |
+
/**
|
6 |
+
* ウィジェット名などを設定
|
7 |
+
*/
|
8 |
+
public function __construct() {
|
9 |
+
$widget_name = vkExUnit_get_short_name() . '_' . __( 'Twitter widget', 'vkExUnit' );
|
10 |
+
parent::__construct(
|
11 |
+
'vk_twitter_widget', // Base ID
|
12 |
+
$widget_name, // Name
|
13 |
+
array( 'description' => __( 'Display Twitter timeline.', 'vkExUnit' ) ) // Args
|
14 |
+
);
|
15 |
+
// widget actual processes
|
16 |
+
}
|
17 |
+
|
18 |
+
/**
|
19 |
+
* ウィジェットの内容を出力
|
20 |
+
*
|
21 |
+
* @param array $args
|
22 |
+
* @param array $instance
|
23 |
+
*/
|
24 |
+
public function widget( $args, $instance ) {
|
25 |
+
// outputs the content of the widget
|
26 |
+
echo $args['before_widget'];
|
27 |
+
echo '<div class="vk-teitter-plugin">';
|
28 |
+
if ( isset( $instance['title'] ) && $instance['title'] ) {
|
29 |
+
echo $args['before_title'];
|
30 |
+
echo $instance['title'];
|
31 |
+
echo $args['after_title'];
|
32 |
+
}
|
33 |
+
if ( isset( $instance['account'] ) && $instance['account'] ) {
|
34 |
+
$account = $instance['account'];
|
35 |
+
$account = "https://twitter.com/{$account}?ref_src=twsrc%5Etfw";
|
36 |
+
} else {
|
37 |
+
return $account = '';
|
38 |
+
}
|
39 |
+
if ( isset( $instance['height'] ) && $instance['height'] ) {
|
40 |
+
$height = $instance['height'];
|
41 |
+
} else {
|
42 |
+
$height = 400;
|
43 |
+
}
|
44 |
+
?>
|
45 |
+
|
46 |
+
<a class="twitter-timeline" href="<?php echo esc_url( $account ); ?>" data-height="<?php echo $height; ?>" data-theme="<?php echo wp_kses_post( $instance['bg_color'] ); ?>" data-link-color="<?php echo sanitize_hex_color( $instance['link_color'] ); ?>" data-chrome=”noheader nofooter”>
|
47 |
+
<script async="" src="//platform.twitter.com/widgets.js" charset="utf-8"></script>
|
48 |
+
</a>
|
49 |
+
|
50 |
+
<?php
|
51 |
+
echo '</div>'; // .vk-twitter-plugin
|
52 |
+
echo $args['after_widget'];
|
53 |
+
}
|
54 |
+
|
55 |
+
/**
|
56 |
+
* 管理用のオプションのフォームを出力
|
57 |
+
*
|
58 |
+
* @param array $instance ウィジェットオプション
|
59 |
+
*/
|
60 |
+
|
61 |
+
static function time_line_color() {
|
62 |
+
return array(
|
63 |
+
'light' => 'Light',
|
64 |
+
'dark' => 'Dark',
|
65 |
+
);
|
66 |
+
}
|
67 |
+
|
68 |
+
public function form( $instance ) {
|
69 |
+
// 管理用のオプションのフォームを出力
|
70 |
+
/**
|
71 |
+
* 入力された値とデフォルト値を結合するメソッド
|
72 |
+
*/
|
73 |
+
$defaults = array(
|
74 |
+
'title' => '',
|
75 |
+
'account' => '',
|
76 |
+
'height' => '',
|
77 |
+
'bg_color' => 'light',
|
78 |
+
'link_color' => '#2b7bb9',
|
79 |
+
);
|
80 |
+
$instance = wp_parse_args( (array) $instance, $defaults );
|
81 |
+
?>
|
82 |
+
|
83 |
+
<?php // title ?>
|
84 |
+
<p><label for="<?php echo $this->get_field_id( 'title' ); ?>"><?php _e( 'Title:', 'vkExUnit' ); ?></label><br>
|
85 |
+
<input type="text" id="<?php echo $this->get_field_id( 'title' ); ?>" class="admin_widget_input" name="<?php echo $this->get_field_name( 'title' ); ?>" value="<?php echo esc_attr( $instance['title'] ); ?>" />
|
86 |
+
</p>
|
87 |
+
|
88 |
+
<?php // account ?>
|
89 |
+
<p><label for="<?php echo $this->get_field_id( 'account' ); ?>"><?php _e( 'Account:<br>Please enter your Twitter account.', 'vkExUnit' ); ?></label><br>
|
90 |
+
<?php _e( '@', 'vkExUnit' ); ?><input type="" id="<?php echo $this->get_field_id( 'account' ); ?>" class="" name="<?php echo $this->get_field_name( 'account' ); ?>" value="<?php echo esc_attr( $instance['account'] ); ?>" />
|
91 |
+
</p>
|
92 |
+
|
93 |
+
<?php // height ?>
|
94 |
+
<p><label for="<?php echo $this->get_field_id( 'height' ); ?>"><?php _e( 'Height:<br>Please enter an arbitrary number.(Example: 300)', 'vkExUnit' ); ?></label><br>
|
95 |
+
<input type="text" id="<?php echo $this->get_field_id( 'height' ); ?>" class="admin_widget_input" name="<?php echo $this->get_field_name( 'height' ); ?>" value="<?php echo esc_attr( $instance['height'] ); ?>" />
|
96 |
+
</p>
|
97 |
+
|
98 |
+
<?php // bg color ?>
|
99 |
+
<p><label for="<?php echo $this->get_field_id( 'bg_color' ); ?>"><?php _e( 'Background color:', 'vkExUnit' ); ?></label><br>
|
100 |
+
<select id="<?php echo $this->get_field_id( 'bg_color' ); ?>" name="<?php echo $this->get_field_name( 'bg_color' ); ?>" class="admin_widget_input">
|
101 |
+
<?php
|
102 |
+
if ( ! isset( $instance['bg_color'] ) || ! $instance['bg_color'] ) {
|
103 |
+
$instance['bg_color'] = $default['bg_color'];
|
104 |
+
}
|
105 |
+
foreach ( static::time_line_color() as $key => $label ) :
|
106 |
+
?>
|
107 |
+
<option value="<?php echo $key; ?>"
|
108 |
+
<?php
|
109 |
+
if ( $instance['bg_color'] == $key ) {
|
110 |
+
echo 'selected';
|
111 |
+
}
|
112 |
+
?>
|
113 |
+
>
|
114 |
+
<?php _e( $label, 'vkExUnit' ); ?>
|
115 |
+
</option>
|
116 |
+
<?php endforeach; ?>
|
117 |
+
</select>
|
118 |
+
</p>
|
119 |
+
|
120 |
+
<?php // link color ?>
|
121 |
+
<p class="color_picker_wrap">
|
122 |
+
<label for="<?php echo $this->get_field_id( 'link_color' ); ?>"><?php _e( 'Link color:', 'vkExUnit' ); ?></label><br>
|
123 |
+
<input type="text" id="<?php echo $this->get_field_id( 'link_color' ); ?>" class="color_picker admin_widget_input" name="<?php echo $this->get_field_name( 'link_color' ); ?>" value="<?php if ( $instance['link_color'] ) {
|
124 |
+
echo esc_attr( $instance['link_color'] );} ?>" />
|
125 |
+
</p>
|
126 |
+
|
127 |
+
<?php
|
128 |
+
}
|
129 |
+
|
130 |
+
/**
|
131 |
+
* ウィジェットオプションの保存処理
|
132 |
+
*
|
133 |
+
* @param array $new_instance 新しいオプション
|
134 |
+
* @param array $old_instance 以前のオプション
|
135 |
+
*/
|
136 |
+
public function update( $new_instance, $old_instance ) {
|
137 |
+
// ウィジェットオプションの保存処理
|
138 |
+
$instance = $old_instance;
|
139 |
+
$instance['title'] = wp_kses_post( $new_instance['title'] );
|
140 |
+
$instance['account'] = wp_kses_post( $new_instance['account'] );
|
141 |
+
$instance['height'] = wp_kses_post( mb_convert_kana( $new_instance['height'], 'a' ) );
|
142 |
+
$instance['bg_color'] = in_array( $new_instance['bg_color'], array_keys( self::time_line_color() ) ) ? $new_instance['bg_color'] : static::$button_default;
|
143 |
+
$instance['link_color'] = ( isset( $new_instance['link_color'] ) ) ? sanitize_hex_color( $new_instance['link_color'] ) : false;
|
144 |
+
return $instance;
|
145 |
+
}
|
146 |
+
}
|
147 |
+
|
148 |
+
add_action( 'widgets_init', 'vkExUnit_widget_set_twitter' );
|
149 |
+
function vkExUnit_widget_set_twitter() {
|
150 |
+
return register_widget( 'VK_Twitter_Widget' );
|
151 |
+
}
|
plugins_admin/vk-admin/class-vk-admin.php
CHANGED
@@ -117,6 +117,10 @@ if ( ! class_exists( 'Vk_Admin' ) ) {
|
|
117 |
$banner .= '<a href="//lightning.nagoya/ja/plugins/ex_plugin/lightning-jpnstyle" target="_blank" class="admin_banner"><img src="' . $dir_url . 'images/jpnstyle-bnr.jpg" alt="" /></a>';
|
118 |
}
|
119 |
|
|
|
|
|
|
|
|
|
120 |
if ( $lang == 'ja' && ! is_plugin_active( 'vk-all-in-one-expansion-unit/vkExUnit.php' ) ) {
|
121 |
$banner .= '<a href="https://ex-unit.nagoya/ja/" target="_blank" class="admin_banner"><img src="' . $dir_url . 'images/ExUnit_bnr.png" alt="" /></a>';
|
122 |
}
|
117 |
$banner .= '<a href="//lightning.nagoya/ja/plugins/ex_plugin/lightning-jpnstyle" target="_blank" class="admin_banner"><img src="' . $dir_url . 'images/jpnstyle-bnr.jpg" alt="" /></a>';
|
118 |
}
|
119 |
|
120 |
+
if ( $lang == 'ja' && ! is_plugin_active( 'lightning-skin-fort/lightning-skin-fort.php' ) ) {
|
121 |
+
$banner .= '<a href="//lightning.nagoya/ja/plugins/ex_plugin/lightning-fort" target="_blank" class="admin_banner"><img src="' . $dir_url . 'images/fort-bnr.jpg" alt="" /></a>';
|
122 |
+
}
|
123 |
+
|
124 |
if ( $lang == 'ja' && ! is_plugin_active( 'vk-all-in-one-expansion-unit/vkExUnit.php' ) ) {
|
125 |
$banner .= '<a href="https://ex-unit.nagoya/ja/" target="_blank" class="admin_banner"><img src="' . $dir_url . 'images/ExUnit_bnr.png" alt="" /></a>';
|
126 |
}
|
plugins_admin/vk-admin/images/fort-bnr.jpg
ADDED
Binary file
|
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Donate link:
|
|
4 |
Tags: Google Analytics, New posts, Related Posts, sitemap, sns, twitter card, Facebook Page Plugin, OG tags,
|
5 |
Requires at least: 4.4
|
6 |
Tested up to: 4.9.2
|
7 |
-
Stable tag:
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -73,6 +73,10 @@ e.g.
|
|
73 |
|
74 |
== Changelog ==
|
75 |
|
|
|
|
|
|
|
|
|
76 |
= 5.9.1 =
|
77 |
* [ bugfix ] php 7.2
|
78 |
* [ Design tuning ]
|
4 |
Tags: Google Analytics, New posts, Related Posts, sitemap, sns, twitter card, Facebook Page Plugin, OG tags,
|
5 |
Requires at least: 4.4
|
6 |
Tested up to: 4.9.2
|
7 |
+
Stable tag: 6.0.0
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
73 |
|
74 |
== Changelog ==
|
75 |
|
76 |
+
= 6.0.0 =
|
77 |
+
* [ Add Widget ] Add Twitter Widget.
|
78 |
+
* [ Page Widget ][ Add function ] Improve the dropdown list order.
|
79 |
+
|
80 |
= 5.9.1 =
|
81 |
* [ bugfix ] php 7.2
|
82 |
* [ Design tuning ]
|
vkExUnit.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Plugin Name: VK All in One Expansion Unit
|
4 |
* Plugin URI: https://ex-unit.nagoya
|
5 |
* Description: This plug-in is an integrated plug-in with a variety of features that make it powerful your web site. Many features can be stopped individually. Example Facebook Page Plugin,Social Bookmarks,Print OG Tags,Print Twitter Card Tags,Print Google Analytics tag,New post widget,Insert Related Posts and more!
|
6 |
-
* Version:
|
7 |
* Author: Vektor,Inc.
|
8 |
* Text Domain: vkExUnit
|
9 |
* Domain Path: /languages
|
3 |
* Plugin Name: VK All in One Expansion Unit
|
4 |
* Plugin URI: https://ex-unit.nagoya
|
5 |
* Description: This plug-in is an integrated plug-in with a variety of features that make it powerful your web site. Many features can be stopped individually. Example Facebook Page Plugin,Social Bookmarks,Print OG Tags,Print Twitter Card Tags,Print Google Analytics tag,New post widget,Insert Related Posts and more!
|
6 |
+
* Version: 6.0.0
|
7 |
* Author: Vektor,Inc.
|
8 |
* Text Domain: vkExUnit
|
9 |
* Domain Path: /languages
|