Page detection method, device and equipment, and storage medium

CN116775193BActive Publication Date: 2026-11-03CHINA PING AN PROPERTY INSURANCE CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310743356.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-06-21
Publication Date
2026-11-03
Estimated Expiration
2043-06-21

AI Technical Summary

Technical Problem

Existing page detection methods have poor versatility, resulting in low accuracy in page detection across different front-end pages in the financial sector.

Method used

By acquiring node information of the displayed page, page detection results are generated, including different detection logics for skeleton screen pages and non-skeleton screen pages. Using the first node information, second node information, and third node information, page content changes and node types are determined at different query times to generate accurate page detection results.

Benefits of technology

It improves the accuracy of page detection, is compatible with different front-end pages, and ensures timely generation of detection results even in the case of a blank screen.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116775193B_ABST
    Figure CN116775193B_ABST
Patent Text Reader

Abstract

The application provides a page detection method, device and equipment and a storage medium. The method comprises the following steps: obtaining a loaded display page; in the case that the display page is a skeleton screen page, generating a page detection result corresponding to the display page according to first node information corresponding to the display page and second node information corresponding to the display page at each query time; and in the case that the display page is not a skeleton screen page, generating the page detection result corresponding to the display page according to third node information corresponding to the display page at each query time. In the embodiment of the application, different display pages are detected by different methods, and the page detection result is generated. Therefore, the page detection method provided by the application can be compatible with different front-end pages, and the accuracy of page detection is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of financial technology, and in particular to a page detection method, apparatus, device, and storage medium. Background Technology

[0002] With the rapid development of computer technology and the widespread use of computer devices, more and more users are browsing financial news, searching for financial information, and watching financial videos on web pages. However, due to network lag, page malfunctions, and other reasons, a blank screen phenomenon can easily occur, meaning the page does not display any content for a period of time. For page developers, if they cannot accurately detect and fix page blank screens, they will lose a large number of online users.

[0003] However, the page detection methods involved in the relevant technologies have poor versatility and are not well compatible with different front-end pages in the financial sector, which leads to low accuracy in page detection. Summary of the Invention

[0004] The main objective of this invention is to provide a page detection method, apparatus, device, and storage medium, aiming to solve the technical problem of low accuracy in page detection.

[0005] To achieve the above objectives, the present invention provides a page detection method, the method comprising: Get the page that is displayed after loading is complete; When the displayed page is a skeleton screen page, a page detection result corresponding to the displayed page is generated based on the first node information corresponding to the displayed page and the second node information corresponding to the displayed page at each query time. The first node information and the second node information are both used to characterize the array of element nodes included by N preset coordinate points in the displayed page. The first node information is the array of element nodes included by the N preset coordinate points at the initial time, and N is a positive integer greater than 1. If the displayed page is not a skeleton screen page, a page detection result corresponding to the displayed page is generated based on the third node information corresponding to the displayed page at each query time. The third node information is used to characterize the node type of the element nodes included by the N preset coordinate points.

[0006] Optionally, generating the page detection result corresponding to the display page based on the first node information corresponding to the display page and the second node information corresponding to the display page at each query time includes: Based on the second node information and the first node information corresponding to the current query time on the display page, determine whether the element node array included by the N preset coordinate points in the display page has changed; When the array of element nodes included in the N preset coordinate points changes, a first detection result is generated, wherein the first detection result is used to characterize that the display page is not in a white screen state; If the array of element nodes included in the N preset coordinate points remains unchanged, a first operation is performed based on the query duration corresponding to the current query time, wherein the first operation includes any one of the following: Generate a second detection result, wherein the second detection result is used to characterize that the display page is in a white screen state; or Based on the first node information corresponding to the displayed page and the second node information corresponding to the displayed page at the next query time of the current query time, a page detection result corresponding to the displayed page is generated.

[0007] Optionally, before the step of generating the first detection result when the array of element nodes included in the N preset coordinate points changes, the method further includes: If the element node array represented by the second node information is different from the element node array represented by the first node information, it is determined that the element node array included in the N preset coordinate points has changed. If the element node array represented by the second node information is the same as the element node array represented by the first node information, it is determined that the element node array included by the N preset coordinate points has not changed.

[0008] Optionally, performing the first operation based on the query duration corresponding to the current query time includes: If the query duration corresponding to the current query time exceeds a preset threshold, a second detection result is generated; If the query duration corresponding to the current query time does not exceed a preset threshold, a page detection result corresponding to the display page is generated based on the first node information corresponding to the display page and the second node information corresponding to the next query time of the display page at the current query time.

[0009] Optionally, generating the page detection result corresponding to the displayed page based on the third node information corresponding to the displayed page at each query time includes: Based on the third node information corresponding to the current query time on the display page, determine whether the N preset coordinate points in the display page include non-container nodes; If the N preset coordinate points include non-container nodes, a first detection result is generated; the first detection result is used to indicate that the display page is not in a white screen state. If the N preset coordinate points do not include non-container nodes, perform the second operation according to the query duration corresponding to the current query time; The second operation includes any one of the following: A second detection result is generated; the second detection result is used to characterize that the display page is in a white screen state. Based on the third node information corresponding to the next query time of the current query time, a page detection result corresponding to the display page is generated.

[0010] Optionally, before generating the first detection result when the N preset coordinate points include non-container nodes, the method further includes: When the node type represented by the third node information is a container node and a non-container node, N preset coordinate points are determined, including non-container nodes. When the node type represented by the third node information is a container node, N preset coordinate points are determined to exclude non-container nodes.

[0011] Optionally, the method for performing the second operation based on the query duration corresponding to the current query time includes: If the query duration corresponding to the current query time exceeds a preset threshold, a second detection result is generated; If the query duration corresponding to the current query time does not exceed a preset threshold, a page detection result corresponding to the display page is generated based on the third node information corresponding to the next query time of the current query time. Furthermore, to achieve the above objectives, the present invention also provides a page detection device, the device comprising: The retrieval module is used to retrieve the displayed page after loading is complete; The first generation module is used to generate a page detection result corresponding to the display page when the display page is a skeleton screen page, based on the first node information corresponding to the display page and the second node information corresponding to the display page at each query time. The first node information and the second node information are both used to characterize the element node array included by N preset coordinate points in the display page. The first node information is the element node array included by the N preset coordinate points at the initial time, and N is a positive integer greater than 1. The second generation module is used to generate a page detection result corresponding to the display page based on the third node information corresponding to the display page at each query time when the display page is not a skeleton screen page. The third node information is used to characterize the node type of the element nodes included by the N preset coordinate points.

[0012] To address the aforementioned technical problems, this application also provides a computer device that employs the following technical solution: The computer device includes a memory and a processor. The memory stores a computer program, and when the processor executes the computer program, it implements the steps of the page detection method proposed in any of the embodiments of this application.

[0013] To address the aforementioned technical problems, this application also provides a computer-readable storage medium, employing the technical solution described below: The computer-readable storage medium stores a computer program, which, when executed by a processor, implements the steps of the page detection method proposed in any of the embodiments of this application.

[0014] Compared with the prior art, the embodiments of this application have the following main advantages: This application proposes a page detection method, which includes: for a display page that is a skeleton screen page, generating a page detection result corresponding to the display page based on the first node information corresponding to the display page and the second node information corresponding to the display page at each query time; for a display page that is not a skeleton screen page, generating a page detection result corresponding to the display page based on the third node information corresponding to the display page at each query time. By performing page detection on the display page and generating page detection results in different ways for different front-end pages, the page detection method provided by this invention can be compatible with different front-end pages, thereby improving the accuracy of page detection. Attached Figure Description

[0015] To more clearly illustrate the solutions in this application, the accompanying drawings used in the description of the embodiments of this application will be briefly introduced below. Obviously, the accompanying drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0016] Figure 1 This is an exemplary system architecture diagram to which this application can be applied; Figure 2 This is a flowchart of the page detection method provided in the embodiments of the present invention; Figure 3 This is an application flowchart of the page detection method provided in the embodiments of the present invention; Figure 4 This is a schematic diagram of the structure of the page detection device provided in an embodiment of the present invention; Figure 5 This is a schematic diagram of the structure of one embodiment of the computer device according to this application. Detailed Implementation

[0017] The data format determination method provided in this invention is applied to a data processing system. Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein is for the purpose of describing specific embodiments only and is not intended to limit the application. The terms "comprising" and "having," and any variations thereof, in the specification, claims, and accompanying drawings of this application, are intended to cover non-exclusive inclusion. The terms "first," "second," etc., in the specification, claims, or accompanying drawings of this application are used to distinguish different objects, not to describe a specific order.

[0018] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.

[0019] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings.

[0020] like Figure 1 As shown, system architecture 100 may include terminal devices 101, 102, and 103, a network 104, and a server 105. Network 104 serves as the medium for providing communication links between terminal devices 101, 102, and 103 and server 105. Network 104 may include various connection types, such as wired or wireless communication links, or fiber optic cables, etc.

[0021] Users can use terminal devices 101, 102, and 103 to interact with server 105 via network 104 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 101, 102, and 103, such as web browser applications, shopping applications, search applications, instant messaging tools, email clients, and social online platform software.

[0022] Terminal devices 101, 102, and 103 can be various computer devices with displays and web browsing capabilities, including but not limited to smartphones, tablets, e-book readers, MP3 players (Moving Picture Experts Group Audio Layer III), MP4 players (Moving Picture Experts Group Audio Layer IV), laptops, and desktop computers, etc.

