Version Description
Download this release
Release Info
Developer | Hiroaki Miyashita |
Plugin | Custom Field Template |
Version | 0.4.1 |
Comparing to | |
See all releases |
Code changes from version 0.4 to 0.4.1
- custom-field-template.php +8 -6
- readme.txt +1 -1
custom-field-template.php
CHANGED
@@ -4,7 +4,7 @@ Plugin Name: Custom Field Template
|
|
4 |
Plugin URI: http://wordpressgogo.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: 0.4
|
8 |
Author URI: http://wordpressgogo.com/
|
9 |
*/
|
10 |
|
@@ -538,16 +538,18 @@ EOF;
|
|
538 |
else $init_id = 0;
|
539 |
|
540 |
$fields = $this->get_custom_fields( $init_id );
|
541 |
-
|
542 |
-
|
543 |
-
|
|
|
544 |
$out .= 'jQuery(document).ready(function() {' . "\n" .
|
545 |
' if(wpTinyMCEConfig) if(wpTinyMCEConfig.defaultEditor == "html") { jQuery("#edButtonPreview").trigger("click"); }' . "\n" .
|
546 |
'});' . "\n";
|
547 |
-
|
|
|
548 |
}
|
549 |
}
|
550 |
-
}
|
551 |
|
552 |
$out .= 'var tinyMCEID = new Array();' . "\n" .
|
553 |
'// ]]>' . "\n" .
|
4 |
Plugin URI: http://wordpressgogo.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: 0.4.1
|
8 |
Author URI: http://wordpressgogo.com/
|
9 |
*/
|
10 |
|
538 |
else $init_id = 0;
|
539 |
|
540 |
$fields = $this->get_custom_fields( $init_id );
|
541 |
+
if ( user_can_richedit() ) {
|
542 |
+
foreach( $fields as $title => $data ) {
|
543 |
+
for($i = 0; $i<count($data); $i++) {
|
544 |
+
if( $data[$i][ 'type' ] == 'textarea' && $data[$i][ 'tinyMCE' ] ) {
|
545 |
$out .= 'jQuery(document).ready(function() {' . "\n" .
|
546 |
' if(wpTinyMCEConfig) if(wpTinyMCEConfig.defaultEditor == "html") { jQuery("#edButtonPreview").trigger("click"); }' . "\n" .
|
547 |
'});' . "\n";
|
548 |
+
break;
|
549 |
+
}
|
550 |
}
|
551 |
}
|
552 |
+
}
|
553 |
|
554 |
$out .= 'var tinyMCEID = new Array();' . "\n" .
|
555 |
'// ]]>' . "\n" .
|
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Donate link: http://wordpressgogo.com/development/custom-field-template.html
|
|
4 |
Tags: custom, fields, field, template
|
5 |
Requires at least: 2.1
|
6 |
Tested up to: 2.6.2
|
7 |
-
Stable tag: 0.4
|
8 |
|
9 |
This plugin adds the default custom fields on the Write Post/Page.
|
10 |
|
4 |
Tags: custom, fields, field, template
|
5 |
Requires at least: 2.1
|
6 |
Tested up to: 2.6.2
|
7 |
+
Stable tag: 0.4.1
|
8 |
|
9 |
This plugin adds the default custom fields on the Write Post/Page.
|
10 |
|