Re: [WebDNA] Middle Question

This WebDNA talk-list message is from

2015


It keeps the original formatting.
numero = 112012
interpreted = N
texte = --Apple-Mail=_3551EC9B-4003-4847-8CA1-21C35CEA377E Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 I=E2=80=99ve always wondered if startafter and endafter were valid = options but never got round to testing. [Middle] has never really done = what I thought it should. Cheers =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D Steve Craig - Asylum Interactive Tel +44 1330 860550 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D http://www.asylumweb.com Email: steve@asylumweb.com Skype: s.craig - iChat: steve.craig =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > On 22 Jan 2015, at 21:29, David Bastedo wrote: >=20 > For EndBefore, the docs say: String of text characters to search for = defining the end of the text to be returned. All following text (and the = EndBefore text itself) will be ignored. --> this suggests that it should = ignore everything after this, including the stop token itself. >=20 > so, the block I am trying to remove: >=20 > by using : property=3D"og:title" as my starting point > and ideally, I want to use: " / as my end point. >=20 > According to the docs, I should then get: content=3D"Toronto Star = copyeditor edits memo announcing the elimination of copyeditor jobs >=20 >=20 > regardless, it isn't working and it is returning the rest of the page = after the place where it is supposed to stop. It is not stopping. > If I url the start and end, I get the same result - no stoppage. >=20 >=20 >=20 > [text]theOutPut=3D[tcpconnect host=3Dboingboing.net = ][!] > [/!][tcpsend skipheader=3DT]GET /2009/11/07/toronto-star-copyedi.html = HTTP/1.0[!] > [/!][UnURL]%0D%0A[/Unurl]Host: boingboing.net = [UnURL]%0D%0A%0D%0A[/UnURL][UnURL]%0D%0A[/Unurl][!= ] > [/!][/tcpsend][/tcpconnect][/text] >=20 > [text]myProp2=3D[middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]" = /[/url]][theOutPut][/middle][/text] =20 > myProp2: [myProp2]
>=20 >=20 > Theoretically, I should be able to stop middle on the first quot that = it runs into, as opposed to " / and I'd take />, but this breaks middle: >=20 > [middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]/>[/url]][t= heOutPut][/middle] >=20 > this I get the same result : > [middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]/[/url]][th= eOutPut][/middle] > as >=20 > [middle startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]"= /[/url]][theOutPut][/middle] >=20 > and > [middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]"[/url]][th= eOutPut][/middle] >=20 >=20 > none of these will stop anything past the endpoint from displaying.... = any ideas? >=20 > d. >=20 >=20 > On Thu, Jan 22, 2015 at 2:24 PM, Kenneth Grome = > wrote: > endbefore works from the end of the specified text, thus you > should expect this: >=20 > content=3D"Toronto Star copyeditor edits memo announcing the > elimination of copyeditor jobs" /> > > content=3D"http://boingboing.net/2009/11/07/toronto-star-copyedi.html = " > /> > content=3D"http://craphound.com/images/torstarsubsnit.jpeg = " >=20 > Regards, > Kenneth Grome > WebDNA Solutions > http://www.webdnasolutions.com > Web Database Systems and Linux Server Management >=20 >=20 > On 01/22/2015 12:52 PM, David Bastedo wrote: > > Is there somebody who can shed some light on the proper use of > > [middle]. It's not behaving as I would expect. > > > > I am attempting to extract open graph meta data from html after > > grabbing it via [tcpconnect] > > > > so here is a sample of what I want to extract: > > > > > > > > > > " /> > > " /> > > > > given this code: > > [text]theOutPut=3D[tcpconnect host=3Dboingboing.net = >][!] > > [/!][tcpsend skipheader=3DT]GET = /2009/11/07/toronto-star-copyedi.html HTTP/1.0[!] > > [/!][UnURL]%0D%0A[/Unurl]Host: boingboing.net = >[UnURL]%0D%0A%0D%0A[/UnURL][UnURL]%0D%0A[/Unurl][= !] > > [/!][/tcpsend][/tcpconnect][/text] > > > > [text]myProp=3D[middle startafter=3Dproperty=3D"og:title"&endbefore=3D= " /][theOutPut][/middle][/text] > > > > myProp: [myProp]
> > > > I would expect MyPprop to return: content=3D"Toronto Star = copyeditor edits memo announcing the elimination of copyeditor jobs > > > > but, it is returning: myProp: content=3D"Toronto Star copyeditor > > edits memo announcing the elimination of copyeditor jobs" /> and > > the rest of the page > > > > If I url everything, it doesn't work at all. Theoretically, middle > > is built for exactly this purpose and I should be able to run a > > series of Middles to extract specific og tags that I pre-describe. > > > > i'm using 6.2 > > > > Thanks in advance! > > > > d. > > > > > > > > --------------------------------------------------------- This > > message is sent to you because you are subscribed to the mailing > > list . To unsubscribe, E-mail to: archives: > > http://mail.webdna.us/list/talk@webdna.us = Bug Reporting: > > support@webdna.us > --------------------------------------------------------- > This message is sent to you because you are subscribed to > the mailing list >. > To unsubscribe, E-mail to: > > archives: http://mail.webdna.us/list/talk@webdna.us = > Bug Reporting: support@webdna.us >=20 >=20 >=20 >=20 > --=20 > David Bastedo > Ten Plus One Communications Inc. > http://www.10plus1.com > 416.277.4499 >=20 > --------------------------------------------------------- This message = is sent to you because you are subscribed to the mailing list . To = unsubscribe, E-mail to: archives: = http://mail.webdna.us/list/talk@webdna.us Bug Reporting: = support@webdna.us --Apple-Mail=_3551EC9B-4003-4847-8CA1-21C35CEA377E Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=utf-8 I=E2=80=99ve always wondered if startafter and endafter were = valid options but never got round to testing. [Middle] has never really = done what I thought it should.

