Version Description
- Bugfix: checkbox output with the label attribute.
- Bugfix: mediaButton attribute.
Download this release
Release Info
Developer | Hiroaki Miyashita |
Plugin | Custom Field Template |
Version | 2.0.2 |
Comparing to | |
See all releases |
Code changes from version 2.0.1 to 2.0.2
- custom-field-template.php +9 -8
- readme.txt +6 -1
custom-field-template.php
CHANGED
@@ -4,7 +4,7 @@ Plugin Name: Custom Field Template
|
|
4 |
Plugin URI: http://wpgogo.com/development/custom-field-template.html
|
5 |
Description: This plugin adds the default custom fields on the Write Post/Page.
|
6 |
Author: Hiroaki Miyashita
|
7 |
-
Version: 2.0.
|
8 |
Author URI: http://wpgogo.com/
|
9 |
*/
|
10 |
|
@@ -2130,25 +2130,25 @@ jQuery(this).addClass("closed");
|
|
2130 |
if ( !$mediaOffImage ) :
|
2131 |
$image_upload_iframe_src = apply_filters('image_upload_iframe_src', "$media_upload_iframe_src?type=image");
|
2132 |
$image_title = __('Add an Image');
|
2133 |
-
$media .= "<a href=\"{$image_upload_iframe_src}&TB_iframe=true\" id=\"add_image{$rand}\" title='$image_title' onclick=\"focusTextArea('
|
2134 |
endif;
|
2135 |
if ( !$mediaOffVideo ) :
|
2136 |
$video_upload_iframe_src = apply_filters('video_upload_iframe_src', "$media_upload_iframe_src?type=video");
|
2137 |
$video_title = __('Add Video');
|
2138 |
-
$media .= "<a href=\"{$video_upload_iframe_src}&TB_iframe=true\" id=\"add_video{$rand}\" title='$video_title' onclick=\"focusTextArea('
|
2139 |
endif;
|
2140 |
if ( !$mediaOffAudio ) :
|
2141 |
$audio_upload_iframe_src = apply_filters('audio_upload_iframe_src', "$media_upload_iframe_src?type=audio");
|
2142 |
$audio_title = __('Add Audio');
|
2143 |
-
$media .= "<a href=\"{$audio_upload_iframe_src}&TB_iframe=true\" id=\"add_audio{$rand}\" title='$audio_title' onclick=\"focusTextArea('
|
2144 |
endif;
|
2145 |
if ( !$mediaOffMedia ) :
|
2146 |
$media_title = __('Add Media');
|
2147 |
-
$media .= "<a href=\"{$media_upload_iframe_src}?TB_iframe=true\" id=\"add_media{$rand}\" title='$media_title' onclick=\"focusTextArea('
|
2148 |
endif;
|
2149 |
else :
|
2150 |
$media_title = __('Add Media');
|
2151 |
-
$media .= "<a href=\"{$media_upload_iframe_src}?TB_iframe=true\" id=\"add_media{$rand}\" title='$media_title' onclick=\"focusTextArea('
|
2152 |
endif;
|
2153 |
endif;
|
2154 |
|
@@ -3401,9 +3401,10 @@ jQuery("#edButtonPreview").trigger("click"); }' . "\n";*/
|
|
3401 |
if ( empty($value) && $val['outputNone'] ) $value = $val['outputNone'];
|
3402 |
if ( $val['shortCode'] == true ) $value = do_shortcode($value);
|
3403 |
if ( !empty($val['label']) && !empty($options['custom_field_template_replace_keys_by_labels']) )
|
3404 |
-
$
|
|
|
3405 |
if ( $val['hideKey'] != true && $num == 0 )
|
3406 |
-
$output .= '<dt>' . $
|
3407 |
$output .= '<dd>' . $value . '</dd>' . "\n";
|
3408 |
endforeach;
|
3409 |
endif;
|
4 |
Plugin URI: http://wpgogo.com/development/custom-field-template.html
|
5 |
Description: This plugin adds the default custom fields on the Write Post/Page.
|
6 |
Author: Hiroaki Miyashita
|
7 |
+
Version: 2.0.2
|
8 |
Author URI: http://wpgogo.com/
|
9 |
*/
|
10 |
|
2130 |
if ( !$mediaOffImage ) :
|
2131 |
$image_upload_iframe_src = apply_filters('image_upload_iframe_src', "$media_upload_iframe_src?type=image");
|
2132 |
$image_title = __('Add an Image');
|
2133 |
+
$media .= "<a href=\"{$image_upload_iframe_src}&TB_iframe=true\" id=\"add_image{$rand}\" title='$image_title' onclick=\"focusTextArea('".sha1($name.$rand)."'); jQuery(this).attr('href',jQuery(this).attr('href').replace('\?','?post_id='+jQuery('#post_ID').val())); return thickbox(this);\"><img src='images/media-button-image.gif' alt='$image_title' /></a> ";
|
2134 |
endif;
|
2135 |
if ( !$mediaOffVideo ) :
|
2136 |
$video_upload_iframe_src = apply_filters('video_upload_iframe_src', "$media_upload_iframe_src?type=video");
|
2137 |
$video_title = __('Add Video');
|
2138 |
+
$media .= "<a href=\"{$video_upload_iframe_src}&TB_iframe=true\" id=\"add_video{$rand}\" title='$video_title' onclick=\"focusTextArea('".sha1($name.$rand)."'); jQuery(this).attr('href',jQuery(this).attr('href').replace('\?','?post_id='+jQuery('#post_ID').val())); return thickbox(this);\"><img src='images/media-button-video.gif' alt='$video_title' /></a> ";
|
2139 |
endif;
|
2140 |
if ( !$mediaOffAudio ) :
|
2141 |
$audio_upload_iframe_src = apply_filters('audio_upload_iframe_src', "$media_upload_iframe_src?type=audio");
|
2142 |
$audio_title = __('Add Audio');
|
2143 |
+
$media .= "<a href=\"{$audio_upload_iframe_src}&TB_iframe=true\" id=\"add_audio{$rand}\" title='$audio_title' onclick=\"focusTextArea('".sha1($name.$rand)."'); jQuery(this).attr('href',jQuery(this).attr('href').replace('\?','?post_id='+jQuery('#post_ID').val())); return thickbox(this);\"><img src='images/media-button-music.gif' alt='$audio_title' /></a> ";
|
2144 |
endif;
|
2145 |
if ( !$mediaOffMedia ) :
|
2146 |
$media_title = __('Add Media');
|
2147 |
+
$media .= "<a href=\"{$media_upload_iframe_src}?TB_iframe=true\" id=\"add_media{$rand}\" title='$media_title' onclick=\"focusTextArea('".sha1($name.$rand)."'); jQuery(this).attr('href',jQuery(this).attr('href').replace('\?','?post_id='+jQuery('#post_ID').val())); return thickbox(this);\"><img src='images/media-button-other.gif' alt='$media_title' /></a>";
|
2148 |
endif;
|
2149 |
else :
|
2150 |
$media_title = __('Add Media');
|
2151 |
+
$media .= "<a href=\"{$media_upload_iframe_src}?TB_iframe=true\" id=\"add_media{$rand}\" title='$media_title' onclick=\"focusTextArea('".sha1($name.$rand)."'); jQuery(this).attr('href',jQuery(this).attr('href').replace('\?','?post_id='+jQuery('#post_ID').val())); return thickbox(this);\"><img src='images/media-button.png' alt='$media_title' /></a>";
|
2152 |
endif;
|
2153 |
endif;
|
2154 |
|
3401 |
if ( empty($value) && $val['outputNone'] ) $value = $val['outputNone'];
|
3402 |
if ( $val['shortCode'] == true ) $value = do_shortcode($value);
|
3403 |
if ( !empty($val['label']) && !empty($options['custom_field_template_replace_keys_by_labels']) )
|
3404 |
+
$key_val = stripcslashes($val['label']);
|
3405 |
+
else $key_val = $key;
|
3406 |
if ( $val['hideKey'] != true && $num == 0 )
|
3407 |
+
$output .= '<dt>' . $key_val . '</dt>' . "\n";
|
3408 |
$output .= '<dd>' . $value . '</dd>' . "\n";
|
3409 |
endforeach;
|
3410 |
endif;
|
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Donate link: http://wpgogo.com/development/custom-field-template.html
|
|
4 |
Tags: custom, fields, field, template, meta, custom field, custom fields, custom field template
|
5 |
Requires at least: 2.1
|
6 |
Tested up to: 3.4
|
7 |
-
Stable tag: 2.0.
|
8 |
|
9 |
This plugin adds the default custom fields on the Write Post/Page.
|
10 |
|
@@ -59,6 +59,7 @@ The Custom Field Template plugin adds the default custom fields on the Write Pos
|
|
59 |
* Adds the attribute of `singleList` attribute in order to output with `<ul><li>` if the value is single. ex) `singleList = true`
|
60 |
* Adds the file upload type. (`type = file`)
|
61 |
* Adds the fieldset type. (`type = fieldset_open`, `type = fieldset_close`)
|
|
|
62 |
|
63 |
Localization
|
64 |
|
@@ -107,6 +108,10 @@ See the default template and modify it.
|
|
107 |
|
108 |
== Changelog ==
|
109 |
|
|
|
|
|
|
|
|
|
110 |
= 2.0.1 =
|
111 |
* Bugix: multibyte string key names with the html editor.
|
112 |
|
4 |
Tags: custom, fields, field, template, meta, custom field, custom fields, custom field template
|
5 |
Requires at least: 2.1
|
6 |
Tested up to: 3.4
|
7 |
+
Stable tag: 2.0.2
|
8 |
|
9 |
This plugin adds the default custom fields on the Write Post/Page.
|
10 |
|
59 |
* Adds the attribute of `singleList` attribute in order to output with `<ul><li>` if the value is single. ex) `singleList = true`
|
60 |
* Adds the file upload type. (`type = file`)
|
61 |
* Adds the fieldset type. (`type = fieldset_open`, `type = fieldset_close`)
|
62 |
+
* Adds the option to deploy the box in each template.
|
63 |
|
64 |
Localization
|
65 |
|
108 |
|
109 |
== Changelog ==
|
110 |
|
111 |
+
= 2.0.2 =
|
112 |
+
* Bugfix: checkbox output with the label attribute.
|
113 |
+
* Bugfix: mediaButton attribute.
|
114 |
+
|
115 |
= 2.0.1 =
|
116 |
* Bugix: multibyte string key names with the html editor.
|
117 |
|