Identifier Variables Identifier variables are used most often with commands such as IF...THEN , MAP , and WRITE . They allow you to create one login script for multiple users by replacing the variable with other text or information. You need to make sure you type the variable exactly as shown. Identifier variables can be placed within literal text strings in a WRITE statement. Literal text must be enclosed in quotation marks and the identifier must be preceded by a percent sign ( % ). For example, using the %LAST_NAME variable, substitutes the user 's actual last name for the LAST_NAME variable. In a login script, WRITE "HELLO, "%LAST_NAME displays a Hello, JONES message on Mary Jones' workstation screen when she logs in. Tables B.1 through B.6 contain the identifier variables that can be used in NetWare 6 login scripts. Table B.1. Date Variables IDENTIFIER VARIABLE | FUNCTION | DAY | Day in number format (01 through 31) | DAY_OF_WEEK | Day of the week (Monday, Tuesday, and so on) | MONTH | Month number (01 through 12) | MONTH_NAME | Month name (January, February, and so on) | NDAY_OF_WEEK | Weekday in number format (1 through 7; 1=Sunday) | SHORT_YEAR | Last two digits of the year (99, 00, 01) | YEAR | All four digits of the year (1999, 2000, 2001) | Table B.2. Time Variables IDENTIFIER VARIABLE | FUNCTION | AM_PM | Day or night (a.m. or p.m.) | GREETING_TIME | Time of day (morning, afternoon, evening) | HOUR | Hour (12-hour scale; 1 through 12) | HOUR24 | Hour (24-hour scale; 00 through 23) | MINUTE | Minute (00 through 59) | SECOND | Second (00 through 59) | Table B.3. User Variables IDENTIFIER VARIABLE | FUNCTION | CN | User's full login name as it exists in eDirectory. | FULL_NAME | User's unique username. It is the value of the FULL_NAME property for eDirectory. | LAST_NAME | User's surname in eDirectory. | LOGIN_CONTEXT | User's context. | LOGIN_NAME | User's unique login name (long names are truncated to eight characters ). | MEMBER OF " group " | Group object to which the user is assigned. | NOT MEMBER OF "group" | Group object to which the user is not assigned. | PASSWORD_EXPIRES | Number of days before password expires . | REQUESTER_CONTEXT | Context when login started. | USER_ID | Number assigned to each user. | Table B.4. Network Variables IDENTIFIER VARIABLE | FUNCTION | FILE_SERVER | NetWare server name | NETWORK_ADDRESS | The internal number assigned by the network specifying where a device can be located in the network cabling system | Table B.5. Workstation Variables IDENTIFIER VARIABLE | FUNCTION | MACHINE | Type of computer (IBM_PC, and so on) | OS | Type of operating system on the workstation | OS_VERSION | Operating system version on the workstation | P_STATION | Workstation's node number (12-digit hexadecimal) | PLATFORM | Workstation's operating system platform | SMACHINE | Short machine name (IBM, and so on) | STATION | Workstation's connection number | WINVER | Version of the workstation's Windows operating system | Table B.6. Miscellaneous Variables IDENTIFIER VARIABLE | FUNCTION | ACCESS_SERVER | Shows whether the access server is functional ( TRUE = functional; FALSE = nonfunctional). | ERROR_LEVEL | An error number (0 = no errors). | %n | Replaced by parameters used during login. When a user logs in, additional parameters can be entered that the login utility passes to the login script. The login utility then substitutes these parameters for any %n variables in the login script. These variables are replaced in order by the parameters the user entered when logging in. Users can change only four variables ( %2 to %5 ) in the login screen. The %0 variable is replaced by the name of the NetWare server entered in the login dialog box, and %1 is replaced by the user's fully distinguished login name. The remaining variables change, depending on what the user types when executing the login utility. The %n variables must precede all command-line options. | property name | You can use property values of eDirectory objects as variables. Use the property values just as you do any other identifier variable. If the property value includes a space, enclose the name in quotation marks. To use a property name with a space within a WRITE statement, you must place it at the end of the quoted string. | |