Re: [WebDNA] multi [sendmail] inside [search]

This WebDNA talk-list message is from

2012


It keeps the original formatting.
numero = 109295
interpreted = N
texte = >=20 >>> The problem is, WebDNA doesn't like using a [sendmail] >>> tag inside of a [search...][founditems] routine. >>=20 >> Of course it does, I've been doing this for years. What=20 >> seems to be the problem that causes you to say this? >=20 >=20 > The simple problem is that it won't work... > Here's a sample.... >=20 > [search db=3D../login/website_users.db& code..blah..code...] > [founditems]  =20 > code..blah..code... > [showif code..blah..code... > [loop start=3D[ code..blah..code...]= = =09 > [text] message =3D > [showif code..blah..code... > [/showif] > [/text] > [/loop] > [/showif] =20 >  [sendmail = to=3Dtimeclock@domain.com&from=3DWebpage@domain.com&subject=3DStaff Over = 40 message (no reply)&content-type=3Dtext/html] > [message] > [/sendmail] > code..blah..code... > [/founditems] > [/search] >=20 > But this does work, but with only the last item found.... >=20 > [search db=3D../login/website_users.db& code..blah..code...] > [founditems]  =20 > code..blah..code... > [showif code..blah..code... > [loop start=3D[ code..blah..code...]= = =09 > [text] message =3D > [showif code..blah..code... > [/showif] > [/text] > [/loop] > [/showif] =20 > code..blah..code... > [/founditems] > [/search] >=20 > [sendmail to=3Dtimeclock@domain.com&from=3DWebpage@ = domain.com&subject=3DStaff Over 40 message (no = reply)&content-type=3Dtext/html] > [message] > [/sendmail] Stephen, I also have sent mail using [sendmail] countless times inside a = [search][founditems]... But anyway, as far as the above code (latter example) only sending one = email.. well that makes perfect sense (looking at the code you wrote). = If you want 3 emails to go out, you have to write out 3 [sendmail]'s = ...or put the [sendmail] inside a loop that will fire 3 times (like = inside [founditems] ;-) .. or inside [loop], or inside [listwords], or = inside whatever other loop serves you best. If you do not want to debug = why [sendmail] was failing inside [founditems] on your first attempt, = then you could rewrite your latter attempt, like so: [search db=3D../login/website_users.db& code..blah..code...] [founditems]  =20 code..blah..code... [showif code..blah..code... [loop start=3D[code..blah..code...] [text]message_[index] =3D [showif = code..blah..code...[/showif] [/text] = [text]NumTimesLoopFired=3D[index][/text][!]<--- 1.) this might go here, = or else below---[/!] [/loop] [/showif] =20 code..blah..code... [text]NumTimesLoopFired=3D[index][/text][!]<--- 2.) this = might go here, or else above---[/!] [/founditems] [/search] [loop start=3D1&end=3D[NumTimesLoopFired]&advance=3D1] [sendmail to=3Dtimeclock@domain.com&from=3DWebpage@ = domain.com&subject=3DStaff Over 40 message (no = reply)&content-type=3Dtext/html] [interpret][message_[index]][/interpret] [/sendmail] [/loop] Associated Messages, from the most recent to the oldest:

    
  1. Re: [WebDNA] multi [sendmail] inside [search] (WebDNA Solutions 2012)
  2. Re: [WebDNA] multi [sendmail] inside [search] ("Terry Wilson" 2012)
  3. Re: [WebDNA] multi [sendmail] inside [search] (Stephen Braun 2012)
  4. Re: [WebDNA] multi [sendmail] inside [search] (William DeVaul 2012)
  5. Re: [WebDNA] multi [sendmail] inside [search] ("Terry Wilson" 2012)
  6. Re: [WebDNA] multi [sendmail] inside [search] (Govinda 2012)
  7. Re: [WebDNA] multi [sendmail] inside [search] (Stephen Braun 2012)
  8. Re: [WebDNA] multi [sendmail] inside [search] (Terry Wilson 2012)
  9. Re: [WebDNA] multi [sendmail] inside [search] (Stephen Braun 2012)
  10. Re: [WebDNA] multi [sendmail] inside [search] (WebDNA Solutions 2012)
  11. Re: [WebDNA] multi [sendmail] inside [search] (Stuart Tremain 2012)
  12. Re: [WebDNA] multi [sendmail] inside [search] (Stuart Tremain 2012)
  13. Re: [WebDNA] multi [sendmail] inside [search] (Govinda 2012)
  14. Re: [WebDNA] multi [sendmail] inside [search] (Terry Wilson 2012)
  15. Re: [WebDNA] multi [sendmail] inside [search] (Stephen Braun 2012)
  16. Re: [WebDNA] multi [sendmail] inside [search] (Stephen Braun 2012)
  17. RE: [WebDNA] multi [sendmail] inside [search] ("Michael A. DeLorenzo" 2012)
  18. Re: [WebDNA] multi [sendmail] inside [search] (Govinda 2012)
  19. Re: [WebDNA] multi [sendmail] inside [search] (WebDNA Solutions 2012)
  20. Re: [WebDNA] multi [sendmail] inside [search] (Tom Duke 2012)
  21. Re: [WebDNA] multi [sendmail] inside [search] (Stephen Braun 2012)
  22. Re: [WebDNA] multi [sendmail] inside [search] (WebDNA Solutions 2012)
  23. [WebDNA] multi [sendmail] inside [search] (Stephen Braun 2012)
>=20 >>> The problem is, WebDNA doesn't like using a [sendmail] >>> tag inside of a [search...][founditems] routine. >>=20 >> Of course it does, I've been doing this for years. What=20 >> seems to be the problem that causes you to say this? >=20 >=20 > The simple problem is that it won't work... > Here's a sample.... >=20 > [search db=3D../login/website_users.db& code..blah..code...] > [founditems]  =20 > code..blah..code... > [showif code..blah..code... > [loop start=3D[ code..blah..code...]= = =09 > [text] message =3D > [showif code..blah..code... > [/showif] > [/text] > [/loop] > [/showif] =20 >  [sendmail = to=3Dtimeclock@domain.com&from=3DWebpage@domain.com&subject=3DStaff Over = 40 message (no reply)&content-type=3Dtext/html] > [message] > [/sendmail] > code..blah..code... > [/founditems] > [/search] >=20 > But this does work, but with only the last item found.... >=20 > [search db=3D../login/website_users.db& code..blah..code...] > [founditems]  =20 > code..blah..code... > [showif code..blah..code... > [loop start=3D[ code..blah..code...]= = =09 > [text] message =3D > [showif code..blah..code... > [/showif] > [/text] > [/loop] > [/showif] =20 > code..blah..code... > [/founditems] > [/search] >=20 > [sendmail to=3Dtimeclock@domain.com&from=3DWebpage@ = domain.com&subject=3DStaff Over 40 message (no = reply)&content-type=3Dtext/html] > [message] > [/sendmail] Stephen, I also have sent mail using [sendmail] countless times inside a = [search][founditems]... But anyway, as far as the above code (latter example) only sending one = email.. well that makes perfect sense (looking at the code you wrote). = If you want 3 emails to go out, you have to write out 3 [sendmail]'s = ...or put the [sendmail] inside a loop that will fire 3 times (like = inside [founditems] ;-) .. or inside [loop], or inside [listwords], or = inside whatever other loop serves you best. If you do not want to debug = why [sendmail] was failing inside [founditems] on your first attempt, = then you could rewrite your latter attempt, like so: [search db=3D../login/website_users.db& code..blah..code...] [founditems]  =20 code..blah..code... [showif code..blah..code... [loop start=3D[code..blah..code...] [text]message_[index] =3D [showif = code..blah..code...[/showif] [/text] = [text]NumTimesLoopFired=3D[index][/text][!]<--- 1.) this might go here, = or else below---[/!] [/loop] [/showif] =20 code..blah..code... [text]NumTimesLoopFired=3D[index][/text][!]<--- 2.) this = might go here, or else above---[/!] [/founditems] [/search] [loop start=3D1&end=3D[NumTimesLoopFired]&advance=3D1] [sendmail to=3Dtimeclock@domain.com&from=3DWebpage@ = domain.com&subject=3DStaff Over 40 message (no = reply)&content-type=3Dtext/html] [interpret][message_[index]][/interpret] [/sendmail] [/loop] Govinda

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:

Multiple catalog databases and showcart (1997) Summing fields (1997) Anybody running directory indexer? (1998) WebCatalog2 Feature Feedback (1996) Cumulative Shipping charge calculations - your help please. (1997) Multiple catalog databases and showcart (1997) [HIDEIF] inside [FOUNDITEM] (1997) Me know logical no need (2002) createfolder not behaving as expected (1999) off-topic - printinglib 68K (1997) Using Applescript to process WebCatalog functions (1998) Dummy Credit Card Number for debug? (1997) Db design question (relational vs. flat?) (1998) Associative lookup style? (1997) weird happenings (1997) Problems appending to database (1997) Location of Webcat site in folder hierarchy (1997) Cannot calculate prices (1997) [WebDNA] mod_fastcgi vs. mod_fcgi (2011) [ConvertChars] problem (1997)