Method and device for guiding login through QQ in browser

Through the information interaction between the client and the web server, the use of QQ account information to realize quick login in the browser, solving the problem of the inability to achieve quick login in the existing technology and improving the user experience.

CN120151009APending Publication Date: 2025-06-13SHANGHAI 2345 NETWORK TECH
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202510266762.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-07
Publication Date
2025-06-13

AI Technical Summary

Technical Problem

In the prior art, it is impossible to achieve quick login through third-party account information, resulting in poor user experience.

Method used

Through the information interaction between the client and the web server, use QQ account information to achieve quick login in the browser. The specific steps include obtaining judgment information, detecting the QQ login account, and guiding the QQ login pop-up window according to the conditions prompts.

Benefits of technology

It realizes quick login through third-party account information, improving user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120151009A_ABST
    Figure CN120151009A_ABST
Patent Text Reader

Abstract

The invention provides a method and device for guiding login in a browser through QQ. The method specifically comprises the steps that S1, the browser is started; s2, acquiring information used for judging whether QQ login needs to be detected or not, and transmitting the information to a web server; s3, the web server receives the information used for judging whether the QQ login needs to be detected or not, and returns first information; step S4, the web server transmits the first information to the client; step S5, the client receives the first information, and judges whether detection QQ login needs to be started or not according to the first information; if so, executing the step S6, otherwise, ending; step S6, starting to detect a QQ login account; and S7, judging whether to prompt to guide the QQ to log in the popup window or not, if not, executing the step S6, and otherwise, ending. The quick login of the website is realized through the QQ account, and the user experience is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer technology, and particularly to a method and device for guiding login with QQ in a browser. Background Art

[0002] Under the background of the rapid development of Internet applications, third-party account login (such as QQ, WeChat, Weibo, etc.) has become one of the core technical means to improve the efficiency of user registration and login. Especially in the browser environment, third-party login can not only simplify the user operation process, but also enhance the user's sense of security on the platform through the trust endorsement of social accounts.

[0003] However, in the existing browser, during the process of logging in to the website of most accounts through a third-party account, the user experience is poor. Summary of the Invention

[0004] The present invention provides a method and device for guiding login with QQ in a browser to solve the problem in the prior art that quick login cannot be achieved through third-party account information.

[0005] In the first aspect, the present invention provides a method for guiding login with QQ in a browser, specifically including the following steps:

[0006] Step S1: Start the browser through the client;

[0007] Step S2: Obtain the information for judging whether to detect QQ login, and transmit the information to the web server;

[0008] Step S3: The web server receives the information for judging whether to detect QQ login and returns the first information;

[0009] Step S4: The web server transmits the first information to the client;

[0010] Step S5: The client receives the first information, and judges whether to start detecting QQ login according to the first information; if so, execute Step S6, otherwise, end;

[0011] Step S6: Start detecting the QQ login account;

[0012] Step S7: Judge whether to prompt the QQ login pop-up window for guidance; if not, execute Step S6, otherwise, end.

[0013] Preferably, in Step S2, the information for judging whether to detect QQ login includes:

[0014] A1) The time of the last QQ login pop-up window for guidance;

[0015] A2) Number of times to guide the QQ login pop-up window;

[0016] A3) Whether there is a login record;

[0017] A4) Browser installation time.

[0018] Preferably, in step S3, the first information includes:

[0019] B1) Whether to detect QQ login;

[0020] B2) Time interval between the guidance pop-up window and the last user logout;

[0021] B3) Waiting time for the browser to start detecting QQ login;

[0022] B4) Basic time interval value for detecting QQ login.

[0023] Preferably, after the browser starts, if the server configuration issues an order to start detecting QQ login and no guidance QQ login pop-up window is prompted, then after intervals of t, 2t, 4t, 8t, 16t, start detecting QQ login again. If no guidance QQ login pop-up window is still prompted, then detect at an interval of 16t until a guidance QQ login pop-up window is prompted; where t represents the period of the content issued by the web server.

[0024] Preferably, step S6 specifically includes the following steps:

[0025] Step S601: Determine whether it is the detection time. If it is the detection time, then execute step S602;

[0026] Step S602: Determine whether the user has logged in. If the user has not logged in, then execute step S603; otherwise, continue the next detection;

[0027] Step S603: Determine whether the user's last logout time exceeds the specified number of days by the server. If it does not exceed the specified number of days by the server, then execute step S604; otherwise, continue the next detection;

[0028] Step S604: Determine whether the QQ process exists. If it exists, then execute step S605; otherwise, continue the next detection;

[0029] Step S605: Start detecting QQ account information;

