Version Description
- [ GA ][ bug fix ] customize error fix
Download this release
Release Info
Developer | kurudrive |
Plugin | VK All in One Expansion Unit |
Version | 6.2.2 |
Comparing to | |
See all releases |
Code changes from version 6.2.1 to 6.2.2
- plugins/google_analytics/ga_customizer.php +30 -26
- readme.txt +4 -1
- vkExUnit.php +1 -1
plugins/google_analytics/ga_customizer.php
CHANGED
@@ -8,27 +8,29 @@ function veu_customize_panel_activation_ga() {
|
|
8 |
return true;
|
9 |
}
|
10 |
|
11 |
-
if ( apply_filters( 'veu_customize_panel_activation', false ) ){
|
12 |
-
add_action( 'customize_register', 'veu_customize_register_ga'
|
13 |
}
|
14 |
|
15 |
function veu_customize_register_ga( $wp_customize ) {
|
16 |
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
|
|
22 |
array(
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
)
|
27 |
);
|
28 |
|
29 |
//2. WPデータベースに新しいテーマ設定を追加
|
30 |
// Google Analytics ID
|
31 |
-
$wp_customize->add_setting(
|
|
|
32 |
array(
|
33 |
'default' => '',
|
34 |
'type' => 'option', // 保存先 option or theme_mod
|
@@ -38,35 +40,37 @@ function veu_customize_register_ga( $wp_customize ) {
|
|
38 |
);
|
39 |
|
40 |
$wp_customize->add_control(
|
41 |
-
new
|
42 |
$wp_customize, 'gaId', array(
|
43 |
-
'label'
|
44 |
-
'section'
|
45 |
-
'settings'
|
46 |
-
'type'
|
47 |
-
'description'
|
48 |
'input_before' => 'UA-',
|
49 |
)
|
50 |
)
|
51 |
);
|
52 |
|
53 |
// Select the type of Analytics code
|
54 |
-
$wp_customize->add_setting(
|
55 |
-
|
|
|
56 |
'default' => 'gaType_universal',
|
57 |
'type' => 'option',
|
58 |
'capability' => 'edit_theme_options',
|
59 |
'sanitize_callback' => 'esc_attr',
|
60 |
)
|
61 |
);
|
62 |
-
$wp_customize->add_control(
|
63 |
-
|
64 |
-
|
65 |
-
'
|
66 |
-
'
|
67 |
-
'
|
|
|
68 |
// 'priority' => $priority,
|
69 |
-
'choices'
|
70 |
'gaType_universal' => __( 'To output the Universal Analytics code (default)', 'vkExUnit' ),
|
71 |
'gaType_normal' => __( 'To output only normal code', 'vkExUnit' ),
|
72 |
'gaType_both' => __( 'To output both types', 'vkExUnit' ),
|
8 |
return true;
|
9 |
}
|
10 |
|
11 |
+
if ( apply_filters( 'veu_customize_panel_activation', false ) ) {
|
12 |
+
add_action( 'customize_register', 'veu_customize_register_ga', 20 );
|
13 |
}
|
14 |
|
15 |
function veu_customize_register_ga( $wp_customize ) {
|
16 |
|
17 |
+
/*-------------------------------------------*/
|
18 |
+
/* ga Settings セクション、テーマ設定、コントロールを追加
|
19 |
+
/*-------------------------------------------*/
|
20 |
+
//1. テーマカスタマイザー上に新しいセクションを追加
|
21 |
+
$wp_customize->add_section(
|
22 |
+
'veu_ga_setting',
|
23 |
array(
|
24 |
+
'title' => __( 'Google Analtics Settings', 'vkExUnit' ),
|
25 |
+
'priority' => 1,
|
26 |
+
'panel' => 'veu_setting',
|
27 |
)
|
28 |
);
|
29 |
|
30 |
//2. WPデータベースに新しいテーマ設定を追加
|
31 |
// Google Analytics ID
|
32 |
+
$wp_customize->add_setting(
|
33 |
+
'vkExUnit_ga_options[gaId]',
|
34 |
array(
|
35 |
'default' => '',
|
36 |
'type' => 'option', // 保存先 option or theme_mod
|
40 |
);
|
41 |
|
42 |
$wp_customize->add_control(
|
43 |
+
new ExUnit_Custom_Text_Control(
|
44 |
$wp_customize, 'gaId', array(
|
45 |
+
'label' => __( 'Google Analytics ID', 'vkExUnit' ),
|
46 |
+
'section' => 'veu_ga_setting',
|
47 |
+
'settings' => 'vkExUnit_ga_options[gaId]',
|
48 |
+
'type' => 'text',
|
49 |
+
'description' => __( 'Please fill in the Google Analytics ID from the Analytics embed code used in the site.<br>ex) XXXXXXXX-X', 'vkExUnit' ),
|
50 |
'input_before' => 'UA-',
|
51 |
)
|
52 |
)
|
53 |
);
|
54 |
|
55 |
// Select the type of Analytics code
|
56 |
+
$wp_customize->add_setting(
|
57 |
+
'vkExUnit_ga_options[gaType]',
|
58 |
+
array(
|
59 |
'default' => 'gaType_universal',
|
60 |
'type' => 'option',
|
61 |
'capability' => 'edit_theme_options',
|
62 |
'sanitize_callback' => 'esc_attr',
|
63 |
)
|
64 |
);
|
65 |
+
$wp_customize->add_control(
|
66 |
+
'gaType',
|
67 |
+
array(
|
68 |
+
'label' => __( 'Select the type of Analytics code', 'vkExUnit' ),
|
69 |
+
'section' => 'veu_ga_setting',
|
70 |
+
'settings' => 'vkExUnit_ga_options[gaType]',
|
71 |
+
'type' => 'radio',
|
72 |
// 'priority' => $priority,
|
73 |
+
'choices' => array(
|
74 |
'gaType_universal' => __( 'To output the Universal Analytics code (default)', 'vkExUnit' ),
|
75 |
'gaType_normal' => __( 'To output only normal code', 'vkExUnit' ),
|
76 |
'gaType_both' => __( 'To output both types', 'vkExUnit' ),
|
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.5
|
7 |
-
Stable tag: 6.2.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -73,6 +73,9 @@ e.g.
|
|
73 |
|
74 |
== Changelog ==
|
75 |
|
|
|
|
|
|
|
76 |
= 6.2.0 =
|
77 |
* [ SNS ][ Follow Me Section ] Change design
|
78 |
* [ SNS ][ Add function ] Add customizer setting
|
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.5
|
7 |
+
Stable tag: 6.2.2
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
73 |
|
74 |
== Changelog ==
|
75 |
|
76 |
+
= 6.2.2 =
|
77 |
+
* [ GA ][ bug fix ] customize error fix
|
78 |
+
|
79 |
= 6.2.0 =
|
80 |
* [ SNS ][ Follow Me Section ] Change design
|
81 |
* [ SNS ][ Add function ] Add customizer setting
|
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: 6.2.
|
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.2.2
|
7 |
* Author: Vektor,Inc.
|
8 |
* Text Domain: vkExUnit
|
9 |
* Domain Path: /languages
|