CN110362370A - A kind of switching method of homepages language, device and terminal device - Google Patents

A kind of switching method of homepages language, device and terminal device Download PDF

Info

Publication number
CN110362370A
CN110362370A CN201910517960.8A CN201910517960A CN110362370A CN 110362370 A CN110362370 A CN 110362370A CN 201910517960 A CN201910517960 A CN 201910517960A CN 110362370 A CN110362370 A CN 110362370A
Authority
CN
China
Prior art keywords
language
information
target
type
webpage
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.)
Granted
Application number
CN201910517960.8A
Other languages
Chinese (zh)
Other versions
CN110362370B (en
Inventor
陈彩霞
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ping An Technology Shenzhen Co Ltd
Original Assignee
Ping An Technology Shenzhen Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Ping An Technology Shenzhen Co Ltd filed Critical Ping An Technology Shenzhen Co Ltd
Priority to CN201910517960.8A priority Critical patent/CN110362370B/en
Publication of CN110362370A publication Critical patent/CN110362370A/en
Priority to PCT/CN2020/093600 priority patent/WO2020248849A1/en
Application granted granted Critical
Publication of CN110362370B publication Critical patent/CN110362370B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/451Execution arrangements for user interfaces
    • G06F9/454Multi-language systems; Localisation; Internationalisation

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The present invention provides a kind of switching method of homepages language, device and terminal devices, suitable for Internet technical field, this method comprises: receiving the language switching instruction that user is issued in target webpage for selection object, language switching instruction carries the attribute information about target language type;Obtain the object type for choosing object;Based on selection object and object type, determine corresponding webpage information to be converted, and webpage information to be converted is sent to background server, so as to obtain target information after the language form of webpage information to be converted is switched to target language type from original language type by background server;The target information that background server returns is received, and target information is showed in for the new labels page for choosing Object Creation.The present invention improves the flexibility of homepages language switching;User need not refresh the original web page, can also check the content of pages of language form needed for oneself, reduce cumbersome degree during web page access.

Description

A kind of switching method of homepages language, device and terminal device
Technical field
The invention belongs to Internet technical field more particularly to a kind of switching methods of homepages language, device, terminal device And computer readable storage medium.
Background technique
With the continuous development of Internet technology, more and more websites start to be intended to internationalization processing, with realize by The content of website shows the user of different regions.For example, Chinese and English are all supported in many websites.When the language of user's selection When saying that type is Chinese, with the content of text in Chinese display webpage;When the language form that user selects is English, with English Show the content of text in webpage.
However, existing website deployment way is based on, when user browses to a certain page, if it triggers language on website Say handover event, then browser will reload the resource information of the website and return to website homepage, for example, reload with Another code page resource that English is write simultaneously returns to website homepage.In this case, user needs to carry out searching for webpage again After seeking operation, it can just be again introduced into the level webpage that last time accessed.As it can be seen that there are cumbersome for existing web page access mode Spend higher and lower flexibility problem, it is difficult to meet the web page access demand of user.
Summary of the invention
In view of this, the embodiment of the invention provides a kind of switching method of homepages language, device, terminal device and calculating Machine readable storage medium storing program for executing, the cumbersome degree present in solve in a manner of existing web page access is high and flexibility is lower asks Topic.
The first aspect of the embodiment of the present invention provides a kind of switching method of homepages language, comprising:
Receive the language switching instruction that user is issued in target webpage for selection object, the language switching instruction Carry the attribute information about target language type;
Obtain the object type for choosing object;
Based on the selection object and the object type, determine corresponding webpage information to be converted, and will it is described to Conversion webpage information is sent to background server, so that the background server is by the language form of the webpage information to be converted After the target language type is switched to from original language type, target information is obtained;
The target information that the background server returns is received, and the target information is showed in for the choosing It takes in the new labels page of Object Creation.
The second aspect of the embodiment of the present invention provides a kind of switching device of homepages language, comprising:
Receiving unit, the language switching instruction issued in target webpage for selection object for receiving user, institute It states language switching instruction and carries attribute information about target language type;
First acquisition unit, for obtaining the object type for choosing object;
Determination unit determines corresponding webpage letter to be converted for being based on the selection object and the object type Breath, and is sent to background server for the webpage information to be converted, so that the background server is by the webpage to be converted After the language form of information is switched to the target language type from original language type, target information is obtained;
Display unit, the target information returned for receiving the background server, and by the target information exhibition It is shown in the new labels page for choosing Object Creation.
The third aspect of the embodiment of the present invention provides a kind of terminal device, including memory and processor, described to deposit Reservoir is stored with the computer program that can be run on the processor, and the processor is realized when executing the computer program The step of such as switching method of above-mentioned homepages language.
The fourth aspect of the embodiment of the present invention provides a kind of computer readable storage medium, the computer-readable storage Media storage has computer program, and the processor realizes the switching side such as above-mentioned homepages language when executing the computer program The step of method.
In the embodiment of the present invention, referred in target webpage for the language switching that selection object is issued by receiving user It enables, determines corresponding webpage information to be converted based on object and its object type is chosen, ensure that in site language switching In operating process, the conversion about part space of a whole page content can be only carried out, improves the flexibility of homepages language switching;Passing through will The target information that background server returns is showed in for choosing in the new labels page that is created of object, so that user is need not Under the case where refreshing original Website page, it also can quickly check the content of pages of language form needed for oneself, be not in Parent page returns to the case where homepage, thus reduces cumbersome degree of user during web page access.
Detailed description of the invention
It to describe the technical solutions in the embodiments of the present invention more clearly, below will be to embodiment or description of the prior art Needed in attached drawing be briefly described, it should be apparent that, the accompanying drawings in the following description is only of the invention some Embodiment for those of ordinary skill in the art without any creative labor, can also be according to these Attached drawing obtains other attached drawings.
Fig. 1 is the implementation process schematic diagram of the switching method of homepages language provided in an embodiment of the present invention;
Fig. 2 is the specific implementation flow chart of the switching method S103 of homepages language provided in an embodiment of the present invention;
Fig. 3 be another embodiment of the present invention provides homepages language switching method implementation process schematic diagram;
Fig. 4 is the implementation process schematic diagram of the switching method for the homepages language that further embodiment of this invention provides;
Fig. 5 is another specific implementation flow chart of the switching method S103 of homepages language provided in an embodiment of the present invention;
Fig. 6 is the structural block diagram of the switching device of homepages language provided in an embodiment of the present invention;
Fig. 7 is the schematic diagram of terminal device provided in an embodiment of the present invention.
Specific embodiment
In being described below, for illustration and not for limitation, the tool of such as particular system structure, technology etc is proposed Body details, to understand thoroughly the embodiment of the present invention.However, it will be clear to one skilled in the art that there is no these specific The present invention also may be implemented in the other embodiments of details.In other situations, it omits to well-known system, device, electricity The detailed description of road and method, in case unnecessary details interferes description of the invention.
It should be understood that although term " first ", " second " etc. are used in some embodiment of the present invention in the text Various elements are described, but these elements should not be limited by these terms.These terms are used only to an element It is distinguished with another element.
In order to illustrate technical solutions according to the invention, the following is a description of specific embodiments.
Fig. 1 shows the implementation flow chart of the switching method of homepages language provided in an embodiment of the present invention, and details are as follows:
S101: receiving the language switching instruction that user is issued in target webpage for selection object, and the language is cut Change the attribute information for instructing and carrying about target language type.
In the embodiment of the present invention, the webpage browsed needed for user is target webpage.It is instructed according to the web page access received, The web page source code of target webpage is parsed, and with the language form that web page source code is preset in browser interface, to target The character string of webpage carries out loaded and displayed.User can choose mesh by moving to the cursor run in browser interface Mark any object in webpage.After any object is selected, if detecting language toggle control in browser interface by point Triggering is hit, then confirmation receives user and is directed to the language switching instruction that the selection object is issued.Wherein, in language toggle control When being clicked triggering, browser interface will generate a language form and show list.Language form shows that list includes preset more Kind language form, such as Chinese, English, Chinese, Japanese, Spanish, Thai and French etc..By user in language form exhibition Show that selected language form is encapsulated as an attribute information into language switching instruction in list.
Preferably, when detecting the access request about target webpage, user identifier entrained by access request is obtained. It in preset history information library, searches and is recorded with the matched page browsing of the user identifier, and extract this page browsing note The associated history access language of record.In the information bank for storing source code corresponding to the target webpage, obtains and visited with the history Ask language corresponding scripted code.After the browser resolves scripted code, load obtains showing with the history access language Target pages.
In the embodiment of the present invention, for same user, due to its commonly use language form usually and be all it is relatively stable not Become, therefore, is recorded, come with associated history access language initial by obtaining the page browsing to match with its user identifier Change shows target pages, the number of operations that user carries out language switching to target webpage can be reduced, so that it is clear to improve webpage Look at efficiency.
S102: the object type for choosing object is obtained.
In the embodiment of the present invention, for selection object associated by language switching instruction, existed by distinguishing the selection object Tag attributes in web page code determine the object type of the selection object.Object type includes but is not limited to level-one tag class Type, second level tag types and other rank tag types.
Above-mentioned level-one tag types for example can be title and subtitle etc.;Second level tag types for example can be text Paragraph, table, picture and video etc..
It illustratively, can if user wants to carry out language switching to the content of text on picture a certain in target webpage The picture is determined as to choose object.In the source code information of target webpage, label category corresponding to the selection object is positioned Property.If detecting, its tag attributes is picture tag<img>, then can recognize that the object type of the selection object is second level label. It similarly, can be by mobile cursor come to this if user wants to carry out language switching to a text fragment in target webpage Text fragment is chosen.If the corresponding source code information of the selection object is<p>this is a paragraph</p>, then The tag attributes that can recognize the selection object are text fragment, accordingly, it is determined that going out its object type is second level label.
S103: being based on the selection object and the object type, determine corresponding webpage information to be converted, and by institute It states webpage information to be converted and is sent to background server, so that the background server is by the language of the webpage information to be converted After type is switched to the target language type from original language type, target information is obtained.
Webpage information to be converted indicates that in subsequent language form handoff procedure, background server needs to carry out language and turns Change the partial character string content of processing.Selection object is identical as webpage information possibility to be converted may also be different, according to selection The object type and/or tag attributes of object determines.
In the embodiment of the present invention, preset transformation rule is loaded.By the way that the current object type input for choosing object is somebody's turn to do Transformation rule carries out detection processing, determines corresponding webpage information to be converted.Illustratively, above-mentioned transformation rule includes:
If the tag attributes for choosing object are title, corresponding webpage information to be converted is to connect under title text and title The continuous multiple text fragments occurred;If the tag attributes for choosing object are text fragment, corresponding webpage information to be converted is Choose each character string that object itself is included;If the tag attributes for choosing object are picture, corresponding webpage to be converted Information is the text character being contained in picture;If the tag attributes for choosing object are video/audio, corresponding net to be converted Page information is video source/source of sound captioned test information.
In the embodiment of the present invention, the webpage information to be converted determined and the language switching instruction received are sent to For executing the background server of text translating operation.The target language type according to entrained by language switching instruction, backstage take Business device treats conversion webpage information and carries out language conversion processing, to realize the language form of webpage information to be converted from original language After type is switched to target language type, the target information of generation is returned.
Preferably, if the text character that webpage information to be converted includes by picture, the source address of picture is sent To background server, so as to utilize preset picture detection algorithm to know after background server is Loaded Image based on the source address Not its text character for being included.If information to be converted is video source/source of sound captioned test information, video source/sound is obtained The origin server information in source.Based on origin server information, request downloading and the associated captioned test information of video source/source of sound Afterwards, then by captioned test information it is sent to background server.
S104: the target information that the background server returns is received, and the target information is showed in and is directed to In the new labels page for choosing Object Creation.
In the embodiment of the present invention, the target information that background server returns is received.Obtain modules in target webpage Code copy, and in code copy replaces with the first source code of webpage information said module to be converted and target information Associated second source code.Meanwhile in browser interface, a new labels page is additionally generated.To it is updated include The above-mentioned code copy of two source codes is parsed, to render the visit shown with object language again in above-mentioned new labels page Ask the page.
In the embodiment of the present invention, referred in target webpage for the language switching that selection object is issued by receiving user It enables, determines corresponding webpage information to be converted based on object and its object type is chosen, ensure that in site language switching In operating process, the conversion about part space of a whole page content can be only carried out, improves the flexibility of homepages language switching;Passing through will The target information that background server returns is showed in the new labels page currently created, so that user need not refresh original net Stand the page the case where under, also can quickly check the content of pages of language form needed for oneself, be not in that parent page is returned The case where returning homepage, thus reduce cumbersome degree of user during web page access.
As an embodiment of the present invention, Fig. 2 shows the conversion methods of homepages language provided in an embodiment of the present invention The specific implementation flow of S103, details are as follows:
S1031: if the object type is level-one tag types, the source code information of the target webpage is obtained.
In the embodiment of the present invention, the tag attributes of object are chosen by detection, and according to preset tag attributes and right As the mapping table of type, the object type for choosing object is determined.If the object type for choosing object is level-one tag class Type then reads the source code information of target webpage, and therefrom orients and choose the matched source code information of object institute.
S1032: in the source code information, each second level mark chosen and continuously occurred after object is positioned Label, and the selection object and the associated code information of second level label are obtained respectively.
Usually, in the source code information of webpage, can all occur after the source code information of level-one label associated Multiple code modules, and code module can include one or more object tags.In the embodiment of the present invention, to selection object institute The source code information matched, using its said code distributing position as starting point, detection continuously occurs after the code distributing position Each second level label, and the code information that each second level label is included to the level-one label and thereafter is read out.
For example, if there are following two continuously occurred text fragment labels after level-one label said code distributing position <p>:<p>this is a paragraph1</p><p>this is a paragraph2</p>, then with above-mentioned two second level mark Signing associated code information is " This is a paragraph1 " and " This is a paragraph2 ".
S1033: the code information is determined as webpage information to be converted corresponding with the selection object.
In the embodiment of the present invention, since user need to only choose the object that object type is level-one tag types, example Such as, the caption text part of target webpage is chosen, system, which just can be oriented, to be chosen object and its continuously occur later each A second level label, and code information associated by level-one label and second level label is obtained respectively, to automatically determine corresponding Webpage information to be converted avoids user and needs to click the wider webpage information to be converted of selection distribution one by one, thus drops The low cumbersome degree of user is improved to the efficiency of selection for choosing object;It include title, text chunk due to choosing object It falls, a plurality of types of object types such as image, video and voice, thus expands the applicable model of language form change event It encloses, so that homepages language switching is not limited only to the content of text of target webpage, thus improves flexibility, meet more users Web page access demand.
As another embodiment of the invention, Fig. 3 show another embodiment of the present invention provides homepages language cut Change the implementation process of method.As shown in figure 3, after above-mentioned S104, further includes:
S105: detecting the first currency identifier in the presence of the target information, and determines corresponding first currency First currency type of identifier and the first amount of money value.
In the embodiment of the present invention, to the target information to be presented in new labels page that background server returns, detection It whether there is the first currency identifier in target information.Wherein, the first currency identifier be present in it is any in the presets list The currency identifier of type, including but not limited to" $ ", " £ ", " Yen " andDeng.
If detecting, there are the first currency identifiers in target information, according to preset currency conversion list, acquisition pair Should the first currency identifier the first currency type.Currency conversion list for record currency identifier, currency type and The mapping relations of language form.For example, if the first currency identifier in the presence of target information isThen acquire The first currency type be dollar, corresponding language form be English.
In the embodiment of the present invention, the digital information of display adjacent with the first currency identifier in target information is extracted, will be mentioned Value output is the first currency values corresponding with the first currency mark, for indicating that the amount of currency of the currency type is worth Size.
S106: it according to preset currency conversion list, obtains and is identified with the matched second-cash of the target language type Symbol and second-cash type.
According to above-mentioned currency conversion list, search and the matched second-cash identifier of target language type and the second goods Coin type.By the way that the first currency type and second-cash type are sent to exchange rate conversion platform or by calling exchange rate inquiry Interface is obtained about the first currency type and the real-time exchange rate return value of second-cash type.
S107: the real-time exchange rate of first currency type and the second-cash type is obtained, and based on described real-time The exchange rate calculates second amount of money value corresponding with first amount of money value.
S108: by the target information first amount of money value and first currency identifier be updated to respectively Second amount of money value and the second-cash identifier.
In the embodiment of the present invention, according to above-mentioned the first amount of money value and the real-time exchange rate acquired, calculate and the first gold medal Corresponding second amount of money value of volume value, and the first amount of money value replacement in target information is shown as the second amount of money value, by the first goods The replacement of coin identifier is shown as second-cash identifier.
Illustratively, if including in the target information that background server is returnedThis character string, then detect The first obtained currency type is dollar;If target language type entrained by language switching instruction is Chinese, pass through currency Translation lists, it may be determined that going out with the second-cash type of Chinese matching is RMB, and currency identifier is " ".It is same with this When, by preset exchange rate query interface, obtain the real-time exchange rate of RMB and U.S. dollar.If the real-time exchange rate is 1:6, basis should Exchange rate, will be in target informationBe converted to " $1200 ", and by " $1200 " this character string is showed in newly In labels page.
In the embodiment of the present invention, by the first currency identifier in detection target information, and in the first currency identifier There are the case where under, automatically determine the currency type that object language is applicable in, show and matched second goods of the currency type Coin identifier and the second-cash amount of money ensure that user can have preferable experience effect during browsing web sites the page Fruit, convenient for checking that currency conversion between different regions etc. is worth, to improve the interactive performance of webpage.
As another embodiment of the invention, on the basis of above-described embodiment, the acquisition to target language type Mode is further limited.As shown in figure 4, before above-mentioned S101, further includes:
S109: in currently running medium of communication window, the chat record of the user in nearest preset duration is extracted Information.
In the embodiment of the present invention, if monitoring, communication applications software is in starting state, including front stage operation state and Background operation state is then searched and calls medium of communication window relevant to communication applications software.According to the medium of communication window The matched communication account of institute, reads the chat record information in nearest preset duration about the communication account.
S110: the language form of each character in the chat record information is detected.
Chat record information is usually made of the character string and multimedia file of multilingual type.The embodiment of the present invention In, obtain the language form of each character in chat record information.If chat record information includes picture file, picture is identified Character included in file, and obtain the language form of the character.
S111: counting the character sum of each language form respectively, and by the maximum institute's predicate of character sum Speech type is determined as the target language type of the user.
To each language form, the character corresponding with the language form detected in chat record information is counted Sum.By comparing the numerical values recited of the character sum of each language form, the wherein maximum language of character sum is selected Type, and the language form is determined as user's required target language type used in target pages.
For example, if including recently 50 Chinese characters and 20 English words in the chat record information of preset duration Symbol, then the maximum language form of character sum is Chinese, therefore, Chinese is determined as to the target language type of user.
Preferably, after determining the maximum language form of character sum, in webpage runnable interface, current use is detected Family switches the character input method used, and obtains language form corresponding with the character input method.If the language acquired Type is identical as the character maximum language form of sum, then the language form is just determined as to the target language type of user.
In the embodiment of the present invention, since the chat record information in nearest preset duration in medium of communication window is usually eventually End subscriber is according to the Content of communciation of itself language needs institute typing, therefore the language form and use of the included character of chat record information In the browsing objective page, there are the higher goodnesses of fit for the required language form used at family, therefore, pass through detection chat record letter The maximum language form of character sum is determined as the target language type of user, realized by the language form of each character in breath The automatic positioning of object language so that user in target pages without carrying out the manual switching of homepages language, thus reduce Cumbersome degree, improves webpage interactive performance.
As an embodiment of the present invention, Fig. 5 shows the switching method of homepages language provided in an embodiment of the present invention Another specific implementation flow of S103, details are as follows:
S1034: it is based on the selection object and the object type, determines corresponding webpage information to be converted, and examine Survey each phrase element that the webpage information to be converted is included.
Each implementation steps mentioned in through the foregoing embodiment are determining opposite with selection object and its object type After the webpage information to be converted answered, treats conversion webpage information and carry out word segmentation processing, included to obtain webpage information to be converted Each phrase element.
S1035: calling preset language switching interface, traverses each phrase element, determines wherein each institute respectively Predicate group element whether there is matched target switch element.
In the embodiment of the present invention, phrase member is determined by calling preset language switching interface to each phrase element Element whether there is and the matched target switch element of target language type.Wherein, language switching interface is used for before language switching Phrase element afterwards is compared.In the element set comprising all kinds of language form elements collected in advance, if inquiry is somebody's turn to do Phrase element exists and the matched target switch element of target language type, then it represents that, should after the operation of language hand-off process There is character change in phrase element.
Illustratively, if webpage information to be converted is " three USB ports ", target language type is English, then its phrase member Element includes " USB ".For " USB " this phrase element, due to its before language conversion with it after language conversion It should be equally shown as " USB ", therefore, by above-mentioned language switching interface, determining the phrase element, there is no matched mesh Mark switch element.
S1036: if matched target switch element is not present in the phrase element, retaining and show the phrase element, and The webpage information to be converted in addition to the phrase element is sent to background server.
In the embodiment of the present invention, there will be no the phrase elements of matching target switch element to believe from webpage to be converted Rejecting processing is carried out in breath.In webpage information to be converted, preset mark is added to the affiliated original position of the phrase element.It will not wrap Webpage information to be converted containing the phrase element is sent to background server, so that background server is only each to what is received Phrase element executes language conversion and handles and return to relevant target information.
When the target information that platform server returns upon receipt, the phrase element of above-mentioned rejecting is added to again default The corresponding page location of label.So far, realize phrase element and target information merges displaying.
In the embodiment of the present invention, each phrase element for being included by detecting webpage information to be converted calls language to cut Alias carrys out grammatical term for the character group element with the presence or absence of matched target switch element, when the judgment result is No, will remove phrase member Webpage information to be converted except element is sent to background server, realizes the modular language conversion of phrase element, ensure that Background server is not necessarily to carry out repeating conversion process to the phrase element there is no target switch element, and this improves to mesh Mark the language switching efficiency of webpage.
It should be understood that the size of the serial number of each step is not meant that the order of the execution order in above-described embodiment, each process Execution sequence should be determined by its function and internal logic, the implementation process without coping with the embodiment of the present invention constitutes any limit It is fixed.
Corresponding to the method for foregoing embodiments, Fig. 6 shows the switching device of homepages language provided in an embodiment of the present invention Structural block diagram, for ease of description, only parts related to embodiments of the present invention are shown.The exemplary homepages language of Fig. 6 Switching device can be the executing subject of the switching method of the homepages language of previous embodiment offer.
Referring to Fig. 6, the switching device of the homepages language includes:
Receiving unit 61, the language switching instruction issued in target webpage for selection object for receiving user, The language switching instruction carries the attribute information about target language type.
First acquisition unit 62, for obtaining the object type for choosing object.
Determination unit 63 determines corresponding webpage to be converted for being based on the selection object and the object type Information, and the webpage information to be converted is sent to background server, so that the background server is by the net to be converted After the language form of page information is switched to the target language type from original language type, target information is obtained.
Display unit 64, the target information returned for receiving the background server, and by the target information It is showed in the new labels page for choosing Object Creation.
Optionally, the switching device of above-mentioned homepages language further include:
First detection unit for detecting the first currency identifier in the presence of the target information, and is determined and is corresponded to First currency type of first currency identifier and the first amount of money value.
Second acquisition unit, for obtaining matched with the target language type according to preset currency conversion list Second-cash identifier and second-cash type.
Computing unit for obtaining the real-time exchange rate of first currency type Yu the second-cash type, and is based on The real-time exchange rate calculates second amount of money value corresponding with first amount of money value.
Updating unit, for by first amount of money value and first currency identifier point in the target information It is not updated to second amount of money value and the second-cash identifier.
Optionally, the determination unit 63 includes:
Subelement is obtained, if being level-one tag types for the object type, obtains the source generation of the target webpage Code information.
Locator unit, for continuously occurring after the positioning selection object each in the source code information A second level label, and the selection object and the associated code information of second level label are obtained respectively.
It determines subelement, believes for the code information to be determined as webpage to be converted corresponding with the selection object Breath.
Optionally, the determination unit 63 includes:
Detection sub-unit determines corresponding webpage to be converted for being based on the selection object and the object type Information, and detect each phrase element that the webpage information to be converted is included.
Subelement is traversed, for calling preset language switching interface, each phrase element is traversed, determines it respectively In each phrase element whether there is matched target switch element.
Retain subelement, if matched target switch element is not present for the phrase element, retains and show the word Group element, and the webpage information to be converted in addition to the phrase element is sent to background server.
Optionally, the switching device of the homepages language further include:
Extraction unit, for extracting the user in nearest preset duration in currently running medium of communication window Chat record information.
Second detection unit, for detecting the language form of each character in the chat record information.
Statistic unit, for counting the character sum of each language form respectively, and the character sum is maximum The language form be determined as the target language type of the user.
In the embodiment of the present invention, referred in target webpage for the language switching that selection object is issued by receiving user It enables, determines corresponding webpage information to be converted based on object and its object type is chosen, ensure that in site language switching In operating process, the conversion about part space of a whole page content can be only carried out, improves the flexibility of homepages language switching;Passing through will The target information that background server returns is showed in the new labels page currently created, so that user need not refresh original net Stand the page the case where under, also can quickly check the content of pages of language form needed for oneself, be not in that parent page is returned The case where returning homepage, thus reduce cumbersome degree of user during web page access.
Fig. 7 is the schematic diagram for the terminal device that one embodiment of the invention provides.As shown in fig. 6, the terminal of the embodiment is set Standby 7 include: processor 70 and memory 71, and the calculating that can be run on the processor 70 is stored in the memory 71 Machine program 72.The processor 70 realizes that the switching method of above-mentioned each homepages language is implemented when executing the computer program 72 Step in example, such as step 101 shown in FIG. 1 is to 104.Alternatively, when the processor 70 executes the computer program 72 Realize the function of each module/unit in above-mentioned each Installation practice, such as the function of unit 61 to 64 shown in Fig. 6.
The terminal device 7 can be the calculating such as desktop PC, notebook, palm PC and cloud server and set It is standby.The terminal device may include, but be not limited only to, processor 70, memory 71.It will be understood by those skilled in the art that Fig. 7 The only example of terminal device 7 does not constitute the restriction to terminal device 7, may include than illustrating more or fewer portions Part perhaps combines certain components or different components, such as the terminal device can also include input sending device, net Network access device, bus etc..
Alleged processor 70 can be central processing unit (Central Processing Unit, CPU), can also be Other general processors, digital signal processor (Digital Signal Processor, DSP), specific integrated circuit (Application Specific Integrated Circuit, ASIC), ready-made programmable gate array (Field- Programmable Gate Array, FPGA) either other programmable logic device, discrete gate or transistor logic, Discrete hardware components etc..General processor can be microprocessor or the processor is also possible to any conventional processor Deng.
The memory 71 can be the internal storage unit of the terminal device 7, such as the hard disk or interior of terminal device 7 It deposits.The memory 71 is also possible to the External memory equipment of the terminal device 7, such as be equipped on the terminal device 7 Plug-in type hard disk, intelligent memory card (Smart Media Card, SMC), secure digital (Secure Digital, SD) card dodge Deposit card (Flash Card) etc..Further, the memory 71 can also both include the storage inside list of the terminal device 7 Member also includes External memory equipment.The memory 71 is for storing needed for the computer program and the terminal device Other programs and data.The memory 71, which can be also used for temporarily storing, have been sent or data to be sent.
It, can also be in addition, the functional units in various embodiments of the present invention may be integrated into one processing unit It is that each unit physically exists alone, can also be integrated in one unit with two or more units.Above-mentioned integrated list Member both can take the form of hardware realization, can also realize in the form of software functional units.
If the integrated module/unit be realized in the form of SFU software functional unit and as independent product sale or In use, can store in a computer readable storage medium.Based on this understanding, the present invention realizes above-mentioned implementation All or part of the process in example method, can also instruct relevant hardware to complete, the meter by computer program Calculation machine program can be stored in a computer readable storage medium, the computer program when being executed by processor, it can be achieved that on The step of stating each embodiment of the method.Wherein, the computer program includes computer program code, the computer program generation Code can be source code form, object identification code form, executable file or certain intermediate forms etc..The computer-readable medium It may include: any entity or device, recording medium, USB flash disk, mobile hard disk, magnetic that can carry the computer program code Dish, CD, computer storage, read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), electric carrier signal, telecommunication signal and software distribution medium etc..
Embodiment described above is merely illustrative of the technical solution of the present invention, rather than its limitations;Although referring to aforementioned reality Applying example, invention is explained in detail, those skilled in the art should understand that: it still can be to aforementioned each Technical solution documented by embodiment is modified or equivalent replacement of some of the technical features;And these are modified Or replacement, the essence of corresponding technical solution is departed from the spirit and scope of the technical scheme of various embodiments of the present invention, it should all It is included within protection scope of the present invention.

