Upload a templates

May 31, 2012 at 1:00 PM

I couldn't upload a template file from in the Editor Optins Dialog as it is in the documentation, even i ulpoad it from the the file manager, but it couldn't be recognise by the editor, i get error.

Coordinator
May 31, 2012 at 1:09 PM
yooas wrote:

I couldn't upload a template file from in the Editor Optins Dialog as it is in the documentation, even i ulpoad it from the the file manager, but it couldn't be recognise by the editor, i get error.

You need to add "js" files to the List of "Allowable File Extensions" under Host -> Host Settings -> Other Settings, otherwise you can not select or upload such template files from the Options Dialog.

May 31, 2012 at 1:18 PM

I have already done that, but it doesn't works!

Coordinator
May 31, 2012 at 1:38 PM

what error did you get, and which dnn version?

Jun 1, 2012 at 6:47 AM

i get "Object referance not set to an instance of an object" in a new window. I'm using dnn 6.2.0

Coordinator
Jun 2, 2012 at 1:29 PM
yooas wrote:

i get "Object referance not set to an instance of an object" in a new window. I'm using dnn 6.2.0

I uploaded a new Beta Version, i removed the Upload feature. however uploading files from the dnn Admin->Filemanger  or the CKEditor included FileBrowser does work

Jun 20, 2012 at 10:58 AM

I have the same issue.

I tried adding the templates manually by adding this to CkEditorDefaultSettings.xml:

 <sTemplates>/Portals/0/templates.js</sTemplates>

But the templates do not apear (pop-up is empty).

I used the template example on this page

http://dnnckeditor.codeplex.com/wikipage?title=Add%20Custom%20Template&referringTitle=Documentation

And saved it in the root folder as templates.js

(DNN 5.6 + Editor 1.14.04)

Am I doing something wrong, or is there another way to add custom templates?

Thank, Timo

Coordinator
Jun 20, 2012 at 1:16 PM
timo_design wrote:

 <sTemplates>/Portals/0/templates.js</sTemplates>

No that can not work the file control only allows urls or fileid something like this

<sTemplates>FileID=253</sTemplates>

If you save the File in the portal root and sync the file system you should be able to select the file in the settings.

Jun 20, 2012 at 3:08 PM

Ah, ok it's on file id.

Thanks, Timo

Jun 21, 2012 at 6:32 PM

Hmm, if I sync the file system it does show up in the root.

I can also select the file (for portal), but the setting is not stored in CKEditorDefaultSettings.xml

(although the template does seem to be loaded)

Jun 21, 2012 at 7:03 PM

Ok, these are the default settings... not the stored settings, right?

Coordinator
Jun 22, 2012 at 10:52 AM
timo_design wrote:

Hmm, if I sync the file system it does show up in the root.

I can also select the file (for portal), but the setting is not stored in CKEditorDefaultSettings.xml

(although the template does seem to be loaded)

If they dont show up in the root, js files are not marked as Allowable File Extensions in dnn.

Settings are never saved in the default settings file, you can only modify the portal/page or modul instance settings from the Options Window.

Coordinator
Jun 22, 2012 at 10:53 AM

I need to find a better way to add templates and styles instead of that stupid js handling.

Coordinator
Jun 22, 2012 at 2:55 PM

Update in 1.14.06 BETA 3 its now possible to use xml files instead of js files.

Jun 27, 2012 at 2:04 PM

Thanks, sounds great. Will test ASAP.