c_SetOptionInt(string strDomain,int nKey,int nValue)
Parameters
[1]string the domain name
[2]int the key of domain option
[3]int the integer value of domain option
Return Values
nil
Remarks
Set the integer value of a domain option.
for example:
c_SetOptionInt("domain", DOPTION_DATA_ACCESS_INTERFACE_INT, 1)
DOPTION_DATA_ACCESS_INTERFACE_INT is a macro definition of domain options, you can check them at the bottom.
c_SetOptionStr(string strDomain,int nKey,string strValue)
Parameters
[1]string the domain name
[2]int the key of domain option
[3]string the string value of domain option
Return Values
nil
Remarks
This function is similar to c_SetOptionInt(), it is used for setting the string value of a domain option.
c_GetOptionInt(string strDomain,int nKey)
Parameters
[1]string the domain name
[2]int the key of domain option
Return Values
[1]int the integer value of domain option
Remarks
Get the integer value of a domain option.
for example:
local interface = c_GetOptionInt("domain", DOPTION_DATA_ACCESS_INTERFACE_INT)
c_GetOptionStr(string strDomain,int nKey)
Parameters
[1]string the domain name
[2]int the key of domain option
Return Values
[1]string the string value of domain option
Remarks
Get the string value of a domain option.
c_SetGlobalOptionInt(int nKey,int nValue)
Parameters
[1]int the key of global option
[2]int the integer value of global option
Return Values
nil
Remarks
Set the integer value of a global option.
for example:
c_SetGlobalOptionInt(GOPTION_SYSTEM_LOGFILE_ENABLE_INT, 1)
GOPTION_SYSTEM_LOGFILE_ENABLE_INT is a macro defination of global options, you can check them on the bottom..
c_SetGlobalOptionStr(int nKey,string strValue)
Parameters
[1]int the key of global option
[2]string the string value of global option
Return Values
nil
Remarks
This function is similar to c_SetGlobalOptionInt(), it is used for setting the string value of a global option.
c_GetGlobalOptionInt(int nKey)
Parameters
[1]int the key of global option
Return Values
[1]int the integer value of global option
Remarks
Get the integer value of a global option.
for example:
local enable_systemlog = c_GetGlobalOptionInt(GOPTION_SYSTEM_LOGFILE_ENABLE_INT)
c_GetGlobalOptionStr(int nKey)
Parameters
[1]int the key of global option
Return Values
[1]string the string value of global option
Remarks
Get the string value of a global option.
c_SetAdminOptionInt(int nKey,int nValue)
Parameters
[1]int the key of admin option
[2]int the integer value of admin option
Return Values
nil
Remarks
Set the integer value of admin option.
for example:
c_SetAdminOptionInt(ADMIN_OPTION_LOGFILE_ENABLE_INT, 1)
ADMIN_OPTION_LOGFILE_ENABLE_INT is a macro defination of admin options, you can check them on the bottom..
c_SetAdminOptionStr(int nKey,string strValue)
Parameters
[1]int the key of admin option
[2]string the string value of admin option
Return Values
nil
Remarks
This function is similar to c_SetAdminOptionInt(), it is used for setting the string value of an admin option.
c_GetAdminOptionInt(int nKey)
Parameters
[1]int the key of admin option
Return Values
[1]int the integer value of admin option
Remarks
Get the integer value of an admin option.
for example:
local enable_adminlog = c_GetAdminOptionInt(ADMIN_OPTION_LOGFILE_ENABLE_INT)
c_GetAdminOptionStr(int nKey)
Parameters
[1]int the key of admin option
Return Values
[1]string the string value of admin option
Remarks
Get the string value of an admin option.
//Domain Option Field(used in c_SetOptionInt,c_SetOptionStr,c_GetOptionInt,c_GetOptionStr)
DOPTION_DOMAIN_MAX_SESSION_INT = 0 //Maximum number of sessions on domain
DOPTION_DOMAIN_PER_IP_MAX_SESSION_INT = 1 //Maximum sessions per IP address on domain
DOPTION_PER_SESSION_MAX_DOWN_SPEED_INT = 2 //Maximum download speed per session
DOPTION_PER_SESSION_MAX_UP_SPEED_INT = 3 //Maximum upload speed per session
DOPTION_DOMAIN_MAX_DOWN_SPEED_INT = 4 //Maximum download speed for domain
DOPTION_DOMAIN_MAX_UP_SPEED_INT = 5 //Maximum upload speed for domain
DOPTION_PER_USER_MAX_DOWN_SPEED_INT = 6 //Maximum download speed for user accounts
DOPTION_PER_USER_MAX_UP_SPEED_INT = 7 //Maximum upload speed for user accounts
DOPTION_PASSTYPE_INT = 8 //FTP Pasv Mode
DOPTION_PASV_IP_REFRESH_INTERVAL_INT = 9 //Update IP address interval for FTP Pasv Mode
DOPTION_FIXEDIP_STR = 10 //Fixed IP for FTP Pasv Mode
DOPTION_WEB_IP_STR = 11 //Web IP for FTP Pasv Mode
DOPTION_DNS_IP_STR = 12 //Dynamic DNS for FTP Pasv Mode
DOPTION_ENABLE_UPNP = 13 //Auto-forwarding domain listener ports to router
DOPTION_PASSPORTMIN_INT = 14 //FTP passive minimum port
DOPTION_PASSPORTMAX_INT = 15 //FTP passive maximum port
DOPTION_BUFFERSIZE_INT = 16 //Transfer buffer size
DOPTION_DATA_ACCESS_INTERFACE_INT = 17 //Storage user/group data way
DOPTION_MYSQL_ADDRESS_STR = 18 //Mysql Server
DOPTION_MYSQL_PORT_INT = 19 //Mysql Server Port
DOPTION_MYSQL_USERNAME_STR = 20 //Mysql Username
DOPTION_MYSQL_PASSWORD_STR = 21 //Mysql Password
DOPTION_MYSQL_DBNAME_STR = 22 //Mysql Database
DOPTION_MYSQL_UNIXSOCKET_STR = 23 //Mysql UnixSocket
DOPTION_DSN_ADDRESS_STR = 24 //ODBC Source
DOPTION_DSN_USERNAME_STR = 25 //ODBC Username
DOPTION_DSN_PASSWORD_STR = 26 //ODBC Password
DOPTION_ENABLE_MODEZ_INT = 27 //Enable FTP MODE Z support
DOPTION_DEFAULT_ZLEVEL_INT = 28 //Defualt compression level
DOPTION_MIN_ZLEVEL_INT = 29 //Minimum allowed compression level
DOPTION_MAX_ZLEVEL_INT = 30 //Maximum allowed compression level
DOPTION_ENABLE_SFVCHECK_INT = 31 //Enable SFV Check
DOPTION_SFVCHECK_CREATMISSING_INT = 32 //SFV create missing files(filename.missing)
DOPTION_SFVCHECK_BADFILE_INT = 33 //SFV Bad File Option
DOPTION_SFVCHECK_PROGRESS_INT = 34 //SFV Check Progress Option
DOPTION_SFVCHECK_SENDRESULT_INT = 35 //SFV send the check result to client(only for FTP)
DOPTION_ANTI_HAMMER_ENABLE_INT = 36 //Enable Anti-hammer
DOPTION_ANTI_HAMMER_BLOCK_TIME_INT = 37 //Anti-hammer blocking time
DOPTION_ANTI_HAMMER_LOGIN_FAILED_COUNTS_INT = 38 //Anti-hammer failed login try
DOPTION_ANTI_HAMMER_INTERVAL_INT = 39 //Anti-hammer failed try time
DOPTION_ANTI_HAMMER_SEND_MESSAGE_INT = 40 //Send hammering message to ftp client
DOPTION_SSL_NAME_STR = 41 //SSL certificate name
DOPTION_SSH_NAME_STR = 42 //SSH key name
DOPTION_SSH_USE_UTF8 = 43 //Using UTF-8 for SSH
DOPTION_SMTP_NAME_STR = 44 //SMTP config name
DOPTION_ENABLE_FXP_INT = 45 //Enable FXP
DOPTION_LOGFILE_ENABLE_INT = 46 //Enable domain log
DOPTION_LOGFILE_NAME_STR = 47 //Domain log's filename
DOPTION_LOGFILE_MAXSIZE_INT = 48 //Domain log's max size
DOPTION_LOGFILE_MESSAGE_INT = 49 //Log text field 'Message' enabled in file
DOPTION_LOGSCREEN_MESSAGE_INT = 50 //Log text field 'Message' enabled in screen
DOPTION_LOGFILE_SECURITY_INT = 51 //Log text field 'Security' enabled in file
DOPTION_LOGSCREEN_SECURITY_INT = 52 //Log text field 'Security' enabled in screen
DOPTION_LOGFILE_FTP_COMMAND_INT = 53 //Log text field 'FTP Command' enabled in file
DOPTION_LOGSCREEN_FTP_COMMAND_INT = 54 //Log text field 'FTP Command' enabled in screen
DOPTION_LOGFILE_FTP_RESPONSE_INT = 55 //Log text field 'FTP Response' enabled in file
DOPTION_LOGSCREEN_FTP_RESPONSE_INT = 56 //Log text field 'FTP Response' enabled in screen
DOPTION_LOGFILE_WEB_COMMAND_INT = 57 //Log text field 'WEB Command' enabled in file
DOPTION_LOGSCREEN_WEB_COMMAND_INT = 58 //Log text field 'WEB Command' enabled in screen
DOPTION_LOGFILE_WEB_RESPONSE_INT = 59 //Log text field 'WEB Response' enabled in file
DOPTION_LOGSCREEN_WEB_RESPONSE_INT = 60 //Log text field 'WEB Response' enabled in screen
DOPTION_LOGFILE_SSH_COMMAND_INT = 61 //Log text field 'SSH Command' enabled in file
DOPTION_LOGSCREEN_SSH_COMMAND_INT = 62 //Log text field 'SSH Command' enabled in screen
DOPTION_LOGFILE_SSH_RESPONSE_INT = 63 //Log text field 'SSH Response' enabled in file
DOPTION_LOGSCREEN_SSH_RESPONSE_INT = 64 //Log text field 'SSH Response' enabled in screen
DOPTION_LOGFILE_ODBC_ERROR_INT = 65 //Log text field 'ODBC Error' enabled in file
DOPTION_LOGSCREEN_ODBC_ERROR_INT = 66 //Log text field 'ODBC Error' enabled in screen
DOPTION_LOGFILE_MYSQL_ERROR_INT = 67 //Log text field 'MYSQL Error' enabled in file
DOPTION_LOGSCREEN_MYSQL_ERROR_INT = 68 //Log text field 'MYSQL Error' enabled in screen
DOPTION_LOGFILE_LUA_ERROR_INT = 69 //Log text field 'Lua Error' enabled in file
DOPTION_LOGSCREEN_LUA_ERROR_INT = 70 //Log text field 'Lua Error' enabled in screen
DOPTION_LOGFILE_MAIL_ERROR_INT = 71 //Log text field 'Mail Error' enabled in file
DOPTION_LOGSCREEN_MAIL_ERROR_INT = 72 //Log text field 'Mail Error' enabled in screen
DOPTION_LOGFILE_FILE_ERROR_INT = 73 //Log text field 'File Error' enabled in file
DOPTION_LOGSCREEN_FILE_ERROR_INT = 74 //Log text field 'File Error' enabled in screen
DOPTION_LOGFILE_NORMAL_ERROR_INT = 75 //Log text field 'Normal Error' enabled in file
DOPTION_LOGSCREEN_NORMAL_ERROR_INT = 76 //Log text field 'Normal Error' enabled in screen
DOPTION_MESSAGE_WELCOME_STR = 77 //FTP welcome message
DOPTION_MESSAGE_LOGIN_STR = 78 //FTP user login message
DOPTION_MESSAGE_CHANGE_DIR_STR = 79 //FTP change directory message
DOPTION_MESSAGE_DIR_LIST_STR = 80 //FTP directory list message
DOPTION_MESSAGE_FILE_UPLOAD_STR = 81 //FTP file uploaded message
DOPTION_MESSAGE_FILE_DOWNLOAD_STR = 82 //FTP file downloaded message
DOPTION_MESSAGE_SYSTEM_COMMAND_STR = 83 //FTP system command message
DOPTION_MESSAGE_QUIT_COMMAND_STR = 84 //FTP user quit message
DOPTION_LISTENER_ENABLE_UPNP_INT = 85 //Auto-forwarding domain listener ports to router
DOPTION_PER_ACCOUNT_MAX_SESSIONS_INT = 86 //Maximum number of sessions per user account
DOPTION_PER_ACCOUNT_PER_IP_MAX_SESSIONS_INT = 87 //Maximum sessions per IP address for user account
DOPTION_COMMAND_TIMEOUT_INT = 88 //Automatic idle connection timeout
DOPTION_TRANSFER_TIMEOUT_INT = 89 //Automatic transfer connection timeout