[0030] Step S606: Determine whether a QQ account has been detected. If a QQ account has been detected, then execute step S607; otherwise, continue the next detection;

[0031] Step S607: Determine whether the registration and login dialog box already exists. If it does not exist, execute Step S608; otherwise, continue the next detection.

[0032] Step S608: Determine whether the current browser window is in the minimized state. If the current browser window is not in the minimized state, prompt to guide the QQ login pop-up window; otherwise, continue the next detection.

[0033] Preferably, Step S605 specifically includes the following steps:

[0034] Step S605a: Access the QQ login page. After the page is loaded, obtain the HTML source file of the QQ login page.

[0035] Step S605b: Parse the HTML source file and judge the element nodes in the span tag of the HTML source file.

[0036] Step S605c: When there is an element node class = uin in the span tag, obtain the logged-in QQ account (i.e., detect the QQ account).

[0037] Preferably, in Step S605c, the logged-in QQ account is obtained through regular rules.

[0038] More preferably, the regular rule is <span class="uin">(\d+) , and the rule is obtained from the list.

[0039] More preferably, the content of the list is specifically expressed as follows:

[0040] "guide_qq_login":{

[0041] "detect_qq_rules":

[0042] " <span class=\"uin\">(\\d+) "

[0044] }。

[0045] In a second aspect, the present invention also provides a device for guiding QQ login in a browser, specifically including the following modules:

[0046] The first module is used to start the browser through the client;

[0047] The second module is used to obtain the information for judging whether it is necessary to detect QQ login and transmit the information to the web server;

[0048] ​The third module is used for the web server to receive the information for determining whether to detect QQ login and return the first information;

[0049] The fourth module is used for the web server to transmit the first information to the client;

[0050] The fifth module is used for the client to receive the first information and determine whether to start detecting QQ login according to the first information; if so, execute the sixth module, otherwise, end;

[0051] The sixth module is used to start detecting the QQ login account;

[0052] The seventh module is used to determine whether to prompt the QQ login pop-up window. If there is no prompt for the QQ login pop-up window, execute the sixth module, otherwise, end.

[0053] Preferably, in the second module, the information for determining whether to detect QQ login includes:

[0054] A1) The time of the last prompt for the QQ login pop-up window;

[0055] A2) The number of times of prompting the QQ login pop-up window;

[0056] A3) Whether there is a login record;

[0057] A4) The browser installation time.

[0058] Preferably, in the third module, the first information includes:

[0059] B1) Whether to detect QQ login;

[0060] B2) The time interval between the pop-up window prompt and the last user logout;

[0061] B3) The waiting time for the browser to start detecting QQ login;

[0062] B4) The basic time interval value for detecting QQ login.

[0063] Preferably, after the browser starts, if the server configuration issues an order to start detecting QQ login and there is no prompt for the QQ login pop-up window, after intervals of t, 2t, 4t, 8t, 16t, start detecting QQ login again. If there is still no prompt for the QQ login pop-up window, detect at an interval of 16t until a prompt for the QQ login pop-up window appears; where t represents the cycle of the content issued by the web server.

[0064] Preferably, the sixth module specifically includes the following sub-modules:

[0065] The first sub-module is used to determine whether it is the detection time. If it is the detection time, the second sub-module is executed;

[0066] The second sub-module is used to determine whether the user has logged in. If the user has not logged in, the third sub-module is executed; otherwise, the next detection is continued;

[0067] The third sub-module is used to determine whether the user's last logout time exceeds the specified number of days of the server. If it does not exceed the specified number of days of the server, the fourth sub-module is executed; otherwise, the next detection is continued;

[0068] The fourth sub-module is used to determine whether the QQ process exists. If it exists, the fifth sub-module is executed; otherwise, the next detection is continued;

[0069] The fifth sub-module is used to start detecting QQ account information;

[0070] The sixth sub-module is used to determine whether a QQ account has been detected. If a QQ account has been detected, the seventh sub-module is executed; otherwise, the next detection is continued;

[0071] The seventh sub-module is used to determine whether the registration and login dialog box already exists. If the registration and login dialog box does not exist, the eighth sub-module is executed; otherwise, the next detection is continued;

[0072] The eighth sub-module is used to determine whether the current browser window is in the minimized state. If the current browser window is not in the minimized state, a prompt to guide the QQ login pop-up window is given; otherwise, the next detection is continued.

[0073] Preferably, the fifth sub-module specifically includes the following units:

[0074] The first unit is used to access the QQ login page. After the page loading is completed, the HTML source file of the QQ login page is obtained;

[0075] The second unit is used to parse the HTML source file and judge the element nodes in the span tag of the HTML source file;