Cheers
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
Steve Craig - Asylum Interactive
Tel +44 = 1330 860550
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
Skype: s.craig - = iChat: steve.craig
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D



On 22 Jan 2015, at 21:29, David Bastedo <david@10plus1.com> = wrote:

For EndBefore, the docs say: String of text characters to = search for defining the end of the text to=20 be returned. All following text (and the EndBefore text itself) will be=20= ignored. --> this suggests that it should ignore everything after = this, including the stop token itself.

so, the block I am trying to remove: <meta property=3D"og:title" content=3D"Toronto Star = copyeditor edits memo announcing the elimination of copyeditor jobs" = />

by = using : property=3D"og:title" as my starting = point
and ideally, I want = to use: " / as my end point.

According to the docs, I should then get:
content=3D"Toronto Star copyeditor edits = memo announcing the elimination of copyeditor jobs


regardless, it isn't working and it is returning the rest = of the page after the place where it is supposed to stop. It is not = stopping.
If I url the = start and end, I get the same result - no stoppage.



[text]theOutPut=3D[tcpconnect = host=3Dboingboing.net][!]
[/!][tcpsend = skipheader=3DT]GET /2009/11/07/toronto-star-copyedi.html HTTP/1.0[!]
[/!][UnURL]%0D%0A[/Unurl]Host: boingboing.net[UnURL]%0D%0A%0D%0A[/UnURL][UnURL]%0D%0A[/Unu= rl][!]
[/!][/tcpsend][/tcpconnect][/text]

[text]myProp2=3D[middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]" = /[/url]][theOutPut][/middle][/text] 
myProp2: = [myProp2]<br />


Theoretically, I should be = able to stop middle on the first quot that it runs into, as opposed to " = / and I'd take />, but this breaks middle:

[middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]/>[/= url]][theOutPut][/middle]

this I get the same result :
[middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]/[/url]= ][theOutPut][/middle]
as

[middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]" = /[/url]][theOutPut][/middle]

and
[middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]"[/url]= ][theOutPut][/middle]


none of these will stop anything past the endpoint from = displaying....  any ideas?

d.


On Thu, Jan 22, 2015 at 2:24 PM, Kenneth Grome = <ken@webdnasolutions.com> wrote:
endbefore works from = the end of the specified text, thus you
should expect this:

 content=3D"Toronto Star copyeditor edits memo announcing the
elimination of copyeditor jobs" />
<meta property=3D"og:description" content=3D"" />
<meta property=3D"og:url"
content=3D"http://boingboing.net/2009/11/07/toronto-star-copyedi.html"=
/>
<meta property=3D"og:image"
content=3D"http://craphound.com/images/torstarsubsnit.jpeg"

