Version Description
Download this release
Release Info
Developer | poporon |
Plugin | Pz-LinkCard |
Version | 2.0.0.1 |
Comparing to | |
See all releases |
Code changes from version 2.0.0 to 2.0.0.1
- lib/pz-linkcard-cacheman-list.php +7 -5
- pz-linkcard.php +12 -8
- readme.txt +4 -0
lib/pz-linkcard-cacheman-list.php
CHANGED
@@ -243,11 +243,13 @@ foreach ($data_all as $data) {
|
|
243 |
$domain = $data->domain;
|
244 |
// 日本語ドメイン対応
|
245 |
if (isset($this->options['flg-idn']) ? true : false) {
|
246 |
-
if (
|
247 |
-
|
248 |
-
|
249 |
-
|
250 |
-
|
|
|
|
|
251 |
}
|
252 |
}
|
253 |
$title = htmlspecialchars($data->title);
|
243 |
$domain = $data->domain;
|
244 |
// 日本語ドメイン対応
|
245 |
if (isset($this->options['flg-idn']) ? true : false) {
|
246 |
+
if (function_exists('idn_to_utf8')) {
|
247 |
+
if ( substr( $domain, 0, 4 ) == 'xn--') {
|
248 |
+
$domain = idn_to_utf8( $domain );
|
249 |
+
$url_m = parse_url( $url );
|
250 |
+
$url_m['host'] = idn_to_utf8( $url_m[host] );
|
251 |
+
$disp_url = $url_m['scheme'].'://'.$url_m['host'].$url_m['path'].$url_m['query'].$url_m['fragment'];
|
252 |
+
}
|
253 |
}
|
254 |
}
|
255 |
$title = htmlspecialchars($data->title);
|
pz-linkcard.php
CHANGED
@@ -114,7 +114,7 @@ class Pz_LinkCard {
|
|
114 |
'flg-alive' => '1',
|
115 |
'flg-ssl' => '1',
|
116 |
'flg-amp' => '1',
|
117 |
-
'flg-idn' => '
|
118 |
'style-reset-img' => '1',
|
119 |
'style' => null,
|
120 |
'css-file' => null,
|
@@ -134,7 +134,7 @@ class Pz_LinkCard {
|
|
134 |
'thumbnail-url' => null,
|
135 |
'plugin-link' => null,
|
136 |
'plugin-name' => 'Pz-LinkCard',
|
137 |
-
'plugin-version' => '2.0.0',
|
138 |
'plugin-url' => 'http://poporon.poponet.jp/pz-linkcard',
|
139 |
'pz-hbc-options' => null,
|
140 |
'debug-time' => null
|
@@ -589,8 +589,10 @@ class Pz_LinkCard {
|
|
589 |
$site_name = $domain;
|
590 |
// 日本語ドメイン対応
|
591 |
if (isset($this->options['flg-idn']) ? true : false) {
|
592 |
-
if (
|
593 |
-
|
|
|
|
|
594 |
}
|
595 |
}
|
596 |
}
|
@@ -667,10 +669,12 @@ class Pz_LinkCard {
|
|
667 |
|
668 |
// 日本語ドメイン対応
|
669 |
if (isset($this->options['flg-idn']) ? true : false) {
|
670 |
-
|
671 |
-
|
672 |
-
$url_m['host']
|
673 |
-
|
|
|
|
|
674 |
}
|
675 |
}
|
676 |
|
114 |
'flg-alive' => '1',
|
115 |
'flg-ssl' => '1',
|
116 |
'flg-amp' => '1',
|
117 |
+
'flg-idn' => '',
|
118 |
'style-reset-img' => '1',
|
119 |
'style' => null,
|
120 |
'css-file' => null,
|
134 |
'thumbnail-url' => null,
|
135 |
'plugin-link' => null,
|
136 |
'plugin-name' => 'Pz-LinkCard',
|
137 |
+
'plugin-version' => '2.0.0.1',
|
138 |
'plugin-url' => 'http://poporon.poponet.jp/pz-linkcard',
|
139 |
'pz-hbc-options' => null,
|
140 |
'debug-time' => null
|
589 |
$site_name = $domain;
|
590 |
// 日本語ドメイン対応
|
591 |
if (isset($this->options['flg-idn']) ? true : false) {
|
592 |
+
if (function_exists('idn_to_utf8')) {
|
593 |
+
if (substr( $site_name, 0, 4 ) == 'xn--') {
|
594 |
+
$site_name = idn_to_utf8( $site_name );
|
595 |
+
}
|
596 |
}
|
597 |
}
|
598 |
}
|
669 |
|
670 |
// 日本語ドメイン対応
|
671 |
if (isset($this->options['flg-idn']) ? true : false) {
|
672 |
+
if (function_exists('idn_to_utf8')) {
|
673 |
+
$url_m = parse_url( $url );
|
674 |
+
if (substr( $url_m['host'], 0, 4 ) == 'xn--') {
|
675 |
+
$url_m['host'] = idn_to_utf8( $url_m[host] );
|
676 |
+
$url = $url_m['scheme'].'://'.$url_m['host'].$url_m['path'].$url_m['query'].$url_m['fragment'];
|
677 |
+
}
|
678 |
}
|
679 |
}
|
680 |
|
readme.txt
CHANGED
@@ -155,6 +155,10 @@ A5.
|
|
155 |
5. "Write shortcode and url"
|
156 |
|
157 |
== Changelog ==
|
|
|
|
|
|
|
|
|
158 |
Ver2.0.0
|
159 |
* URL指定に「href」も使用できるように変更しました。(Thanks @weblearninglog)
|
160 |
Modefied: "href" was added to the parameter that specifies the URL.
|
155 |
5. "Write shortcode and url"
|
156 |
|
157 |
== Changelog ==
|
158 |
+
Ver2.0.0.1
|
159 |
+
* idn_to_utf8()が実装されていない環境でエラーが出ていたので対応しました。
|
160 |
+
Fixed: Fixed a bug.
|
161 |
+
|
162 |
Ver2.0.0
|
163 |
* URL指定に「href」も使用できるように変更しました。(Thanks @weblearninglog)
|
164 |
Modefied: "href" was added to the parameter that specifies the URL.
|