Does anybody have any idea about the following (below is even an explanation of what I need it for)?
My problems actually has two parts:
1) First of all, I don't know how to make CKEditor accept custom tags (i.e. <mytag width='100' height='100'></mytag>). In other words - is it possible to add a new tag into the "accepted tags collection"?
2) Is it possible to prevent rendering of the tag (in our case "mytag")? Instead of parsing the tag, I would like it to be replaced with a picture upon clicking of which, properties could be edited. Ideally, the replacement image should be able to respect the width and height settings.
NOTE: Actually, I basically want to replicate the way flash or iframe is handled by ckeditor for custom content.
Thanks a lot for any suggestions.
Malis
What I need it for:
First of all, I don't actually want to add any tags into xhtml. I know that many programs and sites do that but I don't think it is good practice. What I do want, though, is a way of adding some custom content that will be pre-processed by the content management system - end users will get valid xhtml content while content administrators will be able to edit special content via special user interface).
One of practical examples - I'd like to add the following: <youtube width='400' height='300' source='address'></youtube>. Admin should be see a youtube icon of the specified size and when clicking it, they will see a property window where they will be able to edit these properties. Before the content is sent to the browser by the cms system, it will preprocess the code and turn the <youtube></youtube> part into valid xhtml.
My problems actually has two parts:
1) First of all, I don't know how to make CKEditor accept custom tags (i.e. <mytag width='100' height='100'></mytag>). In other words - is it possible to add a new tag into the "accepted tags collection"?
2) Is it possible to prevent rendering of the tag (in our case "mytag")? Instead of parsing the tag, I would like it to be replaced with a picture upon clicking of which, properties could be edited. Ideally, the replacement image should be able to respect the width and height settings.
NOTE: Actually, I basically want to replicate the way flash or iframe is handled by ckeditor for custom content.
Thanks a lot for any suggestions.
Malis
What I need it for:
First of all, I don't actually want to add any tags into xhtml. I know that many programs and sites do that but I don't think it is good practice. What I do want, though, is a way of adding some custom content that will be pre-processed by the content management system - end users will get valid xhtml content while content administrators will be able to edit special content via special user interface).
One of practical examples - I'd like to add the following: <youtube width='400' height='300' source='address'></youtube>. Admin should be see a youtube icon of the specified size and when clicking it, they will see a property window where they will be able to edit these properties. Before the content is sent to the browser by the cms system, it will preprocess the code and turn the <youtube></youtube> part into valid xhtml.
Re: Custom tags?
I've added the following to the config.js file:
Add the following to check what you get:
When I've figured out more, I'll share...