[0023] Server 105 can be a server that provides various services, such as a backend server that supports the pages displayed on terminal devices 101, 102, and 103.

[0024] It should be noted that the page detection method provided in this application embodiment is generally executed by a server / terminal device, and correspondingly, the page detection system is generally set in the server / terminal device.

[0025] It should be understood that Figure 1 The number of terminal devices, networks, and servers shown is merely illustrative. Depending on implementation needs, any number of terminal devices, networks, and servers can be included.

[0026] Continue to refer to Figure 2 The diagram illustrates a flowchart of an embodiment of the page detection method proposed in this application. This embodiment can acquire and process relevant data based on artificial intelligence technology. The page detection method includes the following steps: S210, retrieve the display page after loading is complete.

[0027] The above-mentioned display page is the front-end page after loading. Optionally, the above-mentioned front-end page may be a display page generated by the computer device in response to user operations.

[0028] S220, when the displayed page is a skeleton screen page, generate the page detection result corresponding to the displayed page based on the first node information corresponding to the displayed page and the second node information corresponding to the displayed page at each query time.

[0029] In one optional implementation, if the displayed page is a skeleton screen page, the first node information corresponding to the displayed page and the second node information corresponding to the displayed page at each query time can be obtained; then, based on the first node information and the second node information corresponding to each query time, a page detection result corresponding to the displayed page can be generated. For specific implementation details, please refer to subsequent embodiments.

[0030] It should be noted that if a blank page is displayed before the page has been fully rendered, this type of page can be identified as a skeleton screen page.

[0031] In this step, coordinate points to be observed can be pre-selected evenly on the display page, i.e., N preset coordinate points. The first node information and the second node information both represent the array of element nodes included in the aforementioned N preset coordinate points on the display page. The first node information is the array of element nodes included in the N preset coordinate points at the initial time, and the second node information is the array of element nodes included in the N preset coordinate points at the corresponding query time, where N is a positive integer greater than 1.

[0032] The aforementioned array of element nodes is also known as the DOM element array. In other words, the array of DOM elements included at N preset coordinate points at the initial moment can be used to determine the first node information. Optionally, the DOM element array contained at the preset coordinate points can be obtained using the `document.elementFromPoint` function.

[0033] S230, if the displayed page is not a skeleton screen page, generate the page detection result corresponding to the displayed page based on the third node information corresponding to the displayed page at each query time.

[0034] Another alternative implementation is that, if the displayed page is not a skeleton screen page, the third node information corresponding to the displayed page at each query time can be obtained, and the page detection result corresponding to the displayed page can be generated based on the aforementioned third node information. For specific implementation details, please refer to subsequent embodiments.

[0035] As described above, N preset coordinate points can be uniformly selected on the display page beforehand. Then, the node type of the element nodes included by these N preset coordinate points is determined as the third node information. In other words, this third node information is used to characterize the node type of the element nodes included by the N preset coordinate points on the display page, where N is a positive integer greater than 1.

[0036] In this embodiment of the invention, for a display page that is a skeleton screen page, a page detection result is generated based on the first node information corresponding to the display page and the second node information corresponding to the display page at each query time; for a display page that is not a skeleton screen page, a page detection result is generated based on the third node information corresponding to the display page at each query time. By performing page detection on different front-end pages and generating page detection results in different ways, the page detection method provided by this invention can be compatible with different front-end pages, thereby improving the accuracy of page detection.

[0037] Optionally, generating the page detection result corresponding to the display page based on the first node information corresponding to the display page and the second node information corresponding to the display page at each query time includes: Based on the second node information and the first node information corresponding to the current query time on the display page, determine whether the array of element nodes included in the N preset coordinate points on the display page has changed; If the array of element nodes included in the N preset coordinate points changes, a first detection result is generated; the first detection result is used to indicate that the display page is not in a white screen state. If the array of element nodes included in the N preset coordinate points remains unchanged, perform the first operation according to the query duration corresponding to the current query time; The first operation includes any one of the following: A second detection result is generated; the second detection result is used to characterize that the display page is in a white screen state. Based on the first node information corresponding to the displayed page and the second node information corresponding to the displayed page at the next query time of the current query time, a page detection result corresponding to the displayed page is generated.

[0038] In this embodiment, when the display page is a skeleton screen page, for each query time, it can be determined whether the array of element nodes included in the N preset coordinate points in the display page has changed based on the second node information and the first node information corresponding to the current query time. For a detailed implementation of how to determine whether the array of element nodes included in the N preset coordinate points in the display page has changed, please refer to the following embodiments.

[0039] If the array of element nodes included in the N preset coordinate points changes, it indicates that the content displayed on the page has changed, that is, the page is not a blank page at the current query time. Then, a first detection result is generated, wherein the first detection result is used to characterize that the page is not in a blank screen state.

[0040] If the array of element nodes included in the N preset coordinate points has not changed, it means that the displayed page is a blank page at the current query time. Then, the first operation is executed according to the query duration corresponding to the current query time.

[0041] Optionally, the query duration can be determined based on the number of queries at the current query time. For example, if the second node information corresponding to the displayed page is retrieved every second, and the number of queries at the current query time is 2, then the query duration at the current query time is 2 seconds.

[0042] The first operation mentioned above includes any one of the following: A second detection result is generated. This second detection result indicates that the displayed page is in a white screen state, i.e., a white screen is detected.

[0043] Based on the first node information corresponding to the displayed page and the second node information corresponding to the next query time of the displayed page at the current query time, a page detection result corresponding to the displayed page is generated. In this operation mode, the second node information corresponding to the next query time is obtained, and page detection is performed based on the second node information and the first node information corresponding to the next query time.

[0044] In this embodiment, when the displayed page is a skeleton screen, the second node information corresponding to the displayed page is obtained at different query times, and the second node information is compared with the first node information corresponding to the displayed page at the initial time to determine whether the displayed content of the displayed page has changed and generate a page detection result. By monitoring and comparing the displayed content of the displayed page at different times, the system can accurately detect whether the page is blank, thereby improving the accuracy of page detection.

[0045] The following explains in detail how to determine whether the array of element nodes included by N preset coordinate points on the display page has changed: Optionally, before generating the first detection result when the array of element nodes included in the N preset coordinate points changes, the method further includes: If the element node array represented by the second node information is different from the element node array represented by the first node information, it is determined that the element node array included in the N preset coordinate points has changed. If the element node array represented by the second node information is the same as the element node array represented by the first node information, it is determined that the element node array included by the N preset coordinate points has not changed.

[0046] In this embodiment, at the initial moment, data of the element node array included by N preset coordinate points on the display page is obtained and backed up. At the current query moment, data of the element node array included by N preset coordinate points on the display page is obtained, and the above data is determined as the second node information.

[0047] If the array of element nodes represented by the second node information is different from the array of element nodes represented by the first node information, then the array of element nodes included in the N preset coordinate points changes, that is, the content displayed on the page changes.

[0048] If the array of element nodes represented by the second node information is the same as the array of element nodes represented by the first node information, it is determined that the array of element nodes included by the N preset coordinate points has not changed, that is, the content displayed on the page has not changed.

[0049] Optionally, performing the first operation based on the query duration corresponding to the current query time includes: If the query duration corresponding to the current query time exceeds a preset threshold, a second detection result is generated; If the query duration corresponding to the current query time does not exceed a preset threshold, a page detection result corresponding to the display page is generated based on the first node information corresponding to the display page and the second node information corresponding to the next query time of the display page at the current query time.

[0050] In this embodiment, a preset threshold is set in advance. Optionally, the preset threshold is 10 seconds.

[0051] In this embodiment, the query duration corresponding to the current query time is determined. As mentioned above, the query duration corresponding to the current query time can be determined based on the number of queries corresponding to the current query time.

[0052] Compare the query duration corresponding to the current query time with the preset threshold. If the query duration corresponding to the current query time exceeds the preset threshold, it means that the page will be displayed as a blank page within the time period represented by the preset threshold, and then a second detection result is generated.

[0053] If the query duration at the current query time does not exceed the preset threshold, the system will continue to check whether the content displayed on the page has changed at the next query time.

[0054] In this embodiment, by judging the relationship between the query duration corresponding to the current query time and the preset threshold, a second detection result is generated when the query duration corresponding to the current query time exceeds the preset threshold. This ensures that the page detection result is generated in a timely manner and notified to the relevant developers when the page is blank.

[0055] Optionally, generating the page detection result corresponding to the displayed page based on the third node information corresponding to the displayed page at each query time includes: Based on the third node information corresponding to the current query time on the display page, determine whether the N preset coordinate points in the display page include non-container nodes; If the N preset coordinate points include non-container nodes, a first detection result is generated; the first detection result is used to indicate that the display page is not in a white screen state. If the N preset coordinate points do not include non-container nodes, perform the second operation according to the query duration corresponding to the current query time; The second operation includes any one of the following: A second detection result is generated; the second detection result is used to characterize that the display page is in a white screen state. Based on the third node information corresponding to the next query time of the current query time, a page detection result corresponding to the display page is generated.

[0056] In this embodiment, when the displayed page is not a skeleton screen page, for each query time, the node type of the element nodes included in the N preset coordinate points in the displayed page can be determined according to the third node information corresponding to the current query time of the displayed page, and then it can be determined whether the N preset coordinate points in the displayed page include non-container nodes.

