Re: Trigger action Quandry

This WebDNA talk-list message is from

2002


It keeps the original formatting.
numero = 40483
interpreted = N
texte = Whenever I have problems with triggers (or spawns) I put in code to write info out to a debugging log. In this case, I'd add something like:[appendfile file=debug.txt&secure=F][date] [time] [thisurl] (showif [hour]\2) [/appendfile]... right before the [showif... Then I could examine the log to see what's up.- brianAt 10:56 AM 6/6/02, Bob Minor wrote: >I have a page that when hit by a human browser it works fine, but if its hit >with a trigger it doesn't. Specifically I run the script every hour, if the >hour is divisible by 2 then it runs the containing code if not then it >should not. Instead it runs every hour regartless. Here is the code from the >page. > >Database Backup > > [math show=f]filecount=0[/math] > [text secure=F]dayfolder=[date %a][/text] > [math show=f]hour=[date %H][/math] > >[showif [hour]\2] > >[ListFiles path=../databases/] >[hideif [filename]^(] >[showif [filename]^.db] > >[filename]
>[math show=T]filecount=filecount+1[/math] >[text secure=F&show=T]backupfile[filecount]=[filename][/text] >[hideif [filename]^archives][commitdatabase >../databases/[filename]][/hideif] > > >[/showif] >[/hideif] >[/Listfiles] > > >[dos] >cd ..\..\..\Medlawplus.com\wwwroot\databases\ >mkdir D:\backup\[dayfolder]\[date %H] >mkdir D:\backup\[dayfolder]\[date %H]\[Date %y-%m-%d] >[loop start=1&end=[filecount]]copy >[interpret][backupfile[index]][/interpret] D:\backup\[dayfolder]\[date >%H]\[interpret][backupfile[index]][/interpret] >[/loop] >[/dos] > >[appendfile action.log][date] [time] [date %H] >[math]{[date]}[/math].[math]{[time]}[/math] backup databases[loop >start=1&end=[filecount]] > copy [interpret][backupfile[index]][/interpret] >D:\backup\[dayfolder]\[date >%H]\[interpret][backupfile[index]][/interpret][/loop] >[/appendfile] > >[/showif] > > >Robert Minor >Director of Internet Services >------------------------------------------------------------ >Cybermill Communications >http://www.cybermill.com http://www.merchantmaker.com > >Providing Ecommerce and interactive website development and >hosting services on Macintosh, Windows NT, Unix, and AS/400. > >All your websites are belong to us! > > >------------------------------------------------------------- >This message is sent to you because you are subscribed to > the mailing list . >To unsubscribe, E-mail to: >To switch to the DIGEST mode, E-mail to > >Web Archive of this list is at: http://search.smithmicro.com/ ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://search.smithmicro.com/ Associated Messages, from the most recent to the oldest:

    
  1. Re: Trigger action Quandry (Brian Fries 2002)
  2. Trigger action Quandry (Bob Minor 2002)
Whenever I have problems with triggers (or spawns) I put in code to write info out to a debugging log. In this case, I'd add something like:[appendfile file=debug.txt&secure=F][date] [time] [thisurl] (showif [hour]\2) [/appendfile]... right before the [showif... Then I could examine the log to see what's up.- brianAt 10:56 AM 6/6/02, Bob Minor wrote: >I have a page that when hit by a human browser it works fine, but if its hit >with a trigger it doesn't. Specifically I run the script every hour, if the >hour is divisible by 2 then it runs the containing code if not then it >should not. Instead it runs every hour regartless. Here is the code from the >page. > >Database backup > > [math show=f]filecount=0[/math] > [text secure=F]dayfolder=[date %a][/text] > [math show=f]hour=[date %H][/math] > >[showif [hour]\2] > >[ListFiles path=../databases/] >[hideif [filename]^(] >[showif [filename]^.db] > >[filename]
>[math show=T]filecount=filecount+1[/math] >[text secure=F&show=T]backupfile[filecount]=[filename][/text] >[hideif [filename]^archives][commitdatabase >../databases/[filename]][/hideif] > > >[/showif] >[/hideif] >[/Listfiles] > > >[DOS] >cd ..\..\..\Medlawplus.com\wwwroot\databases\ >mkdir D:\backup\[dayfolder]\[date %H] >mkdir D:\backup\[dayfolder]\[date %H]\[Date %y-%m-%d] >[loop start=1&end=[filecount]]copy >[interpret][backupfile[index]][/interpret] D:\backup\[dayfolder]\[date >%H]\[interpret][backupfile[index]][/interpret] >[/loop] >[/dos] > >[appendfile action.log][date] [time] [date %H] >[math]{[date]}[/math].[math]{[time]}[/math] backup databases[loop >start=1&end=[filecount]] > copy [interpret][backupfile[index]][/interpret] >D:\backup\[dayfolder]\[date >%H]\[interpret][backupfile[index]][/interpret][/loop] >[/appendfile] > >[/showif] > > >Robert Minor >Director of Internet Services >------------------------------------------------------------ >Cybermill Communications >http://www.cybermill.com http://www.merchantmaker.com > >Providing Ecommerce and interactive website development and >hosting services on Macintosh, Windows NT, Unix, and AS/400. > >All your websites are belong to us! > > >------------------------------------------------------------- >This message is sent to you because you are subscribed to > the mailing list . >To unsubscribe, E-mail to: >To switch to the DIGEST mode, E-mail to > >Web Archive of this list is at: http://search.smithmicro.com/ ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://search.smithmicro.com/ Brian Fries

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:

[WebDNA] maybe silly suggestion? [founditems] (2015) Error Log.db --however (1997) Searching multiple fields from one form field (1997) Help name our technology! (1997) [Semi-OT] Eaaaaaasy OSX FTP (2003) Ok here is a question? (1997) 2nd WebCatalog2 Feature Request (1996) Webcat causing crashes left and right! (1997) [WebDNA] triggers.db "next execute" fails to update (2012) Server Freeze (1998) Re:Password Authentication - request example (1998) Search/sort in URL Was: GuestBook example (1997) Running _every_ page through WebCat ? (1997) [WebDNA] Silly question (2009) [WebDNA] Privat IP website behind a public IP website (2014) WebCatalog as a ListServ (1998) WebCatalog2 Feature Feedback (1996) WC Database Format (1997) file uploads with webcat...binary? (1998) Emailer [cart] file names (1997)