Hi there.
I have read almost all topics with templates and hole doc about templates and still it don't work.
Please specifies 2 things to me.
1st. When I build my template base on this:
I should make it one line?
2nd. Where excactly put this code
and where put mytemplates.js?
If i put code in
when i'm puting this code to php file where is my configuration like this:
Please simple 2 answers...
I have read almost all topics with templates and hole doc about templates and still it don't work.
Please specifies 2 things to me.
1st. When I build my template base on this:
// Register a template definition set named "default".
CKEDITOR.addTemplates( 'default',
{
// The name of the subfolder that contains the preview images of the templates.
imagesPath : CKEDITOR.getUrl( CKEDITOR.plugins.getPath( 'templates' ) + 'templates/images/' ),
// Template definitions.
templates :
[
{
title: 'My Template 1',
image: 'template1.gif',
description: 'Description of My Template 1.',
html:
'<h2>Template 1</h2>' +
'<p><img src="/logo.png" style="float:left" />Type your text here.</p>'
},
{
title: 'My Template 2',
html:
'<h3>Template 2</h3>' +
'<p>Type your text here.</p>'
}
]
});
I should make it one line?
2nd. Where excactly put this code
config.templates_files = [ '/mytemplates.js' ];
and where put mytemplates.js?
If i put code in
ckeditor/plugins/templates/plugin.jsit do nothing
when i'm puting this code to php file where is my configuration like this:
<script type="text/javascript"> //<![CDATA[ var editor = CKEDITOR.replace( \'txt\', { customConfig : \'/js/ckeditor/config.js\', toolbar : [ [\'Source\',\'-\',\'Save\',\'NewPage\',\'Preview\',\'-\',\'Templates\'], [\'Cut\',\'Copy\',\'Paste\',\'PasteText\',\'PasteFromWord\'], [\'Undo\',\'Redo\',\'-\',\'Find\',\'Replace\',\'-\',\'SelectAll\',\'RemoveFormat\'], \'/\', [\'Bold\',\'Italic\',\'Underline\',\'Strike\',\'-\',\'Subscript\',\'Superscript\'], [\'NumberedList\',\'BulletedList\',\'-\',\'Outdent\',\'Indent\',\'Blockquote\'], [\'JustifyLeft\',\'JustifyCenter\',\'JustifyRight\',\'JustifyBlock\'], [\'Link\',\'Unlink\',\'Anchor\'], [\'Image\',\'Table\',\'HorizontalRule\',\'SpecialChar\'], \'/\', [\'Styles\',\'Format\',\'Font\',\'FontSize\'], [\'TextColor\',\'BGColor\'], [\'Maximize\', \'ShowBlocks\'] ], filebrowserBrowseUrl : \'/js/elfinder/elfinder.html?mode=file\', filebrowserImageBrowseUrl : \'/js/elfinder/elfinder.html?mode=image\', filebrowserFlashBrowseUrl : \'/js/elfinder/elfinder.html?mode=flash\', filebrowserImageUploadUrl : \'/js/elfinder/elfinder.html?mode=image\', filebrowserFlashUploadUrl : \'/js/elfinder/elfinder.html?mode=flash\', filebrowserImageWindowWidth : \'950\', filebrowserImageWindowHeight : \'490\', filebrowserWindowWidth : \'950\', filebrowserWindowHeight : \'490\' }); //]]> </script>
Please simple 2 answers...