Yes, but there is no need to transform handlers (commands) into
functions. You can have handlers in .irev too, so long as they are
defined before they are used.
-- Alex.
On 16/11/2010 17:17, paolo mazza wrote:
Thank you Devin,
that's interesting.
So, if I move all the functions and all the commands (transformed in
functions) of my script before the main command the script of my stack
should work also in the on-rev server.
I will give it a try.
Thanks a lot
Paolo
On Tue, Nov 16, 2010 at 5:59 PM, Devin Asay<devin_a...@byu.edu> wrote:
On Nov 16, 2010, at 9:40 AM, paolo mazza wrote:
How can I place a function in a on-rev - CGI server script ?
I have to port a stack script (with commands and functions) to a .irev
text
file for the on-rev server .
I expected something similar to the following script...
<?rev
put MyFunction() into tVAR1
put tVAR1
function MyFunction
put 1 + 1 into VAR2
return VAR2
end MyFunction
?>
... but obviously it does not work !!!
Any idea?
Paolo,
In irev scripts you have to declare the function before you call it, so
just put the function handler at the top:
<?rev
function MyFunction
put 1 + 1 into VAR2
return VAR2
end MyFunction
put MyFunction() into tVAR1
put tVAR1
?>
Regards,
Devin
Devin Asay
Humanities Technology and Research Support Center
Brigham Young University
_______________________________________________
use-revolution mailing list
use-revolution@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your
subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-revolution
_______________________________________________
use-revolution mailing list
use-revolution@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-revolution
_______________________________________________
use-revolution mailing list
use-revolution@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-revolution