Regards,
Kenneth Grome
WebDNA Solutions
http://www.webdnasolutions.com
Web Database Systems and Linux Server Management


On 01/22/2015 12:52 PM, David Bastedo wrote:
> Is there somebody who can shed some light on the proper use of
> [middle]. It's not behaving as I would expect.
>
> I am attempting to extract open graph meta data from html after
> grabbing it via [tcpconnect]
>
> so here is a sample of what I want to extract:
>
> <meta property=3D"og:type" content=3D"article" />
> <meta property=3D"og:title" content=3D"Toronto Star copyeditor = edits memo announcing the elimination of copyeditor jobs" />
> <meta property=3D"og:description" content=3D"" />
> <meta property=3D"og:url" content=3D"http://boingboing.net/2009/11/07/toronto-star-copyedi.html"= />
> <meta property=3D"og:image" content=3D"http://craphound.com/images/torstarsubsnit.jpeg" = />
>
> given this code:
> [text]theOutPut=3D[tcpconnect host=3Dboingboing.net <http://boingboing.net>][!]
> [/!][tcpsend skipheader=3DT]GET = /2009/11/07/toronto-star-copyedi.html HTTP/1.0[!]
> [/!][UnURL]%0D%0A[/Unurl]Host: boingboing.net <http://boingboing.net>[UnURL]%0D%0A%0D%0A[/UnURL][UnURL]= %0D%0A[/Unurl][!]
> [/!][/tcpsend][/tcpconnect][/text]
>
> [text]myProp=3D[middle = startafter=3Dproperty=3D"og:title"&endbefore=3D" = /][theOutPut][/middle][/text]
>
> myProp: [myProp]<br />
>
> I would expect MyPprop to return:   content=3D"Toronto = Star copyeditor edits memo announcing the elimination of copyeditor = jobs
>
> but, it is returning: myProp: content=3D"Toronto Star copyeditor
> edits memo announcing the elimination of copyeditor jobs" /> = and
> the rest of the page
>
> If I url everything, it doesn't work at all. Theoretically, = middle
> is built for exactly this purpose and I should be able to run a
> series of Middles to extract specific og tags that I = pre-describe.
>
> i'm using 6.2
>
> Thanks in advance!
>
> d.
>
>
>
> --------------------------------------------------------- = This
> message is sent to you because you are subscribed to the mailing
> list . To unsubscribe, E-mail to: archives:
> http://mail.webdna.us/list/talk@webdna.us= Bug Reporting:
> support@webdna.us
---------------------------------------------------------
This message is sent to you because you are subscribed to
the mailing list <talk@webdna.us>.
To unsubscribe, E-mail to: <talk-leave@webdna.us>
archives: http://mail.webdna.us/list/talk@webdna.us
Bug Reporting: support@webdna.us




--
David = Bastedo
Ten Plus One Communications Inc.
http://www.10plus1.com
416.277.4499
--------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us

= --Apple-Mail=_3551EC9B-4003-4847-8CA1-21C35CEA377E-- Associated Messages, from the most recent to the oldest:

    
  1. Re: [WebDNA] Middle Question (Kenneth Grome 2015)
  2. Re: [WebDNA] Middle Question (christophe.billiottet@webdna.us 2015)
  3. Re: [WebDNA] Middle Question (David Bastedo 2015)
  4. Re: [WebDNA] Middle Question (Tom Duke 2015)
  5. Re: [WebDNA] Middle Question (christophe.billiottet@webdna.us 2015)
  6. Re: [WebDNA] Middle Question (Kenneth Grome 2015)
  7. Re: [WebDNA] Middle Question (David Bastedo 2015)
  8. Re: [WebDNA] Middle Question (Kenneth Grome 2015)
  9. Re: [WebDNA] Middle Question (Kenneth Grome 2015)
  10. Re: [WebDNA] Middle Question (David Bastedo 2015)
  11. Re: [WebDNA] Middle Question (Terry Wilson 2015)
  12. Re: [WebDNA] Middle Question (Kenneth Grome 2015)
  13. Re: [WebDNA] Middle Question (Kenneth Grome 2015)
  14. Re: [WebDNA] Middle Question (David Bastedo 2015)
  15. Re: [WebDNA] Middle Question (David Bastedo 2015)
  16. Re: [WebDNA] Middle Question (Kenneth Grome 2015)
  17. Re: [WebDNA] Middle Question (Terry Wilson 2015)
  18. Re: [WebDNA] Middle Question (Kenneth Grome 2015)
  19. Re: [WebDNA] Middle Question (Chris 2015)
  20. Re: [WebDNA] Middle Question (Chris 2015)
  21. Re: [WebDNA] Middle Question (Kenneth Grome 2015)
  22. Re: [WebDNA] Middle Question (Steve Craig 2015)
  23. Re: [WebDNA] Middle Question (David Bastedo 2015)
  24. Re: [WebDNA] Middle Question (Kenneth Grome 2015)
  25. [WebDNA] Middle Question (David Bastedo 2015)
--Apple-Mail=_3551EC9B-4003-4847-8CA1-21C35CEA377E Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 I=E2=80=99ve always wondered if startafter and endafter were valid = options but never got round to testing. [middle] has never really done = what I thought it should. Cheers =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D Steve Craig - Asylum Interactive Tel +44 1330 860550 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D http://www.asylumweb.com Email: steve@asylumweb.com Skype: s.craig - iChat: steve.craig =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > On 22 Jan 2015, at 21:29, David Bastedo wrote: >=20 > For EndBefore, the docs say: String of text characters to search for = defining the end of the text to be returned. All following text (and the = EndBefore text itself) will be ignored. --> this suggests that it should = ignore everything after this, including the stop token itself. >=20 > so, the block I am trying to remove: >=20 > by using : property=3D"og:title" as my starting point > and ideally, I want to use: " / as my end point. >=20 > According to the docs, I should then get: content=3D"Toronto Star = copyeditor edits memo announcing the elimination of copyeditor jobs >=20 >=20 > regardless, it isn't working and it is returning the rest of the page = after the place where it is supposed to stop. It is not stopping. > If I url the start and end, I get the same result - no stoppage. >=20 >=20 >=20 > [text]theOutPut=3D[tcpconnect host=3Dboingboing.net = ][!] > [/!][tcpsend skipheader=3DT]GET /2009/11/07/toronto-star-copyedi.html = HTTP/1.0[!] > [/!][unurl]%0D%0A[/Unurl]Host: boingboing.net = [unurl]%0D%0A%0D%0A[/UnURL][unurl]%0D%0A[/Unurl][!= ] > [/!][/tcpsend][/tcpconnect][/text] >=20 > [text]myProp2=3D[middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]" = /[/url]][theOutPut][/middle][/text] =20 > myProp2: [myProp2]
>=20 >=20 > Theoretically, I should be able to stop middle on the first quot that = it runs into, as opposed to " / and I'd take />, but this breaks middle: >=20 > [middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]/>[/url]][t= heOutPut][/middle] >=20 > this I get the same result : > [middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]/[/url]][th= eOutPut][/middle] > as >=20 > [middle startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]"= /[/url]][theOutPut][/middle] >=20 > and > [middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]"[/url]][th= eOutPut][/middle] >=20 >=20 > none of these will stop anything past the endpoint from displaying.... = any ideas? >=20 > d. >=20 >=20 > On Thu, Jan 22, 2015 at 2:24 PM, Kenneth Grome = > wrote: > endbefore works from the end of the specified text, thus you > should expect this: >=20 > content=3D"Toronto Star copyeditor edits memo announcing the > elimination of copyeditor jobs" /> > > content=3D"http://boingboing.net/2009/11/07/toronto-star-copyedi.html = " > /> > content=3D"http://craphound.com/images/torstarsubsnit.jpeg = " >=20 > Regards, > Kenneth Grome > WebDNA Solutions > http://www.webdnasolutions.com > Web Database Systems and Linux Server Management >=20 >=20 > On 01/22/2015 12:52 PM, David Bastedo wrote: > > Is there somebody who can shed some light on the proper use of > > [middle]. It's not behaving as I would expect. > > > > I am attempting to extract open graph meta data from html after > > grabbing it via [tcpconnect] > > > > so here is a sample of what I want to extract: > > > > > > > > > > " /> > > " /> > > > > given this code: > > [text]theOutPut=3D[tcpconnect host=3Dboingboing.net = >][!] > > [/!][tcpsend skipheader=3DT]GET = /2009/11/07/toronto-star-copyedi.html HTTP/1.0[!] > > [/!][unurl]%0D%0A[/Unurl]Host: boingboing.net = >[unurl]%0D%0A%0D%0A[/UnURL][unurl]%0D%0A[/Unurl][= !] > > [/!][/tcpsend][/tcpconnect][/text] > > > > [text]myProp=3D[middle startafter=3Dproperty=3D"og:title"&endbefore=3D= " /][theOutPut][/middle][/text] > > > > myProp: [myProp]
> > > > I would expect MyPprop to return: content=3D"Toronto Star = copyeditor edits memo announcing the elimination of copyeditor jobs > > > > but, it is returning: myProp: content=3D"Toronto Star copyeditor > > edits memo announcing the elimination of copyeditor jobs" /> and > > the rest of the page > > > > If I url everything, it doesn't work at all. Theoretically, middle > > is built for exactly this purpose and I should be able to run a > > series of Middles to extract specific og tags that I pre-describe. > > > > i'm using 6.2 > > > > Thanks in advance! > > > > d. > > > > > > > > --------------------------------------------------------- This > > message is sent to you because you are subscribed to the mailing > > list . To unsubscribe, E-mail to: archives: > > http://mail.webdna.us/list/talk@webdna.us = Bug Reporting: > > support@webdna.us > --------------------------------------------------------- > This message is sent to you because you are subscribed to > the mailing list >. > To unsubscribe, E-mail to: > > archives: http://mail.webdna.us/list/talk@webdna.us = > Bug Reporting: support@webdna.us >=20 >=20 >=20 >=20 > --=20 > David Bastedo > Ten Plus One Communications Inc. > http://www.10plus1.com > 416.277.4499 >=20 > --------------------------------------------------------- This message = is sent to you because you are subscribed to the mailing list . To = unsubscribe, E-mail to: archives: = http://mail.webdna.us/list/talk@webdna.us Bug Reporting: = support@webdna.us --Apple-Mail=_3551EC9B-4003-4847-8CA1-21C35CEA377E Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=utf-8 I=E2=80=99ve always wondered if startafter and endafter were = valid options but never got round to testing. [middle] has never really = done what I thought it should.

Cheers
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
Steve Craig - Asylum Interactive
Tel +44 = 1330 860550
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
Skype: s.craig - = iChat: steve.craig
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D



On 22 Jan 2015, at 21:29, David Bastedo <david@10plus1.com> = wrote:

For EndBefore, the docs say: String of text characters to = search for defining the end of the text to=20 be returned. All following text (and the EndBefore text itself) will be=20= ignored. --> this suggests that it should ignore everything after = this, including the stop token itself.

so, the block I am trying to remove: <meta property=3D"og:title" content=3D"Toronto Star = copyeditor edits memo announcing the elimination of copyeditor jobs" = />

by = using : property=3D"og:title" as my starting = point
and ideally, I want = to use: " / as my end point.

According to the docs, I should then get:
content=3D"Toronto Star copyeditor edits = memo announcing the elimination of copyeditor jobs


regardless, it isn't working and it is returning the rest = of the page after the place where it is supposed to stop. It is not = stopping.
If I url the = start and end, I get the same result - no stoppage.



[text]theOutPut=3D[tcpconnect = host=3Dboingboing.net][!]
[/!][tcpsend = skipheader=3DT]GET /2009/11/07/toronto-star-copyedi.html HTTP/1.0[!]
[/!][unurl]%0D%0A[/Unurl]Host: boingboing.net[unurl]%0D%0A%0D%0A[/UnURL][unurl]%0D%0A[/Unu= rl][!]
[/!][/tcpsend][/tcpconnect][/text]

[text]myProp2=3D[middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]" = /[/url]][theOutPut][/middle][/text] 
myProp2: = [myProp2]<br />


Theoretically, I should be = able to stop middle on the first quot that it runs into, as opposed to " = / and I'd take />, but this breaks middle:

[middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]/>[/= url]][theOutPut][/middle]