[0076] The third unit is used to obtain the logged-in QQ account when there is an element node class=uin in the span tag.

[0077] Preferably, in the third unit, the logged-in QQ account is obtained through a regular rule.

[0078] More preferably, the regular rule is <span class="uin">(\d+) , and the rule is obtained from the list.

[0079] More preferably, the content of the list is specifically expressed as follows:

[0080] "guide_qq_login":{

[0081] "detect_qq_rules":

[0082] " <span class=\"uin\">(\\d+) "

[0084] }。

[0085] In a third aspect, the present invention also provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, it implements a method for guiding QQ login in a browser as described in any one of the first aspects of the present application.

[0086] In a fourth aspect, the present invention also provides an electronic device, which includes: a memory storing a computer program; a processor communicatively connected to the memory and, when calling the computer program, executing a method for guiding QQ login in a browser as described in any one of the first aspects of the present application.

[0087] Compared with the prior art, the present invention has the following obvious outstanding substantial features and remarkable advantages:

[0088] The present invention provides a method and device for guiding QQ login in a browser, which solves the problem in the prior art that it is impossible to achieve fast login through third-party account information. Through the information interaction between the client and the web server, fast login to the website is achieved through the QQ account, improving the user experience. BRIEF DESCRIPTION OF THE DRAWINGS

[0089] The accompanying drawings forming a part of the present invention are used to provide a further understanding of the present invention. The schematic embodiments and descriptions thereof of the present invention are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:

[0090] Figure 1 is a flowchart of a method for guiding QQ login in a browser according to a preferred embodiment of the present invention.

[0091] Figure 2 is a flowchart of detecting a QQ login account according to a preferred embodiment of the present invention.

[0092] Figure 3 is a UML class diagram according to a preferred embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0093] ​The present invention provides a method and device for guiding login with QQ in a browser. To make the objectives, technical solutions and effects of the present invention clearer and more definite, the following further elaborates on the present invention with reference to the accompanying drawings and by way of examples. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.

[0094] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects and do not necessarily need to describe a specific order or sequence. It should be understood that such data used in appropriate cases can be interchanged. In addition, the terms "include" and "have" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product or device that includes a series of steps or units does not necessarily have to be limited to those steps or units clearly listed, but may include other steps or units not clearly listed or inherent to these processes, methods, products or devices.

[0095] Example 1:

[0096] As Figure 1 shown, a method for guiding login with QQ in a browser described in this embodiment specifically includes the following steps:

[0097] Step S1: Start the browser through the client.

[0098] Step S2: Obtain information for determining whether QQ login needs to be detected, and transmit the information (also referred to as the request reporting field) to the web server through the check_version interface.

[0099] Table 1 Request Reporting Field Table

[0100]

[0101]

[0102] As shown in Table 1, the request reporting fields include: the time of the last guided QQ login pop-up window guide_qq_login_bubble_last_show_timestamp, the number of times of the guided QQ login pop-up window guide_qq_login_bubble_show_count, whether there is a login record is_login_record_exist, and the browser installation time guide_qq_login_base_timestamp; among them, the request reporting field types include three types: Int64, Int, and Bool.

[0103] Step S3: The web server receives the information for determining whether to detect QQ login and returns the first information.

[0104] Table 2 First Information Table

[0105]

[0106] As shown in Table 2, the first information includes: whether to detect QQ login is_enable_detect_qq_login, the time interval since the last user exit for the guiding pop-up window show_bubble_interval_days, the waiting time for the browser to start detecting QQ login start_detect_qq_seconds, and the basic time interval value for detecting QQ login detect_qq_login_interval_minutes; among them, the first information types are Bool and Int.

[0107] Step S4: The web server transmits the first information to the client.

[0108] Step S5: The client receives the first information and determines whether to start detecting QQ login according to the first information; if so, execute Step S6, otherwise, end.

[0109] Step S6: Start detecting the QQ login account.

[0110] After the browser starts, if the server configuration issues an order to start detecting QQ login and the guiding QQ login pop-up window is not prompted, then after intervals of t, 2t, 4t, 8t, 16t, start detecting QQ login again. If the guiding QQ login pop-up window is still not prompted, then detect at an interval of 16t until the guiding QQ login pop-up window is prompted; where t represents the cycle of the content issued by the web server.

[0111] Among them, as Figure 2 shown, Step S6 specifically includes Step S601 - Step S608.

[0112] Step S601: Determine whether it is the detection time. If it is the detection time, then execute Step S602.

[0113] Step S602: Determine whether the user has logged in. If the user has not logged in, then execute Step S603, otherwise, continue the next detection.

