Re: TeraScript-Talk: @DOM
I did a @tokenize <@CRLF> and @transpose to assess each line individually. I then grabbed all lines that composed the lineitems (so were in a predictable format), put a before the first line and after the last and parsed it successfully as XML. Works a treat. Wayne > On 10 Apr 2018, at 1:11 am, Robert Shubert wrote: > > Yes, however, HTML is rarely valid XML. XHTML was supposed to address this, > but in reality you're not likely to get an HTML file to parse. > > -Original Message- > From: Wayne Irvine [mailto:wa...@byteserve.com.au] > Sent: Sunday, April 08, 2018 5:40 PM > To: TeraScript-Talk@terascript.com > Subject: TeraScript-Talk: @DOM > > I have used the @DOM tag previously to encapsulate XML and then referred to > various elements within it. > > Does it also work for HTML? Can I encapsulate a page then refer to various > nodes in it using the Document Object Model nomenclature? > > Wayne > > Byteserve Pty Ltd > w: http://www.byteserve.com.au/ > e: i...@byteserve.com.au > p: +61 02 9960 6099 > m: 0409 960 609 > f: +61 02 9960 6088 > > > > > > > To unsubscribe from this list, please send an email to > lists...@terascript.com with "unsubscribe terascript-talk" in the body. > > > > > > > To unsubscribe from this list, please send an email to > lists...@terascript.com with "unsubscribe terascript-talk" in the body. > Byteserve Pty Ltd w: http://www.byteserve.com.au/ e: i...@byteserve.com.au p: +61 02 9960 6099 m: 0409 960 609 f: +61 02 9960 6088 To unsubscribe from this list, please send an email to lists...@terascript.com with "unsubscribe terascript-talk" in the body.
RE: TeraScript-Talk: @DOM
Yes, however, HTML is rarely valid XML. XHTML was supposed to address this, but in reality you're not likely to get an HTML file to parse. -Original Message- From: Wayne Irvine [mailto:wa...@byteserve.com.au] Sent: Sunday, April 08, 2018 5:40 PM To: TeraScript-Talk@terascript.com Subject: TeraScript-Talk: @DOM I have used the @DOM tag previously to encapsulate XML and then referred to various elements within it. Does it also work for HTML? Can I encapsulate a page then refer to various nodes in it using the Document Object Model nomenclature? Wayne Byteserve Pty Ltd w: http://www.byteserve.com.au/ e: i...@byteserve.com.au p: +61 02 9960 6099 m: 0409 960 609 f: +61 02 9960 6088 To unsubscribe from this list, please send an email to lists...@terascript.com with "unsubscribe terascript-talk" in the body. To unsubscribe from this list, please send an email to lists...@terascript.com with "unsubscribe terascript-talk" in the body.
TeraScript-Talk: @DOM
I have used the @DOM tag previously to encapsulate XML and then referred to various elements within it. Does it also work for HTML? Can I encapsulate a page then refer to various nodes in it using the Document Object Model nomenclature? Wayne Byteserve Pty Ltd w: http://www.byteserve.com.au/ e: i...@byteserve.com.au p: +61 02 9960 6099 m: 0409 960 609 f: +61 02 9960 6088 To unsubscribe from this list, please send an email to lists...@terascript.com with "unsubscribe terascript-talk" in the body.
Re: TeraScript-Talk: DOM assignment help
Thanks, Ben! I had just figured that out. Bill On Wed, Mar 7, 2012 at 12:30 PM, Ben Johansen wrote: > Your missing the step where you convert it to a dom object using the @DOM > > > On Mar 7, 2012, at 9:01 AM, Bill Downall wrote: > > I'm sure somebody has the quick trick here. > > I want to create XML in text, and then convert/assign it into a DOM > variable. But both of these look like plain ordinary variables, and the > second cannot be passed to a method that expects a DOM paramaeter. In the > debug output of request varaibles, it doesn't say anything like > "myDOM=[DOM: 071BBC38];", it just shows the HTML text. > > Thanks. > > Bill > > <@assign request$myHTML value=' > > UNKNOWN PROVIDER FOR <@var request$CompanyNum><@var > request$PolNumber> > > Business > > > > > > > > Business > > > '> > > <@assign request$myDom value='<@var request$myHTML type="DOM" > element="root()">'> > > > -- > To unsubscribe from this list, please send an email to > lists...@terascript.com with "unsubscribe terascript-talk" in the body. > > > Ben Johansen > http://www.webspinr.com > b...@webspinr.com > Phone: 503-477-5409 > Mobile: 360-600-7775 > > > > > > > -- > To unsubscribe from this list, please send an email to > lists...@terascript.com with "unsubscribe terascript-talk" in the body. > To unsubscribe from this list, please send an email to lists...@terascript.com with "unsubscribe terascript-talk" in the body.
Re: TeraScript-Talk: DOM assignment help
Your missing the step where you convert it to a dom object using the @DOM On Mar 7, 2012, at 9:01 AM, Bill Downall wrote: > I'm sure somebody has the quick trick here. > > I want to create XML in text, and then convert/assign it into a DOM variable. > But both of these look like plain ordinary variables, and the second cannot > be passed to a method that expects a DOM paramaeter. In the debug output of > request varaibles, it doesn't say anything like "myDOM=[DOM: 071BBC38];", it > just shows the HTML text. > > Thanks. > > Bill > > <@assign request$myHTML value=' > > UNKNOWN PROVIDER FOR <@var request$CompanyNum><@var > request$PolNumber> > > Business > > > > > > > > Business > > > '> > > <@assign request$myDom value='<@var request$myHTML type="DOM" > element="root()">'> > > > To unsubscribe from this list, please send an email to > lists...@terascript.com with "unsubscribe terascript-talk" in the body. Ben Johansen http://www.webspinr.com b...@webspinr.com Phone: 503-477-5409 Mobile: 360-600-7775 To unsubscribe from this list, please send an email to lists...@terascript.com with "unsubscribe terascript-talk" in the body.
TeraScript-Talk: DOM assignment help
I'm sure somebody has the quick trick here. I want to create XML in text, and then convert/assign it into a DOM variable. But both of these look like plain ordinary variables, and the second cannot be passed to a method that expects a DOM paramaeter. In the debug output of request varaibles, it doesn't say anything like "myDOM=[DOM: 071BBC38];", it just shows the HTML text. Thanks. Bill <@assign request$myHTML value=' UNKNOWN PROVIDER FOR <@var request$CompanyNum><@var request$PolNumber> Business Business '> <@assign request$myDom value='<@var request$myHTML type="DOM" element="root()">'> To unsubscribe from this list, please send an email to lists...@terascript.com with "unsubscribe terascript-talk" in the body.