this I get the same result :
[middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]/[/url]= ][theOutPut][/middle]
as

[middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]" = /[/url]][theOutPut][/middle]

and
[middle = startafter=3D[url]property=3D"og:image"[/url]&endbefore=3D[url]"[/url]= ][theOutPut][/middle]


none of these will stop anything past the endpoint from = displaying....  any ideas?

d.


On Thu, Jan 22, 2015 at 2:24 PM, Kenneth Grome = <ken@webdnasolutions.com> wrote:
endbefore works from = the end of the specified text, thus you
should expect this:

 content=3D"Toronto Star copyeditor edits memo announcing the
elimination of copyeditor jobs" />
<meta property=3D"og:description" content=3D"" />
<meta property=3D"og:url"
content=3D"http://boingboing.net/2009/11/07/toronto-star-copyedi.html"=
/>
<meta property=3D"og:image"
content=3D"http://craphound.com/images/torstarsubsnit.jpeg"

Regards,
Kenneth Grome
WebDNA Solutions
http://www.webdnasolutions.com
Web Database Systems and Linux Server Management


On 01/22/2015 12:52 PM, David Bastedo wrote:
> Is there somebody who can shed some light on the proper use of
> [middle]. It's not behaving as I would expect.
>
> I am attempting to extract open graph meta data from html after
> grabbing it via [tcpconnect]
>
> so here is a sample of what I want to extract:
>
> <meta property=3D"og:type" content=3D"article" />
> <meta property=3D"og:title" content=3D"Toronto Star copyeditor = edits memo announcing the elimination of copyeditor jobs" />
> <meta property=3D"og:description" content=3D"" />
> <meta property=3D"og:url" content=3D"http://boingboing.net/2009/11/07/toronto-star-copyedi.html"= />
> <meta property=3D"og:image" content=3D"http://craphound.com/images/torstarsubsnit.jpeg" = />
>
> given this code:
> [text]theOutPut=3D[tcpconnect host=3Dboingboing.net <http://boingboing.net>][!]
> [/!][tcpsend skipheader=3DT]GET = /2009/11/07/toronto-star-copyedi.html HTTP/1.0[!]
> [/!][unurl]%0D%0A[/Unurl]Host: boingboing.net <http://boingboing.net>[unurl]%0D%0A%0D%0A[/UnURL][unurl]= %0D%0A[/Unurl][!]
> [/!][/tcpsend][/tcpconnect][/text]
>
> [text]myProp=3D[middle = startafter=3Dproperty=3D"og:title"&endbefore=3D" = /][theOutPut][/middle][/text]
>
> myProp: [myProp]<br />
>
> I would expect MyPprop to return:   content=3D"Toronto = Star copyeditor edits memo announcing the elimination of copyeditor = jobs
>
> but, it is returning: myProp: content=3D"Toronto Star copyeditor
> edits memo announcing the elimination of copyeditor jobs" /> = and
> the rest of the page
>
> If I url everything, it doesn't work at all. Theoretically, = middle
> is built for exactly this purpose and I should be able to run a
> series of Middles to extract specific og tags that I = pre-describe.
>
> i'm using 6.2
>
> Thanks in advance!
>
> d.
>
>
>
> --------------------------------------------------------- = This
> message is sent to you because you are subscribed to the mailing
> list . To unsubscribe, E-mail to: archives:
> http://mail.webdna.us/list/talk@webdna.us= Bug Reporting:
> support@webdna.us
---------------------------------------------------------
This message is sent to you because you are subscribed to
the mailing list <talk@webdna.us>.
To unsubscribe, E-mail to: <talk-leave@webdna.us>
archives: http://mail.webdna.us/list/talk@webdna.us
Bug Reporting: support@webdna.us




--
David = Bastedo
Ten Plus One Communications Inc.
http://www.10plus1.com
416.277.4499
--------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us

= --Apple-Mail=_3551EC9B-4003-4847-8CA1-21C35CEA377E-- Steve Craig

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

Its not that weird. (1997) Generating Report Totals (1997) WebCat2: multiple currency support (1997) Location of Browser Info.txt file (1997) [WebDNA] TCPConnect Problem (2010) Great product and great job ! (1997) [OT] Checkboxes! Javascript? (2005) Summ=T Problem (1997) Enterprise Server (1998) [WebDNA] Ubuntu 11.10 (2012) Configuring E-mail (1997) Am I going senile? (Price recalc based on quantity) (1997) Install Webcatalog under NT4.0 and Microsoft IIS 2.0 (1997) Forbidden CGI Error (1997) European dates (1998) Cancel Subscription (1996) Random Image (1998) problem 'building' field names (2000) WebStar Secure on other machine (1997) bug in [SendMail] (1997)