[0114] Step S603: Determine whether the user's last exit time exceeds the specified number of days by the server. If it does not exceed the specified number of days by the server, then execute Step S604, otherwise, continue the next detection.

[0115] Step S604: Determine whether the QQ process exists. If it exists, execute Step S605; otherwise, continue with the next detection.

[0116] Step S605: Start detecting QQ account information; specifically, it includes the following steps:

[0117] Step S605a: Access the QQ login page. After the page loading is completed, obtain the HTML source file of the QQ login page.

[0118] Step S605b: Parse the HTML source file and judge the element nodes in the span tag of the HTML source file.

[0119] Step S605c: When there is an element node class="uin" in the span tag, obtain the logged-in QQ account (i.e., detect the QQ account); for example: the QQ login page is https: / / graph.qq.com / oauth2.0 / show?which=Login&display=pc&client_id=100258531&forcelogin=true&redirect_uri=https%3A%2F%2Flogin.2345.com%2Fclientapi%2Fqq%2Fcallback%3Fmid%3Dpcbs%26autoLogin%3D1&response_type=code&state=5716c4794cee9904333d1724e2582d59. By parsing the HTML source file of the above QQ login page, the logged-in QQ account can be obtained.

[0120] Among them, the logged-in QQ account is obtained through a regular rule. More preferably, the regular rule is (\d+), and the rule is obtained from the list. The content of the list is specifically as follows:

[0121] "guide_qq_login":{

[0122] "detect_qq_rules":

[0123] " <span class=\"uin\">(\\d+) "

[0125] }。

[0126] Step S606: Determine whether a QQ account has been detected. If a QQ account has been detected, execute Step S607; otherwise, continue with the next detection.

[0127] ​Step S607: Determine whether the registration and login dialog box already exists. If it does not exist, execute Step S608; otherwise, continue with the next detection.

[0128] Step S608: Determine whether the current browser window is in the minimized state. If the current browser window is not in the minimized state, prompt to display the QQ login pop-up window; otherwise, continue with the next detection.

[0129] Among them, the QQ login pop-up window obtains the user's QQ account avatar information according to a fixed parameter link, for example: http: / / q1.qlogo.cn / g?b=qq&nk=1095627256&s=100&t=1487642103; where nk represents the user's QQ account information, that is, 1095627256 represents the QQ account; s represents the size of the obtained account avatar picture, s = 100 means the size of the avatar picture is 100*100, and the size of the avatar picture can also be modified according to the actual application scenario (the default size of the avatar picture is 100*100); t represents the timestamp, that is, 1487642103 represents the timestamp.

[0130] Step S7: Determine whether to prompt to display the QQ login pop-up window. If there is no prompt to display the QQ login pop-up window, execute Step S6; otherwise, end.

[0131] In this embodiment, the life cycle of detecting the QQ login service is as follows:

[0132] The time point of service creation is to create a singleton object for detecting the QQ login service during the browser startup process; the time point of service destruction is any one or more of the following three situations, specifically including:

[0133] The first situation: When the web side returns not to execute the QQ account service, destroy the service;

[0134] The second situation: When successfully detecting and prompting to display the QQ login pop-up window, destroy the service;

[0135] The third situation: When the QQ login pop-up window is not prompted and the browser is closed, destroy the service.

[0136] Such as Figure 3As shown, it is the UML class diagram of this embodiment. UML: the abbreviation of Unified Modeling Language, which is a standardized modeling language composed of a complete set of diagrams. UML is used to help system developers clarify, display, construct, and record the outputs of software systems. A class diagram is a diagram that describes classes, interfaces, collaborations, and the relationships between them, and is used to show the static structure of these concepts in a system. The class diagram is also the basis for other diagrams. Based on the class diagram, we can use state diagrams, collaboration diagrams, component diagrams, and configuration diagrams, etc. As Figure 3 shown, the DetectQQLogin class is the core business logic class, mainly responsible for the code related to detecting the QQ login business logic. Such as judging whether the user has logged in, whether to start detecting QQ account information, and whether to prompt a guiding pop-up window, etc. The DetectQQLoginHelper class is the actual class for detecting QQ account information, mainly used to load the page to be detected, obtain the html source file, capture all QQ accounts according to regular rules, and based on the obtained QQ accounts, splice the url (link) for obtaining the QQ account avatar, and finally notify the DetectQQLogin class of the avatar url information through the DetectQQLoginHelperDelegate.

[0137] The specific embodiments of the present invention have been described in detail above, but they are only examples, and the present invention is not limited to the specific embodiments described above. For those skilled in the art, any equivalent modifications and substitutions to the present invention are also within the scope of the present invention. Therefore, all equivalent transformations and modifications made without departing from the spirit and scope of the present invention should be covered within the scope of the present invention.

Claims

1. A method for guiding login using QQ in a browser, characterized in that: The specific steps include: Step S1, starting a browser through a client; Step S2: obtaining information for determining whether QQ login detection is required, and transmitting the information to a web server; Step S3, the web server receives the information for determining whether QQ login detection is required, and returns the first information; Step S4: the web server transmits the first information to the client; Step S5: The client receives the first information and determines whether to enable QQ login detection according to the first information; If necessary, execute step S6, otherwise, end; Step S6, start detecting QQ login accounts; Step S7, determine whether a pop-up window for guiding QQ login is displayed. If no pop-up window for guiding QQ login is displayed, execute step S6, otherwise, end.

2. A method for guiding login using QQ in a browser according to claim 1, characterized in that: In step S2, the information used to determine whether QQ login detection is required includes: A1) The time when the QQ login pop-up window was last displayed; A2) The number of pop-up windows that prompted QQ login; A3) Whether there is a login record; A4) Browser installation time.

3. A method for guiding login using QQ in a browser according to claim 1, characterized in that: In step S3, the first information includes: B1) Whether to detect QQ login; B2) The time interval between the last time the user exited the pop-up window; B3) The waiting time for the browser to start detecting QQ login; B4) Basic time interval value for detecting QQ login.

4. A method for guiding login using QQ in a browser according to claim 1, characterized in that: When the browser is started, if the server configures and sends a message to start detecting QQ login, if no pop-up window is displayed to guide QQ login, then after intervals of t, 2t, 4t, 8t, and 16t, start detecting QQ login again. If no pop-up window is displayed to guide QQ login, then detect again at intervals of 16t until a pop-up window is displayed to guide QQ login; where t represents the period for the web server to send content.

5. A method for guiding login using QQ in a browser according to claim 1, characterized in that: The step S6 specifically includes the following steps: Step S601, determine whether the detection time has arrived, if the detection time has arrived, execute step S602; Step S602: determine whether the user has logged in. If the user has not logged in, execute step S603. Otherwise, continue with the next detection. Step S603: determine whether the user's last logout time exceeds the server-specified number of days. If not, execute step S604. Otherwise, continue with the next detection. Step S604: determine whether the QQ process exists. If so, execute step S605. Otherwise, continue to the next detection. Step S605, start detecting QQ account information; Step S606: determine whether a QQ account is detected. If a QQ account is detected, execute step S607. Otherwise, continue to the next detection. Step S607, determine whether the registration and login dialog box already exists, if the registration and login dialog box does not exist, execute step S608, otherwise, continue to the next detection; Step S608, determine whether the current browser window is in a minimized state. If the current browser window is not in a minimized state, a pop-up window will be prompted to guide the QQ login. Otherwise, continue the next detection.

6. A method for guiding login using QQ in a browser according to claim 1, characterized in that: The step S605 specifically includes the following steps: Step S605a: access the QQ login page, and after the page is loaded, obtain the HTML source file of the QQ login page; Step S605b, parsing the HTML source file, and determining the element nodes in the span tags in the HTML source file; Step S605c: when the element node class=uin exists in the span tag, the logged-in QQ account is obtained.

7. A method for guiding login using QQ in a browser according to claim 1, characterized in that: In step S605c, the logged-in QQ account is obtained through regular rules; The regular rule is <span class="uin">(\d+) , the rules are obtained from the list; The contents of the list are as follows: "guide_qq_login":{ "detect_qq_rules":[ " <span class=\"uin\">(\\d+) " ] }。 8. A device for guiding login using QQ in a browser, characterized in that: The modules include: The first module is used to start the browser through the client; The second module is used to obtain information for determining whether QQ login detection is required, and transmit the information to the web server; The third module is used for the web server to receive the information used to determine whether QQ login detection is required and return the first information; A fourth module is used for the web server to transmit the first information to the client; The fifth module is used for the client to receive the first information and determine whether to enable QQ login detection according to the first information; If necessary, execute the sixth module, otherwise, end; The sixth module is used to start detecting QQ login accounts; The seventh module is used to determine whether to prompt the QQ login pop-up window. If there is no prompt to guide the QQ login pop-up window, the sixth module is executed, otherwise, the process ends.

9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method for guiding login using QQ in a browser as described in any one of claims 1 to 7 is implemented.

10. An electronic device, characterized in that: The method comprises a memory, a processor and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, a method for guiding login in a browser using QQ is implemented as described in any one of claims 1 to 7.

Citation Information

Cited By

  • Method and apparatus for QQ-based login guidance in browser

    WO2026184141A1