Hi Rob, Your observations about XSLT are correct.
Also, choosing always to expand empty elements when format and indent is invoked is not always a good idea in regard to browser compatibility: It is a good idea for <script> tags but it is not a good idea for line break which should remain collapsed: <br /> So what we will try to do in Oxygen 12 will be to respect the XHTML formatting guidelines when format and indent is applied on XHTML documents. http://www.w3.org/TR/xhtml1/#guidelines Regards, Radu -- Radu Coravu <oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger http://www.oxygenxml.com On 3/30/2010 3:53 PM, Rob Koberg wrote: > Hi, > > Radu, that will work in oxygen, but if you use that source in an XSL > 1.0 transform to XML (XHTML) it will close it again > > Another way: > > <script ...>//</script> > > The javascript comment between the open and close script tags will fix > the problem. You don't have any TEXTAREAs, do you? > > Or use XSL 2 and the XHTML output method. > > best, > -Rob > > On Tue, Mar 30, 2010 at 2:08 AM, Radu Coravu<[email protected]> wrote: > >> Hi Mark, >> >> I'm forwarding the solution to the users list, maybe some other people might >> find it useful. >> >> The problem is that by default pretty print in Oxygen collapses empty tags >> so that: >> <script type="text/JavaScript" xml:space="preserve" >> src="http://test/test.js"></script> >> becomes: >> <script type="text/JavaScript" xml:space="preserve" >> src="http://test/test.js"/> >> >> of course the 2 versions are XML equivalent but the browser wants only the >> first notation. >> >> So in the Oxygen Preferences->"Editor / Format / XML" page you can check the >> checkbox "Expand empty elements" to avoid problems like this when working >> with XHTML. >> >> Regards, >> Radu >> >> -- >> Radu Coravu >> <oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger >> http://www.oxygenxml.com >> >> On 3/30/2010 11:04 AM, Mark Wilson wrote: >> >> Hi Mark, >> >> Some samples would be great. >> Just send them to our support email address if they contain private data: >> http://www.oxygenxml.com/contact.html >> >> Regards, >> Radu >> >> -- >> Radu Coravu >> <oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger >> http://www.oxygenxml.com >> >> On 3/30/2010 7:33 AM, Mark Wilson wrote: >> >> I have an XHTML page constructed in Oxygen 11.2. It contains a JavaScript >> that works until I click the "Format and Indent" menu icon. After I do that, >> the script no longer works. Note: the script does not appear to change - all >> of the changes occur within the body of the HTML. >> >> Is this normal? I can send you the HTML page with the css files if that >> would help. >> >> Mark >> >> _______________________________________________ >> oXygen-user mailing list >> [email protected] >> http://www.oxygenxml.com/mailman/listinfo/oxygen-user >> >> >> >> >> >> _______________________________________________ >> oXygen-user mailing list >> [email protected] >> http://www.oxygenxml.com/mailman/listinfo/oxygen-user >> >> >> _______________________________________________ oXygen-user mailing list [email protected] http://www.oxygenxml.com/mailman/listinfo/oxygen-user