Claims (10)

1. a kind of switching method of homepages language characterized by comprising
The language switching instruction that user is issued in target webpage for selection object is received, the language switching instruction carries About the attribute information of target language type;
Obtain the object type for choosing object;
Based on the selection object and the object type, corresponding webpage information to be converted is determined, and will be described to be converted Webpage information is sent to background server, so that the background server is by the language form of the webpage information to be converted from source After language form is switched to the target language type, target information is obtained;
The target information that the background server returns is received, and the target information is showed in for the selection pair As creation new labels page in.
2. the switching method of homepages language as described in claim 1, which is characterized in that further include:
It detects the first currency identifier in the presence of the target information, and determines the of corresponding first currency identifier One currency type and the first amount of money value;
According to preset currency conversion list, obtain and the matched second-cash identifier of the target language type and second Currency type;
Obtain the real-time exchange rate of first currency type Yu the second-cash type, and based on the real-time exchange rate calculate with Corresponding second amount of money value of first amount of money value;
By in the target information first amount of money value and first currency identifier be updated to described second respectively Amount of money value and the second-cash identifier.
3. the switching method of homepages language as described in claim 1, which is characterized in that it is described based on the selection object and The object type determines corresponding webpage information to be converted, comprising:
If the object type is level-one tag types, the source code information of the target webpage is obtained;
In the source code information, each second level label chosen and continuously occurred after object is positioned, and obtain respectively Take the selection object and the associated code information of second level label;
The code information is determined as webpage information to be converted corresponding with the selection object.
4. the switching method of homepages language as described in claim 1, which is characterized in that it is described based on the selection object and The object type determines corresponding webpage information to be converted, and the webpage information to be converted is sent to background server, Include:
Based on the selection object and the object type, corresponding webpage information to be converted is determined, and detect described wait turn Each phrase element that draping page information is included;
Preset language switching interface is called, each phrase element is traversed, determines wherein each phrase element respectively With the presence or absence of matched target switch element;
If matched target switch element is not present in the phrase element, retains and show the phrase element, and the phrase will be removed The webpage information to be converted except element is sent to background server.
5. the switching method of homepages language as described in claim 1, which is characterized in that in the reception user in target webpage In for before choosing the language switching instruction that is issued of object, further includes:
In currently running medium of communication window, the chat record information of the user in nearest preset duration is extracted;
Detect the language form of each character in the chat record information;
The character sum of each language form is counted respectively, and the maximum language form of character sum is determined For the target language type of the user.
6. a kind of switching device of homepages language characterized by comprising
Receiving unit, the language switching instruction issued in target webpage for selection object for receiving user, institute's predicate Speech switching command carries the attribute information about target language type;
First acquisition unit, for obtaining the object type for choosing object;
Determination unit, for determining corresponding webpage information to be converted based on the selection object and the object type, and The webpage information to be converted is sent to background server, so that the background server is by the webpage information to be converted After language form is switched to the target language type from original language type, target information is obtained;
Display unit, the target information returned for receiving the background server, and the target information is showed in For in the new labels page for choosing Object Creation.
7. the switching device of homepages language as claimed in claim 6, which is characterized in that further include:
First detection unit, for detecting the first currency identifier in the presence of the target information, and determine it is corresponding described in First currency type of the first currency identifier and the first amount of money value;
Second acquisition unit, for obtaining and the target language type matched second according to preset currency conversion list Currency identifier and second-cash type;
Computing unit, for obtaining the real-time exchange rate of first currency type Yu the second-cash type, and based on described The real-time exchange rate calculates second amount of money value corresponding with first amount of money value;
Updating unit, for by the target information first amount of money value and first currency identifier respectively more It is newly second amount of money value and the second-cash identifier.
8. the switching device of homepages language as claimed in claim 6, which is characterized in that the determination unit includes:
Subelement is obtained, if being level-one tag types for the object type, obtains the source code letter of the target webpage Breath;
Locator unit, in the source code information, positioning each two for choosing object and continuously occurring later Grade label, and the selection object and the associated code information of second level label are obtained respectively;
Subelement is determined, for the code information to be determined as webpage information to be converted corresponding with the selection object.
9. a kind of terminal device, including memory and processor, the memory, which is stored with, to be run on the processor Computer program, which is characterized in that the processor is realized when executing the computer program as claim 1 to 5 is any The step of item the method.
10. a kind of computer readable storage medium, the computer-readable recording medium storage has computer program, and feature exists In when the computer program is executed by processor the step of any one of such as claim 1 to 5 of realization the method.
CN201910517960.8A 2019-06-14 2019-06-14 Webpage language switching method and device and terminal equipment Active CN110362370B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201910517960.8A CN110362370B (en) 2019-06-14 2019-06-14 Webpage language switching method and device and terminal equipment
PCT/CN2020/093600 WO2020248849A1 (en) 2019-06-14 2020-05-30 Webpage language switching method and apparatus, and terminal device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910517960.8A CN110362370B (en) 2019-06-14 2019-06-14 Webpage language switching method and device and terminal equipment