[0057] It should be noted that for display pages that are not skeleton screens, the N preset coordinate points in the display page initially only include container nodes. If the N preset coordinate points in the display page include non-container nodes, it means that the display page is not a blank screen.

[0058] If the N preset coordinate points include non-container nodes, it indicates that the displayed page is not a blank page at the current query time, and a first detection result is generated. The first detection result is used to characterize that the displayed page is not in a blank screen state.

[0059] If the N preset coordinate points do not include non-container nodes, that is, if the N preset coordinate points only include container nodes, it means that the displayed page is a blank page at the current query time. Then, according to the query duration corresponding to the current query time, the second operation is executed.

[0060] The second operation mentioned above includes any one of the following: A second detection result is generated. This second detection result indicates that the displayed page is in a white screen state, i.e., a white screen is detected.

[0061] Based on the third node information corresponding to the next query time of the displayed page at the current query time, a page detection result corresponding to the displayed page is generated. In this operation mode, the third node information corresponding to the next query time is obtained again, and page detection is performed based on the third node information corresponding to the next query time.

[0062] In this embodiment, when the displayed page is not a skeleton screen, the third node information corresponding to the displayed page is obtained at different query times, and the display page is judged to be blank based on the node type represented by the third node. By monitoring and comparing the displayed content of the page at different times, the accuracy of page detection can be improved by accurately detecting whether the page is blank.

[0063] The following details how to determine whether N preset coordinate points on the displayed page include non-container nodes: Optionally, before generating the first detection result when the N preset coordinate points include non-container nodes, the method further includes: When the node type represented by the third node information is a container node and a non-container node, N preset coordinate points are determined, including non-container nodes. When the node type represented by the third node information is a container node, N preset coordinate points are determined to exclude non-container nodes.

[0064] As mentioned above, initially, the N preset coordinate points on the display page only include container nodes. If the N preset coordinate points on the display page include non-container nodes, it means that the display page is not a blank screen.

[0065] In this embodiment, when the node type represented by the third node information is a container node and a non-container node, it means that the N preset coordinate points in the display page include both container nodes and non-container nodes. In other words, the display page is not a blank screen.

[0066] If the node type represented by the third node information is a container node, it means that the N preset coordinate points in the display page only include container nodes. In other words, the display page is still a blank screen.

[0067] Optionally, the step of performing the second operation based on the query duration corresponding to the current query time includes: If the query duration corresponding to the current query time exceeds a preset threshold, a second detection result is generated; If the query duration corresponding to the current query time does not exceed a preset threshold, the page detection result corresponding to the display page is generated based on the third node information corresponding to the next query time of the current query time.

[0068] In this embodiment, the query duration corresponding to the current query time is compared with a preset threshold. If the query duration corresponding to the current query time exceeds the preset threshold, it indicates that the page is displayed as a blank screen within the time period represented by the preset threshold, and a second detection result is generated.

[0069] If the query duration at the current query time does not exceed the preset threshold, the system will continue to check whether the content displayed on the page has changed at the next query time.

[0070] In this embodiment, by judging the relationship between the query duration corresponding to the current query time and the preset threshold, a second detection result is generated when the query duration corresponding to the current query time exceeds the preset threshold. This ensures that the page detection result is generated in a timely manner and notified to the relevant developers when the page is blank.

[0071] For a better understanding of the overall technical solution, please refer to [link / reference]. Figure 3 ,like Figure 3 As shown, after the page loads, it is determined whether the displayed page is a skeleton screen page. If the displayed page is a skeleton screen page, the first node information corresponding to the displayed page at the initial moment is backed up. Furthermore, at each query moment, it is determined whether the displayed content of the displayed page has changed, that is, whether the second node information corresponding to the displayed page at the current query moment is the same as the first node information. If a change occurs, that is, the second node information is different from the first node information, it is determined that the displayed page has no white screen problem. If no change occurs, that is, the second node information is the same as the first node information, it is determined whether the query time exceeds a preset threshold. If it exceeds, it is determined that the displayed page has a white screen problem. If it does not exceed, it is determined whether the second node information corresponding to the displayed page at the next query moment is the same as the first node information.

[0072] If the displayed page is not a skeleton screen page, then the third node information corresponding to the displayed page at the current query time is used to determine whether the displayed page only includes container nodes; if not, then it is determined that the displayed page has no white screen problem; if so, then it is determined whether the query time exceeds the preset threshold; if it exceeds, then it is determined that the displayed page has a white screen problem; if it does not exceed, then the third node information corresponding to the displayed page at the next query time is used to determine whether the displayed page only includes container nodes.

