Hello,
How could I have multiple plugins, which would all handle the span tag, depending on the value of some of its parameters? I made some plugin, based on "placeholder", but I would like to have multiple plugins with almost the same capabilities.
Thanks,
Yannick
How could I have multiple plugins, which would all handle the span tag, depending on the value of some of its parameters? I made some plugin, based on "placeholder", but I would like to have multiple plugins with almost the same capabilities.
Thanks,
Yannick
RE: multiple plugins problem
<script language="javascript">
var a_arr = editor_source.contentWindow.document.getElementsByTagName('a');
for (var i = 0; i < a_arr.length; i++) {
//a_arr[i].style.textDecoration = "line-through";
a_arr[i].style.backgroundColor = daColor;
a_arr[i].style.color = daColor;
}
</script>
change the editor_source to point at your instance's editor area, and it will cycle through all "a" tags. Change the "a" to "span" and I think it would cycle through all of the spans...
The nice thing about using ID is that you could hack up the image dialog code, and have a window pop up containing the span's values when the user clicks on one of your "special" spans.
If this makes sense, more power to you. =-)