Re: [Framers] Format of XML element attributes
On 7/24/2019 1:53 PM, cuc tu wrote: I am saving out structured XML. Frame inserts spaces in the attribute = "value" (should be attribute="value"), which is not acceptable (sloppy code they tell me). Can that be changed? The definition of XML allows white space on either side of the equal sign. Whoever told you that this style is sloppy doesn't know XML and is probably using a non-conforming parser. That said, through FrameMaker 2015, FrameMaker generated a single space on both sides of the equal sign. Since then, it does not. To answer your question, there is no option in FM to control the presence of these spaces. However, if you are using an older version of FrameMaker and want to suppress the spaces, you can use an XSLT post-process that simply writes XML equivalent to its import. Such an identity transform will not write the spaces. Also, extra table element attributes are inserted, such as column width. None of that is acceptable, either. I can only have the attributes defined by the DTD. Is there something I need to add to the R/W Rules file to suppress that? My R/W Rules file is very limited and I only have the include iosall.rw and a graphic element. Check the Structure Application Developer's Guide and the Structure Application Developer Reference for a complete description of the read/write rules that control the attributes FrameMaker uses to control tables. It should not generate attributes that are not declared in the DTD. If it is writing FrameMaker properties (such as column width) to an existing attribute, you can use a read/write rule such as: element "/table/" { is fm table element; attribute "/att/" is fm attribute; } Here, /table /is the name of the table element and /att /is the name of the attribute. The rule specifies that the XML attribute named /att/ is used for a FrameMaker attribute of the same name and not to indicate a table property. --Lynne -- Lynne A. Price Text Structure Consulting, Inc. Specializing in structured FrameMaker consulting, application development, and training lpr...@txstruct.comhttp://www.txstruct.com voice/fax: (510) 583-1505 cell phone: (510) 421-2284 ___ This message is from the Framers mailing list Send messages to framers@lists.frameusers.com Visit the list's homepage at http://www.frameusers.com Archives located at http://www.mail-archive.com/framers%40lists.frameusers.com/ Subscribe and unsubscribe at http://lists.frameusers.com/listinfo.cgi/framers-frameusers.com Send administrative questions to listad...@frameusers.com
Re: [Framers] Format of XML element attributes
Hi Cuc Tu, There's absolutely nothing wrong with spaces around the = in an attribute it's still well-formed XML which should be all that matters. Why would it be unacceptable when the XML specification permits it and some XML editors create it that way? It really does not matter and if an XML system can't handle it then the limitation is with that system. Ian -Original Message- From: Framers On Behalf Of cuc tu Sent: 24 July 2019 21:53 To: framers@lists.frameusers.com Subject: [Framers] Format of XML element attributes Howdy Framers. I am saving out structured XML. Frame inserts spaces in the attribute = "value" (should be attribute="value"), which is not acceptable (sloppy code they tell me). Can that be changed? Also, extra table element attributes are inserted, such as column width. None of that is acceptable, either. I can only have the attributes defined by the DTD. Is there something I need to add to the R/W Rules file to suppress that? My R/W Rules file is very limited and I only have the include iosall.rw and a graphic element. Thanks, Cuc Tu ___ This message is from the Framers mailing list Send messages to framers@lists.frameusers.com Visit the list's homepage at http://www.frameusers.com Archives located at http://www.mail-archive.com/framers%40lists.frameusers.com/ Subscribe and unsubscribe at http://lists.frameusers.com/listinfo.cgi/framers-frameusers.com Send administrative questions to listad...@frameusers.com ___ This message is from the Framers mailing list Send messages to framers@lists.frameusers.com Visit the list's homepage at http://www.frameusers.com Archives located at http://www.mail-archive.com/framers%40lists.frameusers.com/ Subscribe and unsubscribe at http://lists.frameusers.com/listinfo.cgi/framers-frameusers.com Send administrative questions to listad...@frameusers.com
[Framers] Format of XML element attributes
Howdy Framers. I am saving out structured XML. Frame inserts spaces in the attribute = "value" (should be attribute="value"), which is not acceptable (sloppy code they tell me). Can that be changed? Also, extra table element attributes are inserted, such as column width. None of that is acceptable, either. I can only have the attributes defined by the DTD. Is there something I need to add to the R/W Rules file to suppress that? My R/W Rules file is very limited and I only have the include iosall.rw and a graphic element. Thanks, Cuc Tu ___ This message is from the Framers mailing list Send messages to framers@lists.frameusers.com Visit the list's homepage at http://www.frameusers.com Archives located at http://www.mail-archive.com/framers%40lists.frameusers.com/ Subscribe and unsubscribe at http://lists.frameusers.com/listinfo.cgi/framers-frameusers.com Send administrative questions to listad...@frameusers.com