=== TinyMCE:Editor Template Files === Contributors: hana015 Donate link: Plugin URL: https://wordpress.org/plugins/editor-template-files/ Tags: tinymce, editor, template Requires at least: 3.9 Tested up to: 4.8 Stable tag: 1.0.5 License: GPLv2 or later License URI: http://www.gnu.org/licenses/gpl-2.0.html Editor Template Filesは、WordpressでTinyMCE(ビジュアルエディタ)のテンプレート機能を利用できるようにします。 テンプレートは、ファイルベースで作成し、編集可能な領域や編集不可の領域を作ることができます。 You can templates available in Wordpress' s visual editor "TinyMCE". You can create a template with the file and set the noneditable & editable area in your template. == Description == Editor Template Filesは、WordpressでTinyMCE(ビジュアルエディタ)のテンプレート機能を利用できるようにします。 テンプレートは、ファイルベースで作成し、編集可能な領域や編集不可の領域を作ることができます。 * [サポートサイト](https://labo.hanabanadesign.com/editor-template-files/) ## Introduction ## ### Features ### * ビジュアルエディタ「TinyMCE」で、テンプレートを利用できます。 * ファイルベースでのテンプレート作成。 * テンプレートに編集不可・可能領域を設定できます。 * テンプレート読み込み時にあらかじめ設定した値を置き換えることができます。 ### How to use ### 1. Install & Activate the plugin. 2. Create & Upload Your Template.(check below or our site.) 3. Use Your Template. #### How to use Sample Template #### 1. copy from “sample” folder. sample template foler: `/wp-content/plugins/editor-template-files/sample/〜` 2. move to “Your Theme Folder”. `/wp-content/plugins/editor-template-files/sample/〜`            ↓ `/wp-content/themes/Your Theme Folder/sample/〜` 4. rename folder to “editor-template-files” from “sample”. `/wp-content/themes/Your Theme Folder/editor-template-files/〜` 5. If you want to check beautiful style sample. Please check below. please add this code to `functions.php`. `add_editor_style( 'editor-template-files/custom-editor-style.css' );`   Notes: It may affect all editor styles. We recommend that you cancel when you no longer need it. 4. If you want to check perfect sample. Please check below. please add this code to `functions.php`. add_filter('etf_tpl_values', 'hoge'); function hoge( $values ) { global $post_id; $values['sample_value'] = 'Editor Template Files
Sample Page !!'; $values['date'] = get_the_time( 'Y-m-d', $post_id ); $values['etf_plugin_autor'] = 'hana'; return $values; } Thank you for sample settings. You can experience the sample with this. #### Create Your Template #### 1. create folder and file in “Your Theme Folder”. `/Your Theme Folder/editor-template-files/template/***.php` 2. write “Template Info” in your template. /** * * Editor Template Files Name: Sample Template * Description: This is a Sample Template. */ “Editor Template Files Name: ” will “Template Title” when you select Template. “Description: ” will “Template Description” when you select Template. 3. write template As you like. Notes: You must write your code inside “mceTmpl” Class.
Reference: * Sample Template(/wp-content/plugins/editor-template-files/sample/〜) * TinyMCE 4.0 Template Plugin #### Use Your Template #### 1. Open template dialog.(Insert > Template or Template button ) 2. Select your template. 3. Click button. #### Other #### 他、サポートサイトを参照してください。 * 編集不可・可能領域の作り方 * 値の置き換えの使い方 ### 注 ### 必ず、バックアップなどをした上で、使用してください。 既に、エディタのカスタマイズやテンプレートを使用されている場合、動作しない可能性があります。 本プラグインを使用した事による、いかなる損害も作者は一切の責任を負いませんので、自己責任の上でご使用下さい。 == Installation == This section describes how to install the plugin and get it working. e.g. 1. Upload `editor-templates.php` to the `/wp-content/plugins/` directory 1. Activate the plugin through the 'Plugins' menu in WordPress 1. Place `` in your templates #### WP管理画面から #### 1. 「プラグイン > 新規追加」 から「Editor Template Files」を探します。 2. 「今すぐインストール」をクリックして、インストールします。 3. プラグインを有効にします。 == Screenshots == 1. 作成したテンプレートを使う 1( 挿入 > Template ) 2. 作成したテンプレートを使う 2(ツールバーのボタンから) 3. テンプレートを選択する。 4. テンプレートが挿入されました 5. 編集不可領域のサンプル 6. 編集可能領域のサンプル 1 7. 編集可能領域のサンプル 2 8. 編集可能領域のサンプル 3 == Frequently Asked Questions == == Changelog == = 1.0.1 = * Update README File. = 1.0.2 = * Update Plugin Information. = 1.0.3 = * Update README File. = 1.0.4 = * Support child theme. and Fix template button. = 1.0.5 = * Change text for Support Site URL and Author Site URL. There is no change in the content itself. == Upgrade Notice == == Arbitrary section ==