Publications (2)

Publication Number Publication Date
CN110362370A true CN110362370A (en) 2019-10-22
CN110362370B CN110362370B (en) 2022-10-18

Family

ID=68217375

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910517960.8A Active CN110362370B (en) 2019-06-14 2019-06-14 Webpage language switching method and device and terminal equipment

Country Status (2)

Country Link
CN (1) CN110362370B (en)
WO (1) WO2020248849A1 (en)

Cited By (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110795192A (en) * 2019-10-29 2020-02-14 青岛海信传媒网络技术有限公司 Language switching method and device and terminal equipment
CN111061533A (en) * 2019-12-18 2020-04-24 深圳前海环融联易信息科技服务有限公司 Page multi-language display method and device, electronic equipment and computer storage medium
CN111124406A (en) * 2019-12-10 2020-05-08 东软集团股份有限公司 Static page language switching method and device, storage medium and electronic equipment
CN111767104A (en) * 2020-05-07 2020-10-13 北京奇艺世纪科技有限公司 Language type switching method and device, computer equipment and storage medium
CN111859087A (en) * 2020-07-23 2020-10-30 北京好扑信息科技有限公司 Block chain-based government affair announcement publishing system
CN111857906A (en) * 2020-06-03 2020-10-30 北京旷视科技有限公司 Text display method, device and system of terminal and storage medium
CN112068912A (en) * 2020-08-18 2020-12-11 深圳传音控股股份有限公司 System language type switching method, terminal and computer storage medium
WO2020248849A1 (en) * 2019-06-14 2020-12-17 平安科技(深圳)有限公司 Webpage language switching method and apparatus, and terminal device
CN112596841A (en) * 2020-12-24 2021-04-02 厦门亿联网络技术股份有限公司 Interface language switching method, device, equipment and storage medium
CN112817655A (en) * 2021-01-29 2021-05-18 北京达佳互联信息技术有限公司 Document information processing method, device, storage medium and electronic equipment
CN114217891A (en) * 2021-11-19 2022-03-22 建信金融科技有限责任公司 Page data conversion method and device, computer equipment and storage medium
CN114666674A (en) * 2020-12-23 2022-06-24 富泰华工业(深圳)有限公司 Subtitle information conversion method and device, electronic equipment and storage medium

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112783960A (en) * 2021-01-22 2021-05-11 北京澎思科技有限公司 Data processing system and method, electronic device, computer-readable storage medium
CN114816204B (en) * 2021-01-27 2024-01-26 北京猎户星空科技有限公司 Control method, control device, control equipment and storage medium of intelligent robot
CN112965772A (en) * 2021-03-02 2021-06-15 网易(杭州)网络有限公司 Web page display method and device and electronic equipment
CN113448753A (en) * 2021-06-24 2021-09-28 未鲲(上海)科技服务有限公司 Data processing method, computer equipment and readable storage medium
CN114491359A (en) * 2021-12-28 2022-05-13 北京航天智造科技发展有限公司 Webpage internationalization processing method and device
CN115098200A (en) * 2022-05-20 2022-09-23 北京快乐茄信息技术有限公司 Language switching method and device, electronic equipment and storage medium
CN117590980A (en) * 2023-04-28 2024-02-23 北京拉酷网络科技有限公司 Cognitive interface, object processing method, object processing system, object processing device and cloud computing platform
CN116521572B (en) * 2023-07-03 2023-09-19 天津金城银行股份有限公司 Webpage script visual verification method, system, terminal equipment and storage medium
CN117421000B (en) * 2023-09-06 2024-06-04 北京饼干科技有限公司 Method, device, electronic equipment and storage medium for generating distribution webpage

Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1464438A (en) * 2002-06-18 2003-12-31 力捷电脑股份有限公司 Process for changing user interface language with no need to restart the application programs
US20090031212A1 (en) * 2007-07-23 2009-01-29 Arcadyan Technology Corporation Embedded system with web-based user interface, firmware structure thereof and method for providing information thereof
EP2058734A1 (en) * 2007-11-06 2009-05-13 Sercomm Corporation Multi-language interfaces switch system and method therefore
CN102456041A (en) * 2010-10-29 2012-05-16 金蝶软件(中国)有限公司 Webpage language switching method and device as well as network application system
CN102567384A (en) * 2010-12-29 2012-07-11 盛乐信息技术(上海)有限公司 Webpage multi-language dynamic switching method and system based on webpage browser engine
CN103399847A (en) * 2012-05-31 2013-11-20 微软公司 Application language library for managing computing environment language
CN104462074A (en) * 2014-12-26 2015-03-25 北京奇虎科技有限公司 Method and device for conducting webpage data translation and browser client side
CN104881406A (en) * 2015-06-15 2015-09-02 携程计算机技术(上海)有限公司 Web page translation method and system
CN105183724A (en) * 2015-09-30 2015-12-23 北京奇虎科技有限公司 Translation method and electronic device
CN107256234A (en) * 2017-05-18 2017-10-17 腾讯科技(深圳)有限公司 A kind of web page text method of adjustment and its equipment
CN107958251A (en) * 2017-11-16 2018-04-24 维沃移动通信有限公司 A kind of amount of currency conversion method, device and mobile terminal
CN109669741A (en) * 2018-09-26 2019-04-23 深圳壹账通智能科技有限公司 Language switching method, server and the storage medium of terminal applies dynamic official documents and correspondence

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130262078A1 (en) * 2012-03-30 2013-10-03 George Gleadall System and method for providing text content on web pages in multiple human languages
CN105183725A (en) * 2015-09-30 2015-12-23 北京奇虎科技有限公司 Method for translating word on web page and electronic device
CN105740239A (en) * 2016-02-01 2016-07-06 中译语通科技(北京)有限公司 Translation method and system of character on webpage
CN110362370B (en) * 2019-06-14 2022-10-18 平安科技(深圳)有限公司 Webpage language switching method and device and terminal equipment

Patent Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1464438A (en) * 2002-06-18 2003-12-31 力捷电脑股份有限公司 Process for changing user interface language with no need to restart the application programs
US20090031212A1 (en) * 2007-07-23 2009-01-29 Arcadyan Technology Corporation Embedded system with web-based user interface, firmware structure thereof and method for providing information thereof
EP2058734A1 (en) * 2007-11-06 2009-05-13 Sercomm Corporation Multi-language interfaces switch system and method therefore
CN102456041A (en) * 2010-10-29 2012-05-16 金蝶软件(中国)有限公司 Webpage language switching method and device as well as network application system
CN102567384A (en) * 2010-12-29 2012-07-11 盛乐信息技术(上海)有限公司 Webpage multi-language dynamic switching method and system based on webpage browser engine
CN103399847A (en) * 2012-05-31 2013-11-20 微软公司 Application language library for managing computing environment language
CN104462074A (en) * 2014-12-26 2015-03-25 北京奇虎科技有限公司 Method and device for conducting webpage data translation and browser client side
CN104881406A (en) * 2015-06-15 2015-09-02 携程计算机技术(上海)有限公司 Web page translation method and system
CN105183724A (en) * 2015-09-30 2015-12-23 北京奇虎科技有限公司 Translation method and electronic device
CN107256234A (en) * 2017-05-18 2017-10-17 腾讯科技(深圳)有限公司 A kind of web page text method of adjustment and its equipment
CN107958251A (en) * 2017-11-16 2018-04-24 维沃移动通信有限公司 A kind of amount of currency conversion method, device and mobile terminal
CN109669741A (en) * 2018-09-26 2019-04-23 深圳壹账通智能科技有限公司 Language switching method, server and the storage medium of terminal applies dynamic official documents and correspondence

Cited By (16)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2020248849A1 (en) * 2019-06-14 2020-12-17 平安科技(深圳)有限公司 Webpage language switching method and apparatus, and terminal device
CN110795192A (en) * 2019-10-29 2020-02-14 青岛海信传媒网络技术有限公司 Language switching method and device and terminal equipment
CN110795192B (en) * 2019-10-29 2023-08-25 Vidaa(荷兰)国际控股有限公司 Language switching method and device and terminal equipment
CN111124406A (en) * 2019-12-10 2020-05-08 东软集团股份有限公司 Static page language switching method and device, storage medium and electronic equipment
CN111061533A (en) * 2019-12-18 2020-04-24 深圳前海环融联易信息科技服务有限公司 Page multi-language display method and device, electronic equipment and computer storage medium
CN111767104A (en) * 2020-05-07 2020-10-13 北京奇艺世纪科技有限公司 Language type switching method and device, computer equipment and storage medium
CN111767104B (en) * 2020-05-07 2023-09-01 北京奇艺世纪科技有限公司 Language type switching method and device, computer equipment and storage medium
CN111857906A (en) * 2020-06-03 2020-10-30 北京旷视科技有限公司 Text display method, device and system of terminal and storage medium
CN111859087A (en) * 2020-07-23 2020-10-30 北京好扑信息科技有限公司 Block chain-based government affair announcement publishing system
CN112068912A (en) * 2020-08-18 2020-12-11 深圳传音控股股份有限公司 System language type switching method, terminal and computer storage medium
CN114666674A (en) * 2020-12-23 2022-06-24 富泰华工业(深圳)有限公司 Subtitle information conversion method and device, electronic equipment and storage medium
CN112596841A (en) * 2020-12-24 2021-04-02 厦门亿联网络技术股份有限公司 Interface language switching method, device, equipment and storage medium
CN112596841B (en) * 2020-12-24 2022-08-12 厦门亿联网络技术股份有限公司 Interface language switching method, device, equipment and storage medium
CN112817655A (en) * 2021-01-29 2021-05-18 北京达佳互联信息技术有限公司 Document information processing method, device, storage medium and electronic equipment
CN112817655B (en) * 2021-01-29 2024-05-14 北京达佳互联信息技术有限公司 Document information processing method and device, storage medium and electronic equipment
CN114217891A (en) * 2021-11-19 2022-03-22 建信金融科技有限责任公司 Page data conversion method and device, computer equipment and storage medium

Also Published As

Publication number Publication date
CN110362370B (en) 2022-10-18
WO2020248849A1 (en) 2020-12-17

Similar Documents

Publication Publication Date Title
CN110362370A (en) A kind of switching method of homepages language, device and terminal device
US8051080B2 (en) Contextual ranking of keywords using click data
US8898583B2 (en) Systems and methods for providing information regarding semantic entities included in a page of content
CN101124609B (en) Search systems and methods using in-line contextual queries
KR100849272B1 (en) Method for automatically summarizing Markup-type documents
CN107784092A (en) A kind of method, server and computer-readable medium for recommending hot word
US20130110839A1 (en) Constructing an analysis of a document
US20130060769A1 (en) System and method for identifying social media interactions
US20110173174A1 (en) Linguistically enhanced search engine and meta-search engine
US8359307B2 (en) Method and apparatus for building sales tools by mining data from websites
CN104412212A (en) Input method editor
CN103210387B (en) Conjunctive word calling mechanism, information processor, conjunctive word register method and conjunctive word register system
CN106687949A (en) Search results for native applications
CN107193892B (en) A kind of document subject matter determines method and device
WO2008089372A1 (en) Context based search and document retrieval
CN109933708A (en) Information retrieval method, device, storage medium and computer equipment
WO2012061076A1 (en) Search method, apparatus and server for online trading platform
CN110489032B (en) Dictionary query method for electronic book and electronic equipment
CN110750707A (en) Keyword recommendation method and device and electronic equipment
CN107995098A (en) Information-pushing method and device
EP2189917A1 (en) Facilitating display of an interactive and dynamic cloud with advertising and domain features
CN108470289B (en) Virtual article issuing method and equipment based on E-commerce shopping platform
CN114357335A (en) Information acquisition method, medium, device and computing equipment
Mathur et al. Machine-Learning directed Article Detection on the Web using DOM and text-based features
WO2023146585A1 (en) Flexibly identifying and playing media content from any webpage

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant