Timeline for Creating Rich Text Field via Core Service
Current License: CC BY-SA 3.0
14 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
May 4, 2013 at 11:36 | comment | added | Dominic Cronin | As far as I know, there is no "other" XSLT. There's the RTF "filtering" XSLT, which is used by the GUI, and not by the API. Anyway, in general, it's not XSLT that compacts your tags, but the fact of loading it into a DOM representation. But you shouldn't really worry too much about it. If your site design demands the "verbose" format for a tag, then make sure that's what your templates output. | |
May 3, 2013 at 22:07 | comment | added | Chris Morgan | The XSLT applied to the RTF when it is created via Core Service appears to not be the same as the XSLT applied if you edit it via the GUI. If I edit via GUI any modification I make to the RTF XSLT is applied e.g. adding nbsp or span tag. When created through Core Service the modified XSLT does not seem to apply and empty tags are short circuited to <a/> etc | |
May 3, 2013 at 22:03 | comment | added | Chris Morgan | So this is the problem. When you take this to the browser <a name="abc" id="abc"/> is treated as an opening anchor tag | |
May 3, 2013 at 22:00 | comment | added | Dominic Cronin | As you can see in my "Further edit", there's no content between the opening and closing tags which might prevent an XML representation from compacting it to a self-closing tag. This looks like the core service really treats it as a string all the way. | |
May 3, 2013 at 21:57 | history | edited | Dominic Cronin | CC BY-SA 3.0 |
added 112 characters in body
|
May 3, 2013 at 21:10 | comment | added | Chris Morgan | There is no processing on RTF field in template. Just output. The closing tag is missing in the GUI on the RTF source tab | |
May 3, 2013 at 21:09 | comment | added | Chris Morgan | If I put <a id="abc" name="abc"> </a> then it persists. The space counts as some content in the tag | |
May 3, 2013 at 21:08 | comment | added | Chris Morgan | I see that my component.Content before CoreService.Create has the closing anchor tag, and immediately after it does not have closing anchor. | |
May 3, 2013 at 21:05 | comment | added | Chris Morgan | Thanks for checking this out! Is this the "source" tab of the component? What do you see in the "source" tab of the rich text field? | |
May 3, 2013 at 21:04 | comment | added | Dominic Cronin | I've updated, my answer. I note that you mention publish/preview time. What do you see when you open up the component in the GUI? Could it be a templating issue? | |
May 3, 2013 at 21:03 | history | edited | Dominic Cronin | CC BY-SA 3.0 |
added 506 characters in body
|
May 3, 2013 at 20:54 | comment | added | Chris Morgan | If it behaves as per my implementation you will end up with <p xmlns="w3.org/1999/xhtml">this is a test <a name="abc" id="abc" /></p> at publish/preview time | |
May 3, 2013 at 20:39 | comment | added | Chris Morgan | Is NewField of type RTF? If so add <Content xmlns="uuid:985d42e5-976f-46e1-9727-772cb961353f"> <NewField><p xmlns="w3.org/1999/xhtml">this is a test <a name="abc" id="abc"></a></NewField> </Content> | |
May 3, 2013 at 20:10 | history | answered | Dominic Cronin | CC BY-SA 3.0 |