亚洲av成人无遮挡网站在线观看,少妇性bbb搡bbb爽爽爽,亚洲av日韩精品久久久久久,兔费看少妇性l交大片免费,无码少妇一区二区三区

  免費注冊 查看新帖 |

Chinaunix

  平臺 論壇 博客 文庫
最近訪問板塊 發(fā)新帖
查看: 1515 | 回復: 0
打印 上一主題 下一主題

setlocale() [復制鏈接]

論壇徽章:
0
跳轉(zhuǎn)到指定樓層
1 [收藏(0)] [報告]
發(fā)表于 2009-09-16 20:07 |只看該作者 |倒序瀏覽
Definition and Usage
定義和用法
The setlocale() function sets locale information.
setlocale()函數(shù)的作用是:設(shè)置場景信息。
Locale information is language, monetary, time and other information specific for a geographical area.
本地信息可以是指定的某個區(qū)域的語言、貨幣、時間以及其它的信息。
This function returns the current locale settings, or FALSE on failure.
如果這個函數(shù)成功執(zhí)行,將返回當前的場景屬性;如果執(zhí)行失敗,將返回False。
Syntax
語法
setlocale(constant,location)

Parameter參數(shù)
Description描述
constant
Required. Specifies what locale information should be set.
必要參數(shù)。指定需要設(shè)置的場景信息
Available constants:
可用的常量:

  • LC_ALL - All of the below
    LC_ALL – 所有下屬的常量
  • LC_COLLATE -  Sort order
    LC_COLLATE – 排列順序
  • LC_CTYPE - Character classification and conversion (e.g. all characters should be lower or upper-case)
    LC_CTYPE – 字符分類和轉(zhuǎn)換(例如:將所有的字符轉(zhuǎn)換成小寫或大寫形式)
  • LC_MESSAGES - System message formatting
    LC_MESSAGES – 系統(tǒng)信息格式
  • LC_MONETARY - Monetary/currency formatting
    LC_MONETARY – 貨幣 / 通貨格式
  • LC_NUMERIC - Numeric formatting
    LC_NUMERIC – 數(shù)值格式
  • LC_TIME - Date and time formatting
    LC_TIME – 日期和時間格式

location
Required. Specifies what country/region to set the locale information to. Can be a string or an array. If the location is an array, setlocale() will try each array element until it finds a valid language or region code. This is very useful if a region is known under different names on different systems.
必要參數(shù)。指定需要進行場景信息設(shè)置的國家或區(qū)域。它可以由一個字符串或一個數(shù)組組成。如果本地區(qū)域是一個數(shù)組,那么setlocale()函數(shù)將嘗試每 個數(shù)組元素直到它從中獲取有效的語言和區(qū)域代碼信息為止。如果一個區(qū)域處于不同操作系統(tǒng)中的不同名稱下,那么這個參數(shù)將非常有用。
Note: Here you can find
language and region codes
.
注意:你可以通過下面一個地址查詢:語言信息和區(qū)域代碼

Tips and Notes
提示和注意點
Note: The setlocale() function changes the locale only for the current script.
注意:setlocale()函數(shù)僅改變當前腳本程序中的場景。
Tip: The locale information can be set to system default with setlocale(LC_ALL,NULL)
提示:可以使用setlocale(LC_ALL,NULL)函數(shù)將場景信息設(shè)置為系統(tǒng)默認值。
Example
案例
In this example we will set the locale to US English and then back to default again:
在下面這個案例中,我們把場景設(shè)置成美國英語[US English]之后,再將轉(zhuǎn)會默認的場景信息:
The output of the code above will be:
上述代碼將輸出下面的結(jié)果:
English_United States.1252
Norwegian (Bokmål)_Norway.1252



本文來自ChinaUnix博客,如果查看原文請點:http://blog.chinaunix.net/u3/93660/showart_2054018.html
您需要登錄后才可以回帖 登錄 | 注冊

本版積分規(guī)則 發(fā)表回復

  

北京盛拓優(yōu)訊信息技術(shù)有限公司. 版權(quán)所有 京ICP備16024965號-6 北京市公安局海淀分局網(wǎng)監(jiān)中心備案編號:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年舉報專區(qū)
中國互聯(lián)網(wǎng)協(xié)會會員  聯(lián)系我們:huangweiwei@itpub.net
感謝所有關(guān)心和支持過ChinaUnix的朋友們 轉(zhuǎn)載本站內(nèi)容請注明原作者名及出處

清除 Cookies - ChinaUnix - Archiver - WAP - TOP