Since JavaScript can be used in many environments, it is possible that in a server-side application you will have access to the command line arguments.
If that is the case, then it is likely that you will have an argc property, which indicates how many arguments have been passed.
In general, the first argument is the name of the script or program being executed. The argc value should never be zero and as a minimum should indicate that there is at least one argument.
The actual values of the arguments are collected in an array called argv. You should be able to access argv and argc in a similar manner.
Prev | Home | Next |
areas[] | Up | Argument |
JavaScript Programmer's Reference, Cliff Wootton Wrox Press (www.wrox.com) Join the Wrox JavaScript forum at p2p.wrox.com Please report problems to support@wrox.com © 2001 Wrox Press. All Rights Reserved. Terms and conditions. |