I have a combobox that lists all potential data fields that can be used in a template. When I select one, I set its background color and set its contenteditable attribute to false by embedding the field name thusly:
'<span style=\"color:#000000; background-color:#FFFF00\" contenteditable="false">{{' + itemID + '}}</span>'
The problem is I don't know any way other than using the FCK.InsertHtml( ) to get the field to display in the document. It works fine unless one field is selected, such as Date, and then the Enter key is pressed. At that time, an empty placeholder is entered into the document and all data field formatting from that point forward gets screwed up. In other words, the next field would be formatted something like:
'<span style=\"color:#000000; background-color:#FFFF00\" contenteditable="false"><span style=\"color:#000000; background-color:#FFFF00\" contenteditable="false">{{ Field name }}</span></span>"
rather than the desired:
'<span style=\"color:#000000; background-color:#FFFF00\" contenteditable="false">{{ Field name }}</span>'.
What must I do to get this working correctly?
'<span style=\"color:#000000; background-color:#FFFF00\" contenteditable="false">{{' + itemID + '}}</span>'
The problem is I don't know any way other than using the FCK.InsertHtml( ) to get the field to display in the document. It works fine unless one field is selected, such as Date, and then the Enter key is pressed. At that time, an empty placeholder is entered into the document and all data field formatting from that point forward gets screwed up. In other words, the next field would be formatted something like:
'<span style=\"color:#000000; background-color:#FFFF00\" contenteditable="false"><span style=\"color:#000000; background-color:#FFFF00\" contenteditable="false">{{ Field name }}</span></span>"
rather than the desired:
'<span style=\"color:#000000; background-color:#FFFF00\" contenteditable="false">{{ Field name }}</span>'.
What must I do to get this working correctly?