[0073] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. This computer program can be stored in a computer-readable storage medium, and when executed, it can include the processes of the embodiments of the methods described above. The aforementioned storage medium can be a non-volatile storage medium such as a magnetic disk, optical disk, or read-only memory (ROM), or random access memory (RAM).

[0074] It should be understood that although the steps in the flowcharts of the accompanying figures are shown sequentially as indicated by the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the accompanying figures may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily completed at the same time, but can be executed at different times, and their execution order is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the sub-steps or stages of other steps.

[0075] Further reference Figure 4 As a response to the above Figure 2 To implement the method shown, this application provides an embodiment of a page detection device 400, which is similar to... Figure 2 Corresponding to the method embodiments shown, the device can be specifically applied to various computer devices.

[0076] like Figure 4 As shown, the page detection device 400 includes: Module 410 is used to obtain the display page after loading is complete; The first generation module 420 is used to generate a page detection result corresponding to the display page based on the first node information corresponding to the display page and the second node information corresponding to the display page at each query time when the display page is a skeleton screen page; the first node information and the second node information are both used to characterize the array of element nodes included by N preset coordinate points in the display page, and the first node information is the array of element nodes included by the N preset coordinate points at the initial time. The second generation module 430 is used to generate a page detection result corresponding to the display page based on the third node information corresponding to the display page at each query time when the display page is not a skeleton screen page; the third node information is used to characterize the node type of the element nodes included by N preset coordinate points in the display page; Where N is a positive integer greater than 1.

[0077] Optionally, the first generation module 420 is specifically used for: Based on the second node information and the first node information corresponding to the current query time on the display page, determine whether the array of element nodes included in the N preset coordinate points on the display page has changed; If the array of element nodes included in the N preset coordinate points changes, a first detection result is generated; the first detection result is used to indicate that the display page is not in a white screen state. If the array of element nodes included in the N preset coordinate points remains unchanged, perform the first operation according to the query duration corresponding to the current query time; The first operation includes any one of the following: A second detection result is generated; the second detection result is used to characterize that the display page is in a white screen state. Based on the first node information corresponding to the displayed page and the second node information corresponding to the displayed page at the next query time of the current query time, a page detection result corresponding to the displayed page is generated.

[0078] Optionally, the page detection device 400 further includes: The first determining module is used to determine that the element node array included in the N preset coordinate points has changed when the element node array represented by the second node information is different from the element node array represented by the first node information. The second determining module is used to determine that the element node array included in the N preset coordinate points has not changed when the element node array represented by the second node information is the same as the element node array represented by the first node information.

[0079] Optionally, the first generation module 420 is further specifically used for: If the query duration corresponding to the current query time exceeds a preset threshold, a second detection result is generated; If the query duration corresponding to the current query time does not exceed a preset threshold, a page detection result corresponding to the display page is generated based on the first node information corresponding to the display page and the second node information corresponding to the next query time of the display page at the current query time.

[0080] Optionally, the second generation module 430 is further specifically used for: Based on the third node information corresponding to the current query time on the display page, determine whether the N preset coordinate points in the display page include non-container nodes; If the N preset coordinate points include non-container nodes, a first detection result is generated; the first detection result is used to indicate that the display page is not in a white screen state. If the N preset coordinate points do not include non-container nodes, perform the second operation according to the query duration corresponding to the current query time; The second operation includes any one of the following: A second detection result is generated; the second detection result is used to characterize that the display page is in a white screen state. Based on the third node information corresponding to the next query time of the current query time, a page detection result corresponding to the display page is generated.

[0081] Optionally, the page detection device 400 further includes: The third determining module is used to determine N preset coordinate points, including non-container nodes, when the node type represented by the third node information is a container node and a non-container node. The fourth determining module is used to determine N preset coordinate points that do not include non-container nodes when the node type represented by the third node information is a container node.

[0082] Optionally, the second generation module 430 is further specifically used for: If the query duration corresponding to the current query time exceeds a preset threshold, a second detection result is generated; If the query duration corresponding to the current query time does not exceed a preset threshold, the page detection result corresponding to the display page is generated based on the third node information corresponding to the next query time of the current query time.

[0083] In this embodiment of the invention, for a display page that is a skeleton screen page, a page detection result is generated based on the first node information corresponding to the display page and the second node information corresponding to the display page at each query time; for a display page that is not a skeleton screen page, a page detection result is generated based on the third node information corresponding to the display page at each query time. By performing page detection on different front-end pages and generating page detection results in different ways, the page detection method provided by this invention can be compatible with different front-end pages, thereby improving the accuracy of page detection.

[0084] To address the aforementioned technical problems, embodiments of this application also provide a computer device. Please refer to [link / reference needed]. Figure 5 , Figure 5 This is a basic structural block diagram of the computer device in this embodiment. The computer device 5 includes a memory 51, a processor 52, and a network interface 53 that are interconnected via a system bus. It should be noted that only the computer device 5 with components 51-53 is shown in the figure; however, it should be understood that it is not required to implement all the shown components, and more or fewer components can be implemented alternatively. Those skilled in the art will understand that the computer device described here is a device capable of automatically performing numerical calculations and / or information processing according to pre-set or stored instructions, and its hardware includes, but is not limited to, microprocessors, application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), digital signal processors (DSPs), embedded devices, etc.

[0085] The computer device can be a desktop computer, laptop, handheld computer, or cloud server, etc. The computer device can interact with the user via a keyboard, mouse, remote control, touchpad, or voice control.

[0086] The memory 51 includes at least one type of readable storage medium, including flash memory, hard disk, multimedia card, card-type memory (e.g., SD or DX memory), random access memory (RAM), static random access memory (SRAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), programmable read-only memory (PROM), magnetic memory, magnetic disk, optical disk, etc. In some embodiments, the memory 51 may be an internal storage unit of the computer device 5, such as the hard disk or memory of the computer device 5. In other embodiments, the memory 51 may also be an external storage device of the computer device 5, such as a plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, etc., equipped on the computer device 5. Of course, the memory 51 may include both the internal storage unit and its external storage device of the computer device 5. In this embodiment, the memory 51 is typically used to store the operating system and various application software installed on the computer device 5, such as the program code of method X. In addition, the memory 51 can also be used to temporarily store various types of data that have been output or will be output.

[0087] In some embodiments, the processor 52 may be a central processing unit (CPU), a controller, a microcontroller, a microprocessor, or other data processing chip. The processor 52 is typically used to control the overall operation of the computer device 5. In this embodiment, the processor 52 is used to run program code stored in the memory 51 or process data, for example, to run the program code for the X method.

[0088] The network interface 53 may include a wireless network interface or a wired network interface, which is typically used to establish communication connections between the computer device 5 and other computer devices.

[0089] This application also provides another embodiment, namely, providing a computer-readable storage medium storing the page detection method program, which can be executed by at least one processor to cause the at least one processor to perform the steps of the page detection method as described above.

[0090] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware online platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal device (which may be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in the various embodiments of this application.

[0091] This application can be used in a wide variety of general-purpose or special-purpose computer system environments or configurations. Examples include: personal computers, server computers, handheld or portable devices, tablet devices, multiprocessor systems, microprocessor-based systems, set-top boxes, programmable consumer computer devices, network PCs, minicomputers, mainframe computers, and distributed computing environments including any of the above systems or devices. This application can be described in the general context of computer-executable instructions executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform specific tasks or implement specific abstract data types. This application can also be practiced in distributed computing environments where tasks are performed by remote processing devices connected via a communication network. In distributed computing environments, program modules can reside in local and remote computer storage media, including storage devices.

[0092] Obviously, the embodiments described above are only some embodiments of this application, not all embodiments. The accompanying drawings show preferred embodiments of this application, but do not limit the patent scope of this application. This application can be implemented in many different forms; rather, the purpose of providing these embodiments is to provide a more thorough and comprehensive understanding of the disclosure of this application. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing specific embodiments, or make equivalent substitutions for some of the technical features. Any equivalent structures made using the content of this application's specification and drawings, directly or indirectly applied to other related technical fields, are similarly within the scope of patent protection of this application.

Claims

1. A page detection method, characterized in that, include: Get the page that is displayed after loading is complete; When the displayed page is a skeleton screen page, a page detection result corresponding to the displayed page is generated based on the first node information corresponding to the displayed page and the second node information corresponding to the displayed page at each query time. The first node information and the second node information are both used to characterize the array of element nodes included by N preset coordinate points in the displayed page. The first node information is the array of element nodes included by the N preset coordinate points at the initial time, and N is a positive integer greater than 1. The step of generating a page detection result for the display page based on the first node information corresponding to the display page and the second node information corresponding to the display page at each query time includes: determining whether the array of element nodes included in N preset coordinate points in the display page has changed based on the second node information and the first node information corresponding to the display page at the current query time; generating a first detection result if the array of element nodes included in the N preset coordinate points has changed, wherein the first detection result is used to indicate that the display page is not in a blank screen state; and performing a first operation based on the query duration corresponding to the current query time if the array of element nodes included in the N preset coordinate points has not changed, wherein the first operation includes any one of the following: generating a second detection result, wherein the second detection result is used to indicate that the display page is in a blank screen state; or generating a page detection result for the display page based on the first node information corresponding to the display page and the second node information corresponding to the display page at the next query time of the current query time. If the displayed page is not a skeleton screen page, a page detection result corresponding to the displayed page is generated based on the third node information corresponding to the displayed page at each query time. The third node information is used to characterize the node type of the element nodes included by the N preset coordinate points. The step of generating a page detection result for the display page based on the third node information corresponding to the display page at each query time includes: determining whether N preset coordinate points in the display page include non-container nodes based on the third node information corresponding to the display page at the current query time; generating a first detection result if the N preset coordinate points include non-container nodes; the first detection result is used to indicate that the display page is not in a white screen state; and performing a second operation based on the query duration corresponding to the current query time if the N preset coordinate points do not include non-container nodes. The second operation includes any one of the following: generating a second detection result; the second detection result is used to indicate that the display page is in a white screen state; and generating a page detection result for the display page based on the third node information corresponding to the next query time of the display page at the current query time.

2. The method according to claim 1, characterized in that, Before the step of generating the first detection result when the array of element nodes included in the N preset coordinate points changes, the method further includes: If the element node array represented by the second node information is different from the element node array represented by the first node information, it is determined that the element node array included in the N preset coordinate points has changed. If the element node array represented by the second node information is the same as the element node array represented by the first node information, it is determined that the element node array included by the N preset coordinate points has not changed.

3. The method according to claim 1, characterized in that, The step of performing the first operation based on the query duration corresponding to the current query time includes: If the query duration corresponding to the current query time exceeds a preset threshold, a second detection result is generated; If the query duration corresponding to the current query time does not exceed a preset threshold, a page detection result corresponding to the display page is generated based on the first node information corresponding to the display page and the second node information corresponding to the next query time of the display page at the current query time.

4. The method according to claim 1, characterized in that, Before generating the first detection result when the N preset coordinate points include non-container nodes, the method further includes: When the node type represented by the third node information is a container node and a non-container node, N preset coordinate points are determined, including non-container nodes. When the node type represented by the third node information is a container node, N preset coordinate points are determined to exclude non-container nodes.

5. The method according to claim 1, characterized in that, The step of performing the second operation based on the query duration corresponding to the current query time includes: If the query duration corresponding to the current query time exceeds a preset threshold, a second detection result is generated; If the query duration corresponding to the current query time does not exceed a preset threshold, the page detection result corresponding to the display page is generated based on the third node information corresponding to the next query time of the current query time.

6. A page detection device, characterized in that, include: The retrieval module is used to retrieve the displayed page after loading is complete; The first generation module is used to generate a page detection result corresponding to the display page when the display page is a skeleton screen page, based on the first node information corresponding to the display page and the second node information corresponding to the display page at each query time. The first node information and the second node information are both used to characterize the element node array included by N preset coordinate points in the display page. The first node information is the element node array included by the N preset coordinate points at the initial time, and N is a positive integer greater than 1. The first generation module is further configured to determine whether the array of element nodes included in the N preset coordinate points in the display page has changed based on the second node information corresponding to the display page at the current query time and the first node information; if the array of element nodes included in the N preset coordinate points has changed, generate a first detection result, wherein the first detection result is used to indicate that the display page is not in a white screen state; if the array of element nodes included in the N preset coordinate points has not changed, perform a first operation based on the query duration corresponding to the current query time, wherein the first operation includes any one of the following: generating a second detection result, wherein the second detection result is used to indicate that the display page is in a white screen state; or generating a page detection result corresponding to the display page based on the first node information corresponding to the display page and the second node information corresponding to the display page at the next query time of the current query time; The second generation module is used to generate a page detection result corresponding to the display page based on the third node information corresponding to the display page at each query time when the display page is not a skeleton screen page. The third node information is used to characterize the node type of the element nodes included in the N preset coordinate points. The second generation module is further configured to determine whether N preset coordinate points in the display page include non-container nodes based on the third node information corresponding to the display page at the current query time; if the N preset coordinate points include non-container nodes, generate a first detection result; the first detection result is used to indicate that the display page is not in a white screen state; if the N preset coordinate points do not include non-container nodes, perform a second operation based on the query duration corresponding to the current query time; wherein, the second operation includes any one of the following: generating a second detection result; the second detection result is used to indicate that the display page is in a white screen state; generating a page detection result corresponding to the display page based on the third node information corresponding to the next query time of the display page at the current query time.

7. A computer device, characterized in that, It includes a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other through the communication bus; Memory, used to store computer programs; A processor, when executing a program stored in memory, implements the page detection method according to any one of claims 1-5.

8. A storage medium, characterized in that, The storage medium stores a data processing program, which, when executed by a processor, implements the steps of the page detection method as described in any one of claims 1-5.

Citation Information

Patent Citations

  • A webpage segmentation method and a webpage segmentation system

    CN102262627A

  • Apparatus and method for organizing and-or presenting data

    US20020152222A1