CN101957846B - Method and system for automatically setting page language by mobile terminal browser - Google Patents
Method and system for automatically setting page language by mobile terminal browser Download PDFInfo
- Publication number
- CN101957846B CN101957846B CN2010102864518A CN201010286451A CN101957846B CN 101957846 B CN101957846 B CN 101957846B CN 2010102864518 A CN2010102864518 A CN 2010102864518A CN 201010286451 A CN201010286451 A CN 201010286451A CN 101957846 B CN101957846 B CN 101957846B
- Authority
- CN
- China
- Prior art keywords
- language
- browser
- value
- page
- version
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Landscapes
- Information Transfer Between Computers (AREA)
Abstract
The invention provides a method for automatically setting a page language by a mobile terminal browser. The method comprises the following steps of: acquiring relevant information of a user by using the browser and neglecting the default language value of a mobile terminal; determining a precedence language value according to the relevant information of the user and a preset weight of the default language value of a browser edition and writing the precedence language value into a language request header so as to generate language request header data; and transmitting the language request header data to a webpage server and receiving page contents of a corresponding language edition. The invention also provides a system for automatically setting the page language by the mobile terminal browser. The system comprises an information acquisition unit, an information analysis unit, a request header reset unit and a data interaction unit. Through the implementation of the technical scheme of the invention, a mobile phone browser determines the precedence language value by acquiring the relevant information of the user so as to provide the webpage contents of a corresponding language edition for the user and meet the requirement of the user on the page language edition when a webpage is browsed.
Description
Technical field:
The present invention relates to the method and system that a kind of browser is provided with page language automatically, particularly a kind of browser of serving portable terminal is provided with the method and system of page language automatically.
Background technology:
Along with the fast development of Internet technology, many large-scale websites have been realized the internationalization technology of website one after another, promptly return the web site contents of corresponding language version according to the language message of client.Client browser is when server sends access request; The language message that is provided with in the browser is added in the request as request header (accept-language); Send to server in the lump; The language message of server identification request header is returned the web site contents of corresponding language version according to language message.
Above-mentioned technology is suitable equally in mobile phone browser.Yet the default language value of mobile phone browser is set by the developer often, can not as the PC browser, be set by user oneself.Thereby cell phone system also only can be judged the default language value of mobile phone browser and generate the accept-language value; Popular in the market mobile phone has part to have smuggled goods; The situation of correcting machine, this type mobile phone much all crack Chinesizing (great majority were English edition originally) by businessman's mobile phone software, yet but do not have Chinese information in the default language value of mobile phone browser; It still is English causing the accept-language in the request of sending, and can't return the Chinese page.In addition; What the mobile phone manufacturer of most domestic adopted all is the Mtk platform; There is not the uniform communication standard between each manufacturer; (part carries browser and need use the java function) can't be judged correct accept-language information fully after particularly using the java virtual machine, causes the page to return mistake.
At present; Can carry out the judgement of cell-phone language according to certain logic in the part mobile phone; But its Rule of judgment is single; Can't meet consumers' demand: its cell phone system only can carry out the accept-language value to the mobile phone default language to be judged, can't user's details be judged like region, web page browsing custom, speech habits etc.
Summary of the invention:
The objective of the invention is especially to serving the method and system that page language is set automatically of portable terminal, provides a kind of more perfect technical solution in order to overcome the shortcoming that existing browser is provided with the method and system of page language automatically.
The invention provides the method that a kind of browser of mobile terminal is provided with page language automatically, comprising:
Browser obtains user related information, ignores the default language value of portable terminal;
The weight that presets according to the default language value of said user related information and browser version is confirmed the precedence language value, said precedence language value is write in the language request head production language request header data;
A said language request data are sent to web page server, and receive the content of pages of corresponding language version.
Wherein, said user related information comprises: the GPS information data of the network operator information of portable terminal, portable terminal, IP database.
Wherein, the default language value of said browser version presets the weight maximum.
Wherein, said basis presets weight and confirms that the precedence language value further comprises: the pairing weight of each languages is calculated and compared, and the languages that weight proportion is maximum are confirmed as the precedence language value.
Wherein, after said browser sent to web page server with a said language request data, said server was discerned the language value in the said language request head, return with said language request head in the content of pages of identical language version.
The present invention also provides a kind of browser of mobile terminal that the system of page language is set automatically, comprising:
Information acquisition unit: be used for when the browser initialization, obtaining user related information;
Information analysis unit: ignore the default language value of portable terminal, and confirm the precedence language value according to the weight that presets of the default language value of said user related information and browser version;
Request header reset cell: said precedence language value is write in the language request head production language request header data;
Data interaction unit: be used for a said language request data are sent to web page server, and receive the content of pages of corresponding language version.
Wherein, said user related information comprises: the GPS information data of the network operator information of portable terminal, portable terminal, IP database.
Wherein, the default language value of said browser version presets the weight maximum.
Wherein, said basis presets weight and confirms that the precedence language value further comprises: the pairing weight of each languages is calculated and compared, and the languages that weight proportion is maximum are confirmed as the precedence language value.
Wherein, In said data interaction unit; After said browser sent to web page server with a language request data, said server was discerned the language value in the said language request head, return with said language request head in the content of pages of identical language version.
Through the technical scheme of embodiment of the present invention, mobile phone browser is through obtaining cellphone subscriber's relevant information, and carries out weight relatively with the default language value of browser version, confirms a kind of precedence language value, and the web page contents of corresponding language version is provided for the user.The present invention is through rationally and use unified standard to carry out specification request, rationally judges requirement language information is returned the correct page language, has satisfied user's demand to the page language version when browsing page.
Description of drawings:
Fig. 1 is provided with the synoptic diagram of the method for page language automatically for browser of mobile terminal;
Fig. 2 is provided with the process flow diagram of the system of page language automatically for browser of mobile terminal.
Embodiment:
Specify embodiment of the present invention below in conjunction with accompanying drawing.
Fig. 1 shows the process flow diagram that browser of mobile terminal is provided with the method for page language automatically.Employed language request head is accept-language in the present embodiment.Accept-language is one of request header data that meet the W3C standard, has comprised the language message that the user uses, and web page server can judge this information, return with the accept-language request in identical language, make things convenient for the user to read.
As shown in Figure 1, in step S1, the user logins browser of mobile terminal, and browser of mobile terminal is carried out initialization.In step S2, said browser obtains user related information and accept-language data.Wherein, the SIM of said browser identification mobile phone obtains the user related informations such as GPS information data, IP database of network operator information, the portable terminal of portable terminal.
In step S3; Said browser is ignored the default language value of portable terminal; And confirm the precedence language value according to the weight that presets of the default language value of said user related information and browser version: when the user imports the target network address, when sending access request, browser can append in the request by automatic production language request header (accept-language); Original language value in the said language request head is the default language value of portable terminal, and this default language value has the highest priority.Said browser is ignored this default language value.
The default language value of browser version is the language version of user's selected browser software when browser software is installed, like Chinese edition, English edition, the Russian edition, Vietnam's version or the like.Said browser has preestablished the default language value of said browser version and the weight of each relevant information of user, the default language value of wherein said browser version preset the weight maximum.After said browser calculated the pairing weight of each languages and compares, the languages that weight proportion is maximum were confirmed as the precedence language value.
For example, can weight be set at respectively: the network operator information 35% of browser version default language value 40%, portable terminal, the GPS information data 15% of portable terminal and IP database 10%.The default language value of supposing this mobile phone is for English, and the language version of browser software is Vietnam's version, and the user uses this mobile phone within Chinese territory, and the Virtual network operator of mobile phone is Chinese company.Then browser is at first ignored the default language value English of mobile phone; Again other parameter weights are calculated comparison: at this moment; Because the GPS information data of network operator information, portable terminal and IP database are Chinese, the weight proportion of Chinese is 60%, and the weight of Vietnam's literary composition; Be merely the weight 40% of browser version default language value, then can the precedence language value be confirmed as in Chinese.When weight was set, the weight of each parameter is provided with all can realize the object of the invention less than 50%, is not limited to the parameter setting in the above-mentioned example.
In step S4, said browser writes said precedence language value among the accept-language, finally obtains the accept-language that the user needs, production language request header data.
In step S5; Said browser carries out data interaction through the server of special channel and system of basic unit and the page of being browsed; Said accept-language data are sent to the server of the page of being browsed; Said server is through the language value in the identifiable language request header, return with said language request head in the content of pages of identical language version give said browser.(step S6).
Fig. 2 shows the synoptic diagram that browser of mobile terminal is provided with the system of page language automatically.As shown in Figure 2, the system that browser of mobile terminal is provided with page language automatically comprises: information acquisition unit 1, information analysis unit 2, request header reset cell 3 and data interaction unit 4.Information acquisition unit 1, information analysis unit 2, request header reset cell 3, data interaction unit 4 and CPU5 are connected through data bus 6.CPU5 is through data bus 6 control information collecting units 1, the operation of information analysis unit 2, request header reset cell 3 and data interaction unit 4.
The default language value of portable terminal is ignored in information analysis unit 2, and according to the precedence language value that weight is confirmed the user that presets of the default language value of said user related information and browser version.Wherein, the default language value of said browser version presets the weight maximum.When weight was set, the weight of each parameter is provided with all can realize the object of the invention less than 50%.
Request header reset cell 3 writes determined precedence language value in the above-mentioned information analysis unit 2 among the accept-language, finally obtains the accept-language that the user needs, production language request header data.
Through the technical scheme of embodiment of the present invention, mobile phone browser is through obtaining cellphone subscriber's relevant information, and carries out weight relatively with the default language value of browser version, confirms a kind of precedence language value, and the web page contents of corresponding language version is provided for the user.The present invention carries out specification request through rationally also using unified standard; Reasonable judges requirement language information; Reduce the user because of other extraneous factors such as resource or network cause returning the situation of linguistic errors, satisfied user's demand to the page language version when browsing page.
Aforesaid detailed description and accompanying drawing carry out through literal interpretation and diagram, and its purpose does not lie in the protection domain that limits claim.Each mutation of embodiment in this instructions is obvious for those of ordinary skill, and is in the protection domain of claim and equivalent technologies thereof.
Claims (8)
1. a browser of mobile terminal is provided with the method for page language automatically, comprising:
Browser obtains user related information, ignores the default language value of portable terminal;
The weight that presets according to the default language value of said user related information and browser version is confirmed the precedence language value, comprises the pairing weight of each languages is calculated and compared, and the languages that weight proportion is maximum are confirmed as the precedence language value;
Said precedence language value is write in the language request head production language request header data;
A said language request data are sent to web page server, and receive the content of pages of corresponding language version.
2. the method that page language is set automatically according to claim 1 is characterized in that, said user related information comprises: the GPS information data of the network operator information of portable terminal, portable terminal, IP database.
3. the method that page language is set automatically according to claim 1 is characterized in that, the default language value of said browser version preset the weight maximum.
4. the method that page language is set automatically according to claim 1; It is characterized in that; After said browser sends to web page server with a said language request data; Said server is discerned the language value in the said language request head, return with said language request head in the content of pages of identical language version.
5. a browser of mobile terminal is provided with the system of page language automatically, comprising:
Information acquisition unit: be used for when the browser initialization, obtaining user related information;
Information analysis unit: the default language value of ignoring portable terminal; And confirm the precedence language value according to the weight that presets of the default language value of said user related information and browser version; Comprise the pairing weight of each languages calculated and compared that the languages that weight proportion is maximum are confirmed as the precedence language value;
Request header reset cell: said precedence language value is write in the language request head production language request header data;
Data interaction unit: be used for a said language request data are sent to web page server, and receive the content of pages of corresponding language version.
6. the system that page language is set automatically according to claim 5 is characterized in that, said user related information comprises: the GPS information data of the network operator information of portable terminal, portable terminal, IP database.
7. the system that page language is set automatically according to claim 5 is characterized in that, the default language value of said browser version preset the weight maximum.
8. the system that page language is set automatically according to claim 5; It is characterized in that; In said data interaction unit; After said browser sent to web page server with a language request data, said server was discerned the language value in the said language request head, return with said language request head in the content of pages of identical language version.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN2010102864518A CN101957846B (en) | 2010-09-19 | 2010-09-19 | Method and system for automatically setting page language by mobile terminal browser |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN2010102864518A CN101957846B (en) | 2010-09-19 | 2010-09-19 | Method and system for automatically setting page language by mobile terminal browser |
Publications (2)
Publication Number | Publication Date |
---|---|
CN101957846A CN101957846A (en) | 2011-01-26 |
CN101957846B true CN101957846B (en) | 2012-07-04 |
Family
ID=43485176
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN2010102864518A Active CN101957846B (en) | 2010-09-19 | 2010-09-19 | Method and system for automatically setting page language by mobile terminal browser |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN101957846B (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2014090042A1 (en) * | 2012-12-13 | 2014-06-19 | 珠海赛纳打印科技股份有限公司 | Webpage forming method, peripheral apparatus, and system |
US9620125B2 (en) | 2013-12-27 | 2017-04-11 | Wistron Corporation | Method of providing input method and electronic device using the same |
Families Citing this family (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102323937A (en) * | 2011-08-31 | 2012-01-18 | 百度在线网络技术(北京)有限公司 | Method and equipment for providing search result |
CN103377206B (en) * | 2012-04-18 | 2016-04-06 | 腾讯科技(深圳)有限公司 | The method of display page content and browser |
EP3037984A4 (en) * | 2013-11-29 | 2016-11-02 | Huawei Device Co Ltd | Method and apparatus for obtaining network resources |
CN105488041B (en) * | 2014-09-15 | 2018-08-24 | 北京畅游天下网络技术有限公司 | The method for realizing the multilingual display of browser interface |
CN104503987A (en) * | 2014-12-02 | 2015-04-08 | 深圳市金立通信设备有限公司 | Terminal |
CN106569822A (en) * | 2016-11-03 | 2017-04-19 | 深圳市证通电子股份有限公司 | Language matching method and device of WEB system |
CN109669552A (en) * | 2018-12-28 | 2019-04-23 | 北京小米移动软件有限公司 | Conversation processing method, device and storage medium |
CN110413932B (en) * | 2019-07-31 | 2022-05-06 | 北京金山云网络技术有限公司 | Page display method, device, terminal, server, system and storage medium |
CN113515710B (en) * | 2021-04-23 | 2024-03-01 | 北京金山云网络技术有限公司 | Page information display method and device, electronic equipment and storage medium |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2003296223A (en) * | 2002-03-29 | 2003-10-17 | Fuji Xerox Co Ltd | Method and device, and program for providing web page information |
WO2004088479A2 (en) * | 2003-03-26 | 2004-10-14 | Victor Hsieh | Online intelligent multilingual comparison-shop agents for wireless networks |
KR100708813B1 (en) * | 2004-06-04 | 2007-04-18 | (주)넷피아닷컴 | Native Language Internet Address System |
CN101567906A (en) * | 2009-05-25 | 2009-10-28 | 阿里巴巴集团控股有限公司 | Method and server for confirming the webpage content language |
-
2010
- 2010-09-19 CN CN2010102864518A patent/CN101957846B/en active Active
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2014090042A1 (en) * | 2012-12-13 | 2014-06-19 | 珠海赛纳打印科技股份有限公司 | Webpage forming method, peripheral apparatus, and system |
US10007738B2 (en) | 2012-12-13 | 2018-06-26 | Zhuhai Pantum Electronics Co., Ltd. | Method for forming webpage, peripheral apparatus and system |
US9620125B2 (en) | 2013-12-27 | 2017-04-11 | Wistron Corporation | Method of providing input method and electronic device using the same |
TWI594134B (en) * | 2013-12-27 | 2017-08-01 | 緯創資通股份有限公司 | Method of providing input method and electronic device using the same |
Also Published As
Publication number | Publication date |
---|---|
CN101957846A (en) | 2011-01-26 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN101957846B (en) | Method and system for automatically setting page language by mobile terminal browser | |
KR101922037B1 (en) | Page operation processing method and apparatus, and terminal | |
CN102722551B (en) | Intelligent switching method and system for browser kernels | |
CN103246657A (en) | Method and device for generating browser bookmark and method and device for browsing web page | |
CN102682093A (en) | Web page sectionally-loading method and web page sectionally-loading system for mobile browser | |
CN103404182A (en) | Method and apparatus for preventing illegal access of business | |
WO2014059906A1 (en) | Method and system for accessing audio/video community virtual rooms | |
CN104301161A (en) | Computing method, computing device and communication system for business quality index | |
CN103237088A (en) | Corresponding relation library-based browsing method and system and cloud server | |
CN103593408A (en) | Method and device for acquiring user subscription resources | |
CN102831150B (en) | Browser and local exchange method, system and the terminal applied | |
CN107124477A (en) | Processing method, terminal and the server of web site contents | |
CN102222095B (en) | Equipment for converting webpage to be displayed and method thereof | |
CN110555145A (en) | Browser-based webpage content acquisition system and acquisition method thereof | |
CN104182402A (en) | Browser interface address bar input control method and browser interface address bar input control system | |
JP2008537202A (en) | A device-independent addressing system that accesses web pages via public mobile networks | |
CN101883354A (en) | Self-service site establishing method based on 3G (The 3rd Generation Telecommunication) mobile network | |
CN103440281A (en) | Method, device and equipment for acquiring download file | |
US20150317143A1 (en) | Method and apparatus for installing webpage application | |
EP2998885A1 (en) | Method and device for information search | |
CN102831179A (en) | Webpage processing method and device | |
CN105491064B (en) | A kind of method for pushing and equipment | |
CN101808110B (en) | Forum access method based on mobile communication equipment terminal | |
KR101111898B1 (en) | Server system for reducing use of packet data use for smart phone | |
CN105338091A (en) | High-transmission-efficiency personalized information interface display method and apparatus |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant | ||
TR01 | Transfer of patent right | ||
TR01 | Transfer of patent right |
Effective date of registration: 20200527 Address after: 310051 room 508, floor 5, building 4, No. 699, Wangshang Road, Changhe street, Binjiang District, Hangzhou City, Zhejiang Province Patentee after: Alibaba (China) Co.,Ltd. Address before: 100080, Beijing, Suzhou Street, Haidian District No. 29 hospital, No. 18, building 16, Scandinavia Patentee before: UC MOBILE Ltd. |