Those are not really a work around, but rather a mechanism to falling back to the more flexible tools when more efficient tools don't suffice for a certain screen/etc, and they are all over the framework.
The best practice is not to avoid them altogether, but rather when you use platform-specific.html or whatever that you also include alternatives for other "platforms" (or rather, render modes) like xsl-fo, csv, or whatever. This can be done in OFBiz, though the tag names are a little funny and don't make what you're doing as obvious. -David > On 16 Apr 2015, at 04:24, Adrian Crum <adrian.c...@sandglass-software.com> > wrote: > > True, there are widget elements that allow you to use HTML-specific > artifacts, but those were created as a workaround. > > I don't agree that "no one is practicing this." There have been efforts in > the past where FreeMarker templates were replaced with widgets. Also, there > are many instances in the project where widgets are used to produce PDF and > CSV files - so someone practiced "generic layout only" to create those files. > > Throughout my presentation, I used examples from the current trunk to > demonstrate how NOT to do things. So, I don't believe that the current trunk > is a good representation of best practices. > > > Adrian Crum > Sandglass Software > www.sandglass-software.com > > On 4/16/2015 12:13 PM, Taher Alkhateeb wrote: >> Hi Adrian, >> >> I have a comment on your presentation. You have stated below slide 10 the >> following: >> >> "A common mistake new developers make is assuming these XML screen >> definitions will only output HTML – so they embed markup and JavaScript in >> the XML. That should never be done! These XML files describe a generic >> layout only." >> >> However, the tag <platform-specific><html><html-template >> location="..."></html></platform-specific> exists in thousands of locations >> all over the framework, core applications and specialpurpose. So it seems >> like the intention you mentioned above is not really applicable in OFBiz. >> >> I am wondering if this statement is realistic or applicable given that it >> seems no one is really practicing this and using OFBiz as an HTML platform >> more than anything else. I would appreciate hearing your thoughts on that. >> >> Cheers, >> >> Taher Alkhateeb >> >> On Thu, Apr 16, 2015 at 1:41 PM, Adrian Crum < >> adrian.c...@sandglass-software.com> wrote: >> >>> Here is the slideshow from my presentation at ApacheCon: >>> >>> http://www.sandglass-software.com/products/sandglass/ >>> documents/2015_ApacheCon_Reduced.pdf >>> >>> -- >>> Adrian Crum >>> Sandglass Software >>> www.sandglass-software.com >>> >>