The server waits until the file appears on disk
numero = 190WaitForFile will wait a specified number of seconds (default 30) until the file appears. The template will not finish executing and the HTML will not be returned to the visiting browser until the WaitForFile finishes.
Example[waitforfile file=ICVer001.ans]Some WebDNA to parse the ICVerify answer file format and do something important with it[/WaitForFile]You can write WebDNA that learns if the WaitForFile timed out:
[text]succeeded=F[/text][waitforfile file=FileToWaitFor.txt]Some WebDNA to execute if the file is found[text]succeeded=T[/text][/waitforfile][showif [succeeded]=T] File was found! [/showif][showif [succeeded]=F] File was not found! [/showif]The value of [succeeded] becomes either T or F, depending on whether or not the [waitforfile] succeeded in finding the file on disk before the timeout expired.
Parameter | Description |
---|---|
file | |
timeout | (Optional) Number of seconds to wait before cancelling the operation. No WebDNA inside the [WaitForFile] context will be executed. Defaults to 30 seconds if not specified. |
WaitForFile will wait a specified number of seconds (default 30) until the file appears. The template will not finish executing and the HTML will not be returned to the visiting browser until the WaitForFile finishes.
[waitforfile file=ICVer001.ans]
Some WebDNA to parse the ICVerify answer file format and do something important with it
[/WaitForFile]
[text]succeeded=F[/text]
[waitforfile file=FileToWaitFor.txt]
Some WebDNA to execute if the file is found
[text]succeeded=T[/text]
[/waitforfile]
[showif [succeeded]=T] File was found! [/showif]
[showif [succeeded]=F] File was not found! [/showif]
Parameter | Description |
---|---|
file | |
timeout | (Optional) Number of seconds to wait before cancelling the operation. No WebDNA inside the [waitforfile] context will be executed. Defaults to 30 seconds if not specified. |
DOWNLOAD WEBDNA NOW!
Amazon Web Services (AWS) README for Machine Image ID...
Tips and TricksA list of user-submitted tips ...
Download WebDNA ApplicationsWebDNA applications...
WebDNA ModulesA list of the currently available modules...
F.A.QA compilation of some user's questions...
Technical Change HistoryThis Technical Change History provides a reverse chronological list of WebDNA changes...
[encrypt] and [decrypt] allow you to store sensitive data in your databases without risk of exposing it to prying eyes...
[renamefolder]Rename a folder in your webspace...
[writefile][writefile] functions allows you to perform a wide variety of tasks...
[SQLrelease]...
[convertwords]Changes specified words in a string of text to different words...
[url][url]...