CN112148571A - Method and device for recording and playing back webpage operation process - Google Patents

Method and device for recording and playing back webpage operation process Download PDF

Info

Publication number
CN112148571A
CN112148571A CN202010651352.9A CN202010651352A CN112148571A CN 112148571 A CN112148571 A CN 112148571A CN 202010651352 A CN202010651352 A CN 202010651352A CN 112148571 A CN112148571 A CN 112148571A
Authority
CN
China
Prior art keywords
data
webpage
server
operation process
web page
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202010651352.9A
Other languages
Chinese (zh)
Inventor
路玉亭
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Qingdao Window Technology Co ltd
Original Assignee
Qingdao Window Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Qingdao Window Technology Co ltd filed Critical Qingdao Window Technology Co ltd
Priority to CN202010651352.9A priority Critical patent/CN112148571A/en
Publication of CN112148571A publication Critical patent/CN112148571A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/34Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment
    • G06F11/3438Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment monitoring of user actions
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/958Organisation or management of web site content, e.g. publishing, maintaining pages or automatic linking

Abstract

The method is applied to a webpage operation process recording device and a webpage operation process playback device, and comprises the steps of generating an HTML event and/or processing information corresponding to the HTML event into a webpage operation instruction based on the HTML event occurring in a webpage, and recording and adding the webpage operation instruction and time information of the HTML event to webpage operation instruction sequence data according to a corresponding relation. According to the webpage operation process playback method, the recorded data of the webpage operation process are read and analyzed, based on the data records contained in the recorded data, the calling time of the data records is generated according to the time information arrangement of the data records, the webpage operation instructions contained in the data records are executed based on the calling time of the data records, and the original webpage operation process is restored. The method and the device are beneficial to completely storing the operation process records of the webpage, and the generated data have the advantages of small volume and tamper resistance.

Description

Method and device for recording and playing back webpage operation process
Technical Field
The invention relates to the field of communication, in particular to a method and a device for recording and playing back a webpage operation process.
Background
In the process of web page browsing and operation, it is often necessary to record browsing and operation information of a user, for example, explaining browsed content and sending the explanation to a third party, so that the third party can perform web page playback to fully understand content, emphasis and operation process included in a web page. In addition, in some special requirements, it is required to strictly record the browsing and operating processes of the web page, and generate web page operating process recorded data for inspection, and at the same time, it is required to consider the integrity of the recorded data, and it is not allowed to tamper, for example, in the "notification about the retrospective management of the standardized internet insurance sales behavior" issued by the bank and custody, it is explicitly required to make the retrospective of the internet insurance sales behavior, i.e. the operating process sold through the web page is completely recorded, and the generated data for inspection is stored, and it is emphasized that the retrospective data of the internet insurance sales behavior should be restored to an effective file for inspection, and the sales page should be restored to an effective picture or video for inspection, so as to facilitate inspection and use.
In the prior art, a mode of screen recording is adopted for recording a webpage operation process to generate a video, and the method has the characteristics of large volume, inconvenience in recording and difficulty in checking, generally, in the webpage operation process of internet insurance, the operation time is calculated according to 10 minutes, the size of a generated recording file is more than 500M, a user is required to install screen recording software to complete the insurance process, and the behaviors of the user are limited; checking for recorded video does not allow one to quickly locate a certain content (e.g., the user's signature in the health advice item).
Therefore, a new technical solution is urgently needed to solve the problem that data records for inspection are generated by effectively and accurately recording the webpage browsing and operating processes.
Disclosure of Invention
The embodiment of the application provides a method for recording and replaying a webpage operation process, which solves the problem of recording the webpage browsing and operation process and generates complete webpage operation process recording data.
In a first aspect, the present application provides a method for recording a web page operation process, which is applied to a device for recording a web page operation process, and the method includes:
generating an HTML Event (HTML DOM Event) generated in the webpage and/or processing information corresponding to the HTML Event into a webpage operation instruction;
recording and adding the webpage operation instruction and the time information of the HTML event according to the corresponding relation to webpage operation instruction sequence data;
the webpage operation instruction is used for calling during webpage playback so as to restore the execution effect of the corresponding HTML event; the webpage operation instruction sequence data is used for playing back the webpage operation process, based on the data record contained in the webpage operation process, scheduling and generating the calling time of the data record according to the time information of the data record, and executing the webpage operation instruction contained in the data record based on the calling time.
In the technical solution provided by the first aspect, each time a web page is operated or a web page is changed, a corresponding HTML event is generated, and therefore, the web page operation instruction is generated based on the HTML event generated in the web page.
In the technical scheme provided by the first aspect, the operation process of the webpage is recorded based on the HTML event occurring in the webpage, and the webpage operation instruction sequence data containing the time information is generated, that is, the data record of "what was done at what time in the webpage" is recorded, so that complete data is provided for playback of the whole operation process of the webpage and restoration of the single-step webpage operation.
In a possible implementation manner of the first aspect, data sent from a server to a client in the loading process is acquired according to the first loading of the web page, or data in a local browser after the loading of the web page is completed is read, and the data is recorded as web page basic access data; and the webpage basic access data is used as initialization data in the playback process of the webpage operation process.
In this possible implementation manner, the basic access data of the web page is data requested from the server during the first web page loading process, that is, all data locally contained in the browser after the first web page loading is completed, and the contents of the obtained data are substantially the same in the two obtaining methods provided above.
In the possible implementation manner, complete webpage data are recorded at the time point when the webpage is loaded for the first time, and then, after the webpage enters an operation state, the HTML event occurring in the webpage is started to generate the HTML event and/or processing information corresponding to the HTML event as a webpage operation instruction. The implementation mode respectively adopts corresponding processing methods according to the characteristics of different stages of webpage access, is high in execution efficiency and is convenient for generating complete initial data.
In a possible implementation manner of the first aspect, according to an HTML event occurring in the web page, when processing information corresponding to the HTML event is a request sent to a server, the request information and server return information are recorded according to a corresponding relationship, and server request record data is generated.
With reference to this possible implementation manner, optionally, the web page operation instruction (the web page operation instruction generated based on the HTML event or the corresponding processing information thereof) and the server return information are recorded according to the corresponding relationship and server request record data is generated.
The possible implementation mode solves the problem that the interaction between the webpage and the server causes confusion in the webpage operation process playback process, enables the playback process not to depend on the server environment during the recording of the webpage operation process any more, and can normally execute the playback even under the condition that the original server environment does not exist. Meanwhile, the data and the situation of interaction with the server during the recording of the webpage operation process are accurately restored. In addition, the server requests to record data for analog output, and the analog providing server returns data, so that the playback efficiency is improved.
In a possible implementation manner of the first aspect, the operating environment information of the web page is acquired, and web page operating environment data is generated; the webpage operation environment information comprises one or more of Web server information, client operating system information, network information, browser information, operation environment information provided by a browser for a webpage, webpage information and geographical position information.
In the possible implementation manner, the running environment information of the webpage is recorded, and the running environment information is used for setting the recording program provided by the application in the webpage operation recording process, analyzing, judging and setting the played-back webpage running environment in the webpage playback process, and simultaneously, providing information support for a player who executes the playback.
In a possible implementation manner of the first aspect, the external environment data in the webpage operation process is generated by acquiring audio and/or video data of the current external environment through a browser.
According to the possible implementation mode, by recording the external environment data in the webpage operation process, a new recording dimension is increased, the use of the generated recording data is expanded, and a new safety authentication mode is provided.
In a possible implementation manner of the first aspect, one or more of the web page operation instruction sequence data, the web page basic access data, the server request record data, the operating environment data, and the web page operation process external environment data are structurally stored to generate web page operation process record data.
According to the possible implementation mode, the stored and generated webpage operation process record data have the characteristics of small volume and easiness in storage, and meanwhile, due to the adoption of structured storage, the data extraction requirements in multiple aspects can be met, and data in a certain aspect can be extracted quickly.
In a possible implementation manner of the first aspect, a message digest is generated for the web page operation process record data by applying a message digest algorithm; the message abstract is used for verifying the integrity of the data of the webpage operation process and identifying the webpage operation process.
The possible implementation mode is short and easy to store the generated message abstract, facilitates verification of authenticity and integrity of the recorded data and the contained data in the webpage operation process, and has the advantage of tamper resistance.
A second aspect of the present application provides a method for playing back a webpage operation process, which is applied to a device for playing back a webpage operation process, and the method includes:
reading the recorded data of the webpage operation process;
analyzing the webpage operation process recorded data to obtain one or more of webpage basic access data, webpage operation instruction sequence data, server request recorded data, webpage operation environment data and external environment data in the webpage operation process;
when the analyzed and obtained data contain webpage operation environment data, judging whether the current played-back webpage operation environment meets the playback requirement according to the data contained in the webpage operation environment data, and setting the webpage operation environment according to the data contained in the webpage operation environment data;
when the analyzed and obtained data contain the external environment data in the webpage operation process, the audio and/or video content contained in the data are played in a browser according to the external environment data in the webpage operation process;
when the analyzed data contains webpage basic access data, displaying a webpage according to the webpage basic access data;
reading a data record in the webpage operation instruction sequence data, arranging and generating the calling time of the data record according to the time information of the data record, and executing the webpage operation instruction contained in the data record based on the calling time of the data record.
In the technical solution provided by the second aspect, playback is performed on the basis of the recorded data of the webpage operation process generated by the technical solution provided by the first aspect, according to the analyzed obtained data, based on the data content contained in the data, the judgment and setting of the webpage operation environment, the audio and video playing contained in the external environment data, the initialization of the webpage content according to the webpage basic access data, the execution of the corresponding webpage operation instruction by referring to the time information during the recording of the webpage operation process, and other operations are performed, so as to achieve complete restoration of the webpage operation process. Moreover, the advantage of adopting the structured storage based on the web page operation process recording data can be flexibly controlled aiming at the playback requirement in the playback process, such as: and removing the playing operation aiming at the webpage running environment data.
In a possible implementation manner of the second aspect, when it is determined that the web page operation instruction includes sending a request to a server, the following steps are performed:
capturing a request currently sent to a server;
acquiring corresponding server request record data based on the current webpage operation instruction or the current request information;
obtaining server return data contained in the server request record data from the server request record data;
and taking the data returned by the server as the data returned by sending the request to the server at this time, and returning the data to the webpage.
In this possible implementation manner, according to the generation manner of the server request record data, the server return data included in the server request record data is acquired from the server request record data. If the server request recording data is recorded according to the corresponding relationship between the request information and the server return information, searching the corresponding relationship according to the captured server request information to obtain the server return data; and if the server requests to record data according to the webpage operation instruction and the server return information according to the corresponding relationship, searching and obtaining the server return data in the corresponding relationship according to the currently executed webpage operation instruction.
In the possible implementation mode, the request sent to the server is captured in the playback process, the return data is searched from the server request recording data and provided as the data returned after the request is sent to the server at this time, the implementation mode enables the webpage operation process playback to be independent of the server environment when the webpage operation process is recorded, and the mode of simulating the server return data by using the server request recording data improves the playback efficiency and can avoid the problem of confusion interaction with the server.
A third aspect of the present application provides a web page operation process recording apparatus, configured to execute the method in the first aspect or any possible implementation manner of the first aspect. Specifically, the web page operation process recording device includes:
the operation environment information acquisition module is used for acquiring the operation environment information of the webpage;
the webpage operation process external environment data acquisition module is used for acquiring audio and/or video data of the current external environment through a browser in the webpage operation process;
the webpage data acquisition module is used for acquiring data sent from the server to the client in the webpage first loading process, or reading data in a local browser after webpage loading is finished and storing the data as webpage basic access data;
the webpage operation monitoring module is used for monitoring an HTML event generated in a webpage and calling the webpage operation instruction generating module after the HTML event is monitored;
the webpage operation instruction generating module is used for generating an HTML event and/or processing information corresponding to the HTML event into a webpage operation instruction according to the HTML event occurring in the webpage, and recording and adding the webpage operation instruction and the time information of the HTML event to webpage operation instruction sequence data according to a corresponding relation;
the server request processing module is used for recording the request information and the server return information according to the corresponding relation and generating server request record data when the processing information corresponding to the HTML event comprises a request sent to a server, or recording the webpage operation instruction and the server return information according to the corresponding relation and generating server request record data;
the data storage module is used for performing structured storage on one or more of the webpage operation instruction sequence data, the webpage basic access data, the server request record data, the operation environment data and the external environment data in the webpage operation process to generate webpage operation process record data; the message digest generating module is also used for generating message digest information according to the message digest;
and the message abstract generating module is used for generating a message abstract by applying a message abstract algorithm according to the webpage operation process record data stored by the data storage module.
A fourth aspect of the present application provides a device for playing back a webpage operation process, which is used to execute the method in the second aspect or any possible implementation manner of the second aspect. Specifically, the webpage operation process playback device comprises:
the data reading module is used for reading the recorded data of the webpage operation process;
the data analysis module is used for analyzing the webpage operation process record data and the data contained in the webpage operation process record data, wherein the webpage operation process data comprises one or more of webpage operation instruction sequence data, webpage basic access data, server request record data, operation environment data and external environment data in the webpage operation process;
the operation environment information setting module is used for judging whether the current operation environment meets the playback requirement or not based on the operation environment data and setting a webpage operation environment based on the operation environment data;
the webpage data writing module is used for writing webpage data into the browser based on the webpage basic access data to restore and display a webpage;
the webpage operation instruction execution module is used for reading data records in the webpage operation instruction sequence data, arranging and generating calling time of the data records according to the time information of the data records, and executing the webpage operation instructions contained in the data records based on the calling time of the data records;
the server request operation execution module is used for capturing the current request sent to the server and calling the server request proxy service module to process the request when the webpage operation instruction is determined to contain the request sent to the server;
the server request proxy service module is used for acquiring corresponding server request record data based on a current webpage operation instruction or current request information, acquiring server return data contained in the server request record data, taking the server return data as return data after the request is sent to the server at this time, and returning the return data to the webpage;
and the external environment audio and video data playing module is used for playing audio and/or video data contained in the external environment data in the webpage operation process.
In a fifth aspect, the present application provides a computer-readable storage medium having stored thereon a computer program which, when run on a computer, causes the computer to execute the method for recording any one of the web page operations of the first aspect and/or the method for playing back any one of the web page operations of the second aspect.
In a sixth aspect, the present application provides a computer program for executing the method for recording the operation process of the web page according to the first aspect and/or the method for playing back the operation process of the web page according to the second aspect when the computer program is executed by a computer.
Therefore, in each aspect, the webpage operation process record data are generated by recording in the webpage operation process, the webpage data and the webpage operation process are completely recorded, and the data are independent; and playback is performed based on the data, the playback process avoids the same interaction with the server during recording, and the image quality of the restored webpage operation process is completely lossless.
Drawings
Fig. 1 is a schematic flowchart illustrating a process of generating sequence data of web page operation instructions according to an embodiment of the present application;
fig. 2 is an activity diagram of a record of a web page operation process according to an embodiment of the present application;
FIG. 3 is a schematic flowchart of two processes for generating basic access data of a web page according to an embodiment of the present application;
fig. 4 is a schematic flowchart of generating a webpage operation instruction according to an embodiment of the present application;
FIG. 5 is a schematic flowchart illustrating a process for generating data of a webpage operating environment according to an embodiment of the present application;
fig. 6 is a schematic structural diagram of a conventional web page operating environment according to an embodiment of the present application;
fig. 7 is a schematic flowchart of generating external environment data in a webpage operation process according to an embodiment of the present application;
fig. 8 is a schematic diagram of a generating relationship of recorded data in a web page operation process according to an embodiment of the present application;
fig. 9 is a schematic flowchart of generating a message digest for data recorded in an operation process of a web page according to an embodiment of the present application;
FIG. 10 is an activity diagram of a record of a web page operation process according to an embodiment of the present application;
FIG. 11 is an activity diagram of a webpage operation process playback provided by an embodiment of the present application;
fig. 12 is a schematic diagram illustrating a flowchart of executing a webpage operation instruction during playback according to an embodiment of the present application;
fig. 13 is a schematic structural diagram of a device for recording a webpage operation process according to an embodiment of the present application;
fig. 14 is a schematic structural diagram of a device for playing back a webpage operation process according to an embodiment of the present application.
Detailed Description
The embodiments of the present application are in part illustrative of the present application and are not intended to be limiting of the present application.
Embodiments of the present application will now be described with reference to the accompanying drawings, and it is to be understood that the described embodiments are merely illustrative of some, but not all, embodiments of the present application. As can be known to those skilled in the art, with the development of technology and the emergence of new scenarios, the technical solution provided in the embodiments of the present application is also applicable to similar technical problems.
In the following, some terms in the present application are explained so that those skilled in the art can understand that:
1) HTML events, i.e., HTML DOM events, include events of HTML elements as well as global events.
2) The web page operation instruction is generated when the web page operation process is recorded, is called when the web page operation process is played back, and is a computer program (such as a function, a method, an instruction, program code and the like) capable of being executed in the web page. It is generated based on HTML events, and the execution effect is equivalent to the HTML events.
3) The webpage operation instruction sequence data are a set, and each element of the set comprises webpage operation instruction information and relevant information of the time of an HTML event corresponding to the webpage operation instruction.
4) The web page basic access data is data requested from a server in the process of loading a web page for the first time, namely all data contained in a browser locally after the web page is loaded for the first time. It can be understood in popular terms that data included in an initial webpage state obtained after a webpage is opened for the first time and loaded is similar to data generated by an existing browser for opening the webpage and using a browser to store as an additional function after loading is completed. The data is all data related to the web page, including but not limited to web page HTML codes, web page script programs, js files, css style files, pictures, font files, and the like.
5) The server requests to record data, which is used for recording data sent and received when interacting with the server in the process of web page operation, and the data content of the data can include but is not limited to one or more of request information sent to the server, server return information, web page operation instructions, HTML events, processing information corresponding to the HTML events, request time and return time.
6) The webpage operation environment data is generated according to the collected webpage operation environment information, and the webpage operation environment information comprises one or more of Web server information, client operating system information, network information, browser information, operation environment information provided by a browser for a webpage, webpage information and geographical position information.
7) The external environment data in the webpage operation process refers to the external environment data in the webpage operation process generated by acquiring the acquired audio and/or video data of the current external environment through a browser while recording the webpage operation process and according to the acquired data.
8) The web page operation process recording data is used for recording a web page operation process and refers to data generated by one or more of web page operation instruction sequence data, web page basic access data, server request recording data, operation environment data and external environment data in the web page operation process through structured storage.
9) And/or, describing the association relationship of the associated objects, indicating that three relationships may exist. For example, a and/or B, may represent: three cases of a alone, B alone, and a and B together exist, and a character "/" generally indicates that the former and latter associated objects are in an "or" relationship.
The application provides a webpage operation process recording method which is applied to recording the browsing and operation processes of a user on a webpage and finally generating recorded data capable of being used for playing back the operation process.
In the browsing and operating process of the webpage, each time the webpage operation or the webpage changes, the corresponding HTML event is generated, therefore, the method provided by the application acquires the data of the webpage operating process based on the HTML event generated in the webpage, generates the webpage operating instruction based on the acquired HTML event, and then generates the acquired webpage operating instruction into the webpage operating instruction sequence data.
Fig. 1 shows a schematic flow chart of a possible generation of sequence data of web page operation instructions, which includes the following steps:
s101, monitoring HTML events;
s102, generating an HTML event and/or processing information corresponding to the HTML event into a webpage operation instruction;
s103, recording and adding the webpage operation instruction and the time information of the HTML event according to the corresponding relation to webpage operation instruction sequence data;
the following is detailed for the above steps:
in S101, acquiring the HTML event may be implemented by establishing monitoring for the HTML DOM, for example, using a javascript HTML DOM event monitor and establishing monitoring by an addEventListener () method. In a preferred implementation, monitoring is directly established on document, because, when a web page is loaded, a browser creates a Document Object Model (DOM) of the page, the document is a root node of the DOM, and all elements in the web page are child nodes of the document, monitoring of all elements in the web page can be achieved by adopting the method according to a bubble mechanism of a web page event.
In S102, the HTML event and/or the processing information corresponding to the HTML event is generated as a web page operation command, and the execution effect of the generated web page operation command is equal to the execution effect of the HTML event or the processing information corresponding to the HTML event. Therefore, the technical solution provided by the present application mainly uses the webpage operation instruction to restore the recorded webpage operation or the change of the webpage, and the principle of implementing this point lies in: any operation performed in the web page (i.e., any HTML event) can be done using a JavaScript-like program. Preferably, the webpage operation instruction is in the form of a JavaScript statement, a function, a program, and the like, for example: if the HTML event is that a click event occurs to the button "btn", the operation instruction is: document. getelementbyid ("btn"). click (), i.e., the "btn" button is first retrieved and then its click () function is executed. In the embodiment, two ways of generating the web page operation instruction corresponding to the HTML event are provided, one way is based on the HTML event corresponding generation, such as the above button click event generation is the click () instruction executed on the button; another kind is generated based on the processing information corresponding to the HTML event, such as: the HTML event is a click event occurring on the button "btn", and when the HTML event is clicked, the function helloWord () is executed, and the processing information corresponding to the HTML event is: executing the function helloWord (), so that the corresponding generated webpage operation instruction is as follows: helloWord ().
In a specific embodiment, when the HTML event and/or the processing information corresponding to the HTML event is generated as the web page operation instruction, S102 further includes recording data information related to the HTML event or the processing information corresponding to the HTML event, and storing the data information independently or in combination with the web page operation instruction, where the data information is used when the web page operation instruction is executed. For example, the data content input in the input element needs to be written into the input when the corresponding web page operation instruction is executed, and the effect of inputting the input element is restored when the web page is played back.
In one possible implementation manner, in the step S102, when it is determined that the HTML event and/or the processing information corresponding to the HTML event includes a request to be sent to the server or an interaction with the server, based on a result of the request to the server or the interaction with the server, a web page operation instruction which does not include the request to be sent to the server or the interaction with the server is generated. For example, if an HTML event executes to send a request to a server, and the server returns the order number 100 and writes the web page element input1, the content of the generated web page operation instruction is: the number 100 is written to the web element input 1.
In S103, the web page operation instruction sequence data is a set, and each stored element includes web page operation instruction information and relevant information of an HTML event occurrence time corresponding to the web page operation instruction, where the time information includes, but is not limited to, an occurrence time of the HTML event, a time length from the HTML occurrence time to a start time of web page operation start recording, an interval time length from a previous HTML occurrence time, and the like.
Through the above embodiments, the operation process of the web page is recorded based on the HTML event occurring in the web page, and the web page operation instruction sequence data containing time information is generated, that is, the data of "what was done at what time in the web page" is recorded, so that complete data is provided for playback of the whole operation process of the web page and restoration of single-step web page operation.
In a possible implementation scenario, in consideration of characteristics of each stage in a web page access process, different recording modes are adopted for different stages, that is, a mode of recording web page data is adopted based on loading of a web page, and a mode of recording a web page operation instruction is adopted based on operation for the web page. Please refer to the example implementation steps in fig. 2:
s201, opening a webpage;
s202, webpage loading;
s203, acquiring basic access data of the webpage;
s204, monitoring HTML events;
s205, generating the HTML event and/or the processing information corresponding to the HTML event into a webpage operation instruction;
and S206, recording and adding the webpage operation instruction and the time information of the HTML event according to the corresponding relation to the webpage operation instruction sequence data.
In step S203, there are two ways to obtain the basic access data of the web page:
in a first mode, according to the first loading of the web page, data sent from the server to the client in the loading process is acquired, please refer to the steps shown in fig. 3 in detail: s301, completing webpage loading; s302, data sent from a server to a client in the process of loading the webpage for the first time is obtained; s303, storing the data as webpage basic access data;
in a second mode, the data in the local browser after the web page is loaded is read, please refer to the steps shown in fig. 3 in detail: s304, completing webpage loading; s305, reading data in the local browser after the webpage loading is finished; s306, storing the data as webpage basic access data.
In the first mode, the data obtained from the server in the first webpage loading process is requested, including but not limited to the following modes: recording all data sent to a client browser by a Web server, and generating the recorded data into webpage basic access data (optionally sending the data to a client) after the webpage is loaded; after the webpage loading is started, a webpage operation process recording program provided for realizing the application is loaded firstly, then a data recording method in the webpage operation process recording program is called, and in the webpage loading process, data obtained from a server request are recorded and webpage basic access data are generated.
In the implementation scenario, the step S203 records and obtains complete webpage data at the time when the webpage is loaded for the first time, and then, after the webpage enters the operation state, the step S204 is executed to start monitoring an HTML event, and based on the HTML event occurring in the webpage, the HTML event and/or processing information corresponding to the HTML event are/is generated as a webpage operation instruction.
The steps S205 and S206 are the same as the steps S102 and S103 in the previous embodiment, and are not described herein again.
In the implementation scenario, the webpage access process is divided into two stages of loading and operation, and the implementation scenario adopts a data recording mode and an instruction recording mode to process the two stages respectively. In the process of loading the webpage, the method is mainly characterized in that data transmission and webpage content initialization display are adopted, and a data recording mode is very suitable in the stage, namely, the mode for recording the webpage data to generate the webpage initialization access data is provided by the embodiment, and meanwhile, the method is beneficial to realizing the loading of related programs of the method and preparing for the acquisition of the subsequent webpage operation process. In the process of webpage operation, the method is mainly characterized in that the actions of user browsing, webpage operation and server interaction are mainly embodied as actions, so that a mode of adopting webpage operation instruction records (namely steps S204, S205 and S206) is more suitable at the stage, and the webpage operation instructions are generated based on HTML event records generated in the webpage, so that the purpose of recording the webpage operation process is achieved.
Through the embodiment, the mode of recording the initial state and each step of interaction is adopted, the appropriate processing method is respectively adopted according to the characteristics of different stages of webpage access, the processing logic is clear, and the generated data structure is clear and high in stability.
In a specific implementation scenario, when the processing content corresponding to the HTML event occurring in the web page interacts with the server, the web page operation instruction generated according to the corresponding processing content, for example, executed during the playback process, may send a request to the server again (the same as the server request during the web page operation recording process), so that the problem of confusion of interaction with the server may be caused. For example: when the webpage operation process is recorded, the total number of orders currently stored by the server is 10, the execution content of the HTML event comprises request information of 'order number increase 1' sent to the server, the server processes and returns 'the total number of current orders is 11' according to the received information, and the webpage operation playback process is executed according to the information: the total number of orders currently stored by the server is 11, and when the webpage operation instruction is executed, request information of 'order number increase by 1' is sent to the server, so that an error return result 'the total number of orders currently is 12', which is different from the recorded result, and the data stored by the server is damaged. In order to solve the above problem, please refer to fig. 4, the detailed steps are as follows:
s401, monitoring an HTML event;
s402, judging whether the processing information corresponding to the HTML event comprises a request sent to a server;
s403, recording the request information and the server return information according to a corresponding relation and generating server request record data, or recording the webpage operation instruction and the server return information according to a corresponding relation and generating server request record data;
s404, generating the HTML event and/or the processing information corresponding to the HTML event into a webpage operation instruction.
According to the steps, after an HTML event is monitored in S401, whether the HTML event interacts with a server is judged in step S402, if yes, step S403 is executed to generate server request record data, and step S404 is executed to generate a webpage operation instruction; if the determination result is no, step S404 is directly executed to generate a web page operation instruction. It should be noted that, in the case where the determination result is yes, the execution order of steps S403 and S404 is not particularly limited.
According to the steps, when the processing content corresponding to the HTML event occurring in the webpage interacts with the server, the request content sent to the server and the return content of the server are recorded, and the server request record data are generated.
In the above embodiment, the recorded server request recorded data is applied to the playback process, and when it is determined that a request is sent to the server in the playback process, the original server is not required to be requested, and the result is directly searched from the server request recorded data and returned, so that interaction with the original server is avoided again, and the above problem of confusion of interaction with the server is not caused. Therefore, the method provided by the embodiment enables the playback process to be independent of the original server on the basis of storing the interaction records of the webpage and the server, and enhances the independence of the playback process.
In one possible embodiment, the operation environment information of the web page is recorded, and with specific reference to fig. 5, the steps are as follows:
s501, opening a webpage;
s502, acquiring the running environment information of the webpage;
and S503, generating webpage running environment data.
In the above embodiment, the Web page operating environment is a hardware and software support environment required for Web page operation, and referring to a schematic structural diagram of an existing Web page operating environment shown in fig. 6, a server is required to provide Web services for general Web page operation, data is transmitted through a network, a client terminal receives data, and a browser operates a Web page, so that the Web page operating environment information includes, but is not limited to, Web server information, client operating system information, network information, browser information, operating environment information provided by the browser for the Web page, information of the Web page itself, and geographic location information.
According to the above embodiment, the operating environment information of the web page is recorded, so that parameters and operating modes of a recording program (a computer program provided for implementing the method in the present application) can be set conveniently according to the operating environment information in the web page operation recording process, for example, a mobile browser and a PC browser are different, and HTML events and functions related to the mobile browser and the PC browser are also different, and the parameters and the operating modes of the recording program are set, so that the recording program can perform specific processing on the operating environment information, for example, a web page operating instruction compatible with the operating environment is adopted. In addition, the running environment information of the webpage is recorded, and the running environment information is also used for judging and setting the running environment of the webpage used by the current webpage playback in the webpage playback process, judging whether the current running environment has the necessary conditions of the webpage playback, and setting to obtain the optimal playback effect. Meanwhile, the recorded webpage running environment information is also used for providing information support for a player to execute the webpage, such as: server information, a web page version number, geographical location information of a recorder, etc. when recording is performed are provided.
In another possible embodiment, during the operation of the web page, the current external environment data is collected, specifically referring to fig. 7, the following steps are performed:
s701, opening a webpage;
s702, acquiring audio and/or video data of the current external environment through a browser;
and S703, generating external environment data in the webpage operation process.
At the beginning of the recording of the webpage operation process, S702 uses a browser to collect the audio and/or video data of the current external environment, and S703 generates the external environment data of the webpage operation process, wherein the generated external environment data of the webpage operation process is synchronous with the webpage operation process.
The method provided by the above embodiment can be used for solving the following problems:
the webpage operation process and the external environment data are mutually authenticated to authenticate the authenticity of an operator executing the webpage operation process and the authenticity of the environment where the operator is located, namely, a user executes a certain webpage operation in a certain external environment, or the user is located in a certain environment under the condition of executing a certain webpage operation;
the interaction can be generated between the external environment data and the webpage operation process, for example, when a user executes certain confidential operation, a section of characters are read aloud according to requirements to confirm the operation as the user, and by the mode, the recorded webpage operation process and the voice confirmation in the external environment data are in the same moment, so that the information verification problem of 'someone has done something at a certain moment', for example, the network insurance process is confirmed as the user operation;
the external environment data in the webpage operation process explains the webpage browsing and operation process, and enhances the webpage playback function, such as: and operating and explaining the webpage content in the webpage operation process record, and playing and explaining the operation aiming at the webpage content in the playback process, such as recording an example internet application process for the learning of clients.
According to the possible implementation mode, the external environment data in the webpage operation process is recorded, the webpage operation recording effect is improved, new purposes are added, and a new safety authentication mode is provided.
In another possible embodiment, various data recorded in the web page operation process are structurally stored to generate web page operation process recorded data, please refer to a schematic diagram of a data generation relationship shown in fig. 8, and one or more of the web page operation instruction sequence data, the web page basic access data, the server request recorded data, the operating environment data, and the external environment data of the web page operation process are structurally stored to generate web page operation process recorded data.
In the possible implementation manner, based on the requirements of recording and playback of the webpage operation process, the data generated in the webpage operation process are selected and structurally stored, and the stored and generated data, namely the webpage operation process recording data, are used for playback of the webpage operation process and restoration of single-step webpage operation.
Based on the above embodiment, optionally, the web page operation process recording data is stored as a whole, and an independent file for playback is generated.
Based on the above embodiment, optionally, the data generated in the webpage operation process or the webpage operation process record data is encrypted and stored.
In a specific implementation scenario, the web page operation process record data may include the following storage situations according to storage requirements:
storing the webpage operation process record data at a server;
storing the webpage operation process record data at a client;
storing the webpage operation process record data at the server side and the client side simultaneously;
and storing part of the operation process record data at the client and part of the operation process record data at the server, wherein the data stored at the two ends logically form structured overall data.
Compared with a video file generated by recording a common screen, the webpage operation process recording data generated by the embodiment of the application has the characteristics of small volume and easy storage, dozens of mega video data can be generated in 1 minute of recording the common screen, the data generated by the method provided by the application can be controlled within 100K, and the generated playing picture is completely lossless in the playback process. In addition, due to the adoption of structured storage, various related data extraction requirements can be met, and data in a certain aspect can be extracted quickly, such as operation fragment data when a user clicks a certain button.
In another possible implementation, the message digest is generated according to the generated data of the record of the web page operation process, and with specific reference to fig. 9, the following steps are performed:
s901, reading the recorded data of the webpage operation process;
and S902, generating a message abstract for the webpage operation process record data by applying a message abstract algorithm.
In this embodiment, the Message digest algorithm in S902, such as MD5Message digest algorithm (MD5 Message-DigestAlgorithm), may generate a 128-bit (16-byte) hash value, and the generated hash value (i.e. the generated Message digest) is unique for different web page operation procedure record data, and thus can be used as a unique identifier of the web page operation procedure. On the basis of the generation of the webpage operation record data, the implementation mode is applied to generate and store a message abstract (for example, a block chain is used for storage), when subsequent data are stored and played back, the message abstract is generated by the webpage operation record data which are currently played back, the message abstract is compared with the message abstract stored in the previous recording, the message abstract is completely the same, namely the data are complete and not tampered, and the integrity of the data can be verified through the message abstract.
With the above embodiment, in a specific implementation scenario, a message digest is generated for the sub-item data included in the web page operation process record data by using a message digest algorithm, and is used for verifying the integrity of the sub-item data and establishing an individual identifier for the sub-item data; or generating a message abstract by using a message abstract algorithm for the data stored at the server side and the data stored at the client side respectively, and verifying the integrity of the data stored at one end and establishing an identifier for the data at one end. Optionally, the method further includes, on the basis of generating the message digests for the plurality of pieces of data, applying a message digest algorithm to the plurality of message digests to generate new message digests for the message digests, and using the new message digests as the message digests of the web page operation process record data.
In the implementation manner provided by this embodiment, the message digest is generated for the webpage operation process record data by using the message digest algorithm, and the message digest is short and easy to store, so that the authenticity and integrity of the webpage operation process record data and the subdata contained in the webpage operation process record data are conveniently verified, and the method has the advantage of tamper resistance.
Further, according to the above embodiment, the data of the web page operation process record and the generated message digest are generated and stored by using the block chain technology, so as to generate permanent and non-falsifiable data of the web page operation process record.
In the following, the above embodiments are combined with each other to describe an implementation of the present invention in the web page operation process record, and referring to fig. 10, the main steps are as follows:
s1001, opening a webpage;
s1002, acquiring running environment information of the webpage;
s1003, collecting audio and/or video data of the current external environment;
s1004, acquiring basic access data of the webpage;
s1005, monitoring HTML events;
s1006, judging whether the processing information corresponding to the HTML event comprises a request sent to a server;
s1007, recording the request information and the server return information according to the corresponding relation and generating server request record data;
s1008, generating the HTML event and/or the processing information corresponding to the HTML event into a webpage operation instruction;
s1009, recording and adding the webpage operation instruction and the time information of the HTML event to webpage operation instruction sequence data according to the corresponding relation;
s1010, generating webpage operation process record data;
the data involved include: the data processing method comprises webpage operation instruction sequence data 801, webpage basic access data 802, server request record data 803, operating environment data 804, webpage operation process external environment data 805 and webpage operation process record data 806.
In a specific implementation scenario, S1002, S1003, and S1004 in this embodiment are optional implementation steps, and may be selected and adopted according to a requirement recorded in the web page operation process. The storage manner, storage location, and storage property of the related data content (801 to 806) in this embodiment are not particularly limited, and include, but are not limited to, storing using a storage manner such as program variables, a database, a file, a cache, and a local storage, and storing at a server side or a client side according to actual requirements, and further, selecting temporary storage or permanent storage, and preferably, the web page operation process record data 806 is finally generated web page operation process record data and is permanently stored in a manner such as a file and a database. Preferably, the JS library is used for packaging the method provided by the application in the web page, and the JS library is loaded first after the web page is opened in S1001.
In optional step S1002, operation environment information of the current web page is obtained, and operation environment data 804 is generated based on the information, where the operation environment information is further used to set parameters and an operation mode of the recording program, and the generated data is further used to set a web page operation environment when playback is executed.
In optional step S1003, at the beginning time of the web page operation process recording, starting an audio and/or video data acquisition program, and generating the acquired data into the web page operation process external environment data 805, preferably, stopping the audio and/or video data acquisition at the end time point of the web page closing or web page operation process recording, and generating the web page operation process external environment data 805 of the whole process.
Optional step S1004, executed after the first loading or complete loading of the web page is completed, collects the web page basic access data by one of the following ways: and acquiring the data sent from the server to the client in the loading process, or reading the data stored in the local browser after the webpage loading is finished.
After the webpage is loaded for the first time, step S1005 is executed, an HTML event monitoring program is started on the webpage, preferably, monitoring is directly established on document of a DOM object of the current webpage (i.e., monitoring is established on window. document), according to an execution principle of event bubbling, an event occurring on any HTML element in the webpage first triggers itself, then its parent level is also triggered, and then triggers up to document layer by layer, so that any operation occurring in the webpage can be monitored by this method.
Based on the monitored HTML event, step S1006 is executed to determine whether the currently executed content interacts with the server (except for server interaction generated to implement the method of the present application), for example, whether the executed content corresponding to the monitored HTML event has form submission or not, or whether a page get mode request is monitored or not. In addition, in a specific implementation scenario, whether interaction with the server occurs is further determined according to whether a WebSocket connection exists or not and whether a TCP data transmission exists or not.
When it is determined that there is no interaction with the server, executing step S1008 to generate the HTML event and/or the processing information corresponding to the HTML event as a web page operation instruction; when it is determined that there is an interaction with the server, step S1007 is first executed, server request record data 803 is generated, and then the web page generation operation instruction operation of step S1008 is executed.
In step S1007, the server request record data is mainly generated based on the return result of the request to the server, and the data serving as the query condition for searching the server request record data includes, but is not limited to, one or more of request information, a request website, a request method, a request time, a protocol type, transmitted data, a web page operation instruction, an HTML event, and processing content corresponding to the HTML event, which are transmitted to the server. It should be noted that, in the case where it is determined in S1006 that there is interaction with the server, and the generation of the web page operation instruction in step S1008 is not dependent on the generation of the server request record data in step S1007, the execution sequence of step S1007 and step S1008 is not particularly limited. In an alternative embodiment, when it is determined in step S1006 that there is interaction with the server, step S1007 and step S1008 are combined, that is, a web page operation instruction including a server return result and/or processing the return result is generated.
According to the web page operation instruction generated in the step S1008, step S1009 is executed to generate a data record by combining the web page operation instruction with the corresponding time information, and add the data record to the web page operation instruction sequence data. The sequence data of the web page operation instructions is substantially a set.
The above steps S1005 to S1009 correspond to the browsing and operating process after the web page loading is completed, are executed when it is monitored that the HTML event occurs to the web page or the web page changes, and are ended when the web page closes or stops the recording of the web page operating process.
Based on the above-described recorded web page basic access data 802, web page operation instruction sequence data 801, server request log data 803, operating environment data 804, and web page operation process external environment data 805, step S1010 is performed, and web page operation process log data 806 is generated. Preferably, the step S1010 generated web page operation procedure record data 806 is permanently stored.
To facilitate understanding of the methods provided by the above embodiments, fig. 13 shows a possible structure of a web page operation process recording apparatus, which includes: a web page operation monitoring module 1301, a web page operation instruction generating module 1302, a server request processing module 1303, a web page data obtaining module 1304, a web page operation process external environment data obtaining module 1305, an operation environment information obtaining module 1306, a data storage module 1307, and a message summary generating module 1308. Those skilled in the art will appreciate that the structure of the web page operation process recording device shown in fig. 13 does not constitute a limitation to the web page operation process record, and the web page operation process recording device provided in the embodiment of the present application may include more or less modules than those shown in the figure, or may combine some modules, or may be arranged in different modules.
The following specifically introduces each constituent module of the web page operation process recording apparatus with reference to fig. 13:
an operation environment information obtaining module 1306, configured to obtain operation environment information of the web page;
the external environment data acquiring module 1305 in the web page operation process is configured to acquire audio and/or video data of the current external environment and other external environment data through the browser in the web page operation process;
a web page data obtaining module 1304, configured to obtain data sent from the server to the client in a process of first loading a web page, or read data in the local browser after completion of loading a web page, and store the data as web page basic access data;
the web page operation monitoring module 1301 is used for monitoring an HTML event occurring in a web page and calling a web page operation instruction generation module after the HTML event is monitored;
a web page operation instruction generating module 1302, configured to generate, according to an HTML event occurring in the web page, the HTML event and/or processing information corresponding to the HTML event as a web page operation instruction, and record and add the web page operation instruction and time information of the HTML event to web page operation instruction sequence data according to a corresponding relationship;
the server request processing module 1303 is configured to record the request information and the server return information according to a corresponding relationship and generate server request record data, or record the web page operation instruction and the server return information according to a corresponding relationship and generate server request record data, when the processing information corresponding to the HTML event includes a request sent to a server;
a data storage module 1307, configured to perform structured storage on one or more of the web page operation instruction sequence data, the web page basic access data, the server request record data, the operating environment data, and the external environment data in the web page operation process, so as to generate web page operation process record data; the message digest generating module is also used for generating message digest information according to the message digest;
a message digest generating module 1308, configured to apply a message digest algorithm to generate a message digest according to the data stored in the data storage module in the operation process record data of the web page.
The application also provides a webpage operation process playback method, which plays back webpage browsing and operation processes and restores single-step webpage operation based on the recorded data of the webpage operation process.
FIG. 11 shows a flow diagram of a possible playback of a web page operation process, including the steps of:
s1101, reading webpage operation process record data;
s1102, analyzing the webpage operation process recorded data to obtain one or more of webpage basic access data, webpage operation instruction sequence data, server request recorded data, webpage operation environment data and external environment data in the webpage operation process;
s1103, setting a webpage running environment according to data contained in the webpage running environment data;
s1104, according to the external environment data in the webpage operation process, playing the audio and/or video content contained in the webpage in the browser;
s1105, displaying the webpage according to the webpage basic access data;
s1106, judging whether the unexecuted instructions in the webpage operation instruction sequence data are empty;
s1107, reading a webpage operation instruction to be executed according to the execution time requirement;
and S1108, executing the webpage operation instruction according to the execution time requirement.
In the above step S1102, the analysis is performed according to the structure adopted when the web page operation process record data is stored. When the obtained data includes the data of the web page running environment, step S1103 is executed, optionally, before the data of the web page running environment is set based on the data, first, the current web page running environment is judged, whether the web page playback requirement is met (generally, the playback of the web page is not completely consistent with the recorded running environment), and when the playback cannot be executed, a prompt message is given, otherwise, the data of the web page running environment is set according to the data included in the data of the web page running environment. When it is determined that the data obtained by parsing in S1102 includes external environment data in the web page operation process, step S1104 is executed, and a corresponding playing program is executed according to the type of the external environment data. When it is determined that the data obtained by parsing in S1102 includes the basic access data of the web page, step S1105 is executed to display the web page using the data, and optionally, the data content included in the basic access data of the web page is used to replace the data content in the current web page. The execution sequence of steps S1104 and S1105 is not particularly limited.
After the above steps S1101 to S1105 complete the web page initialization part when the web page playback is completed, then step S1106 is executed to determine whether the web page operation instruction record in the web page operation instruction sequence data is empty, if so, the playback is ended, otherwise, step S1107 is executed to read a web page operation instruction record according to the sequence required to be executed, the web page operation instruction information and the time information are obtained by analysis, the instruction execution time required by the record is calculated according to the time information, a timer is started inside the web page, and step S1108 is executed to execute the web page operation instruction according to the specified time point. After the execution of S1108 is completed, step S1106 is skipped to execute in a loop until the execution of all the web page operation instructions is completed. In a specific implementation scenario, step 1108 searches for and obtains a specific webpage element according to webpage element information included in the webpage operation instruction, executes the webpage operation instruction based on the webpage element, and when the webpage operation instruction executes related data, acquires data information required by the webpage operation instruction based on the webpage operation instruction and executes the webpage operation instruction.
In a possible implementation manner, step S1107 of the above embodiment reads a web page operation instruction, and then executes different processing according to whether the web page operation instruction contains an interaction request with the server, referring to fig. 12, the detailed steps are as follows:
s1201, reading a webpage operation instruction;
s1202, judging when the execution of the webpage operation instruction sends a request to a server;
s1203, capturing a request sent to a server at present;
s1204, based on the current webpage operation instruction or the current request information, obtaining corresponding server request record data;
s1205, obtaining server return data contained in the server request record data;
s1206, taking the server return data as return data for sending the request to the server at this time, and returning to the webpage;
s1207, executing the webpage operation instruction according to the execution time requirement.
In the above steps, when it is determined that the current web page operation instruction needs to interact with the server, a request sent to the original server is captured first, and then corresponding return content is obtained from the server request recording data. The method provided by the embodiment enables the webpage operation process playback not to depend on the original server providing the Web service, and can independently execute the playback.
In another possible implementation manner, when the webpage operation process is recorded, according to the content interacted with the server and the related execution content thereof, the webpage operation instruction is generated based on the execution content and the result, and therefore, the request sent to the server during the playback process is avoided. For example: in the web page recording process, currently storing 'order total number 10' in the server, clicking a button btn1, sending 'order number 5' this time to the server, processing and returning 'order total number 15' by the server, and writing the result into label1, wherein the content of the web page operation instruction generated in the above operation process is as follows: btn1 plays the click effect, writing the number 15 in label 1.
To facilitate understanding of the methods provided by the above several embodiments of web operation process playback, fig. 14 shows one possible structure of a web operation process playback apparatus, the apparatus comprising: the system comprises a data reading module 1401, a data analysis module 1402, an operating environment information setting module 1403, a webpage data writing module 1404, a webpage operation instruction execution module 1405, a server request operation execution module 1406, an external environment audio and video data playing module 1407 and a server request proxy service module 1408. Those skilled in the art will appreciate that the structure of the web page operation process playback apparatus shown in fig. 14 does not constitute a limitation to the web page operation process playback apparatus, and the web page operation process playback apparatus provided in the embodiments of the present application may include more or less modules than those shown, or combine some modules, or arrange different modules.
The following describes each constituent module of the web page operation process playback apparatus in detail with reference to fig. 14:
a data reading module 1401, configured to read data recorded in a webpage operation process;
the data analysis module 1402 is configured to analyze the web page operation process record data and data contained in the web page operation process record data, where the web page operation process data includes one or more of web page operation instruction sequence data, web page basic access data, server request record data, the operating environment data, and external environment data in the web page operation process;
an operating environment information setting module 1403, configured to determine whether the current operating environment meets the playback requirement based on the operating environment data, and set a webpage operating environment based on the operating environment data;
a webpage data writing module 1404, configured to write webpage data into the browser based on the webpage basic access data to restore and display a webpage;
a web page operation instruction execution module 1405, configured to read a data record in the data of the web page operation instruction, arrange and generate a call time of the data record according to time information of the data record, and execute a web page operation instruction included in the data record based on the call time of the data record;
the server request operation execution module 1406 is configured to, when it is determined that the web page operation instruction includes a request to be sent to a server, capture the current request to be sent to the server, and invoke the server request proxy service module to process the request;
the server request proxy service module 1408 is configured to obtain corresponding server request record data based on a current web page operation instruction or current request information, obtain server return data included in the server request record data, use the server return data as return data of a request sent to a server this time, and return the server return data to the web page;
and the external environment audio/video data playing module 1407 is configured to play audio and/or video data included in the external environment data in the webpage operation process.
In a possible implementation manner of the present application, the web page operation process recording apparatus and the web page operation process playback apparatus provided in the above embodiments are implemented in combination with a browser, that is, modules included in the apparatus are partially or completely integrated in the browser or loaded in a browser plug-in manner, and an "save as" function of the browser itself may be extended, so as to generate a "source file" capable of recording a web page operation browsing process, where the "source file" is simultaneously applied to playback.
An embodiment of the present application further provides a computer-readable storage medium, in which a computer program is stored, and when the computer program runs on a computer, the computer is enabled to execute the method for recording and playing back a webpage operation process according to the foregoing embodiment.
In addition, the embodiment of the present application further provides a computer program product, which includes a computer program, and when the computer program product runs on a computer, the computer is enabled to execute the method for recording and playing back the webpage operation process described in the above embodiment.
In the above embodiments, the implementation may be wholly or partially realized by software, hardware, firmware, or any combination thereof. When implemented in software, may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the procedures or functions described in accordance with the present application are generated, in whole or in part. The computer may be a general purpose computer, a special purpose computer, a network of computers, or other programmable device. The computer instructions may be stored in a computer readable storage medium or transmitted from one computer readable storage medium to another, for example, the computer instructions may be transmitted from one website, computer, server, or data center to another website, computer, server, or data center by wire (e.g., coaxial cable, fiber optic, digital subscriber line) or wirelessly (e.g., infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device, such as a server, a data center, etc., that incorporates one or more of the available media. The usable medium may be a magnetic medium (e.g., floppy Disk, hard Disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., solid state Disk, SolidState Disk), among others.
The above description is only a specific implementation of the embodiments of the present application, but the scope of the embodiments of the present application is not limited thereto, and any person skilled in the art can easily conceive of changes or substitutions within the technical scope of the embodiments of the present application, and all the changes or substitutions should be covered by the scope of the embodiments of the present application. Therefore, the protection scope of the embodiments of the present application shall be subject to the protection scope of the claims.

Claims (12)

1. A method for recording a webpage operation process is applied to a webpage operation process recording device, and comprises the following steps:
generating an HTML event and/or processing information corresponding to the HTML event into a webpage operation instruction based on the HTML event occurring in the webpage;
recording and adding the webpage operation instruction and the time information of the HTML event according to the corresponding relation to webpage operation instruction sequence data;
the webpage operation instruction is used for calling during webpage playback so as to restore the execution effect of the corresponding HTML event; the webpage operation instruction sequence data is used for playing back the webpage operation process, based on the data record contained in the webpage operation process, scheduling and generating the calling time of the data record according to the time information of the data record, and executing the webpage operation instruction contained in the data record based on the calling time.
2. The method of claim 1, further comprising, when the web page is first loaded:
acquiring data sent from a server to a client in the process of loading the webpage for the first time, or reading data in a local browser after the webpage is loaded, and recording the data as webpage basic access data;
and the webpage basic access data are used as initialization data for webpage operation process playback.
3. The method of claim 2, further comprising:
according to the HTML events occurring in the webpage, when the processing information corresponding to the HTML events is a request sent to a server, the request information and the server return information are recorded according to the corresponding relation to generate server request record data, or the webpage operation instructions and the server return information are recorded according to the corresponding relation to generate server request record data.
4. The method of claim 3, when accessing a web page, further comprising:
acquiring the running environment information of the webpage and generating webpage running environment data;
the webpage operation environment information comprises one or more of Web server information, client operating system information, network information, browser information, operation environment information provided by a browser for a webpage, webpage information and geographical position information.
5. The method of claim 4, wherein during the operation of the web page, the method further comprises:
and acquiring audio and/or video data of the current external environment through the browser to generate external environment data in the webpage operation process.
6. The method of claim 5, further comprising:
and performing structured storage on one or more of the webpage operation instruction sequence data, the webpage basic access data, the server request record data, the operating environment data and the external environment data in the webpage operation process to generate webpage operation process record data.
7. The method of claim 6, further comprising:
according to the webpage operation process record data, generating a message abstract for the webpage operation process record data by applying a message abstract algorithm; the message abstract is used for verifying the integrity of the data of the webpage operation process and identifying the webpage operation process.
8. A webpage operation process playback method is applied to a webpage operation process playback device, and comprises the following steps:
reading the recorded data of the webpage operation process;
analyzing the webpage operation process recorded data to obtain one or more of webpage basic access data, webpage operation instruction sequence data, server request recorded data, webpage operation environment data and external environment data in the webpage operation process;
when the analyzed and obtained data contain webpage operation environment data, judging whether the current played-back webpage operation environment meets the playback requirement according to the data contained in the webpage operation environment data, and setting the webpage operation environment according to the data contained in the webpage operation environment data;
when the analyzed and obtained data contain the external environment data in the webpage operation process, playing the contained audio and/or video contents according to the external environment data in the webpage operation process;
when the analyzed data contains webpage basic access data, displaying a webpage according to the webpage basic access data;
reading a data record in the webpage operation instruction sequence data, arranging and generating the calling time of the data record according to the time information of the data record, and executing the webpage operation instruction contained in the data record based on the calling time of the data record.
9. The method of claim 8, wherein when it is determined that the web page operation instruction comprises sending a request to a server, further comprising:
capturing a request currently sent to a server;
acquiring corresponding server request record data based on the current webpage operation instruction or the current request information;
obtaining server return data contained in the server request record data from the server request record data;
and taking the server return data as return data for sending the request to the server at this time, and returning the return data to the webpage.
10. A web page operation process recording device, wherein the web page operation process recording device comprises:
the operation environment information acquisition module is used for acquiring the operation environment information of the webpage;
the webpage operation process external environment data acquisition module is used for acquiring audio and/or video data of the current external environment through a browser in the webpage operation process;
the webpage data acquisition module is used for acquiring data sent from the server to the client in the webpage first loading process, or reading data in a local browser after webpage loading is finished and storing the data as webpage basic access data;
the webpage operation monitoring module is used for monitoring an HTML event generated in a webpage and calling the webpage operation instruction generating module after the HTML event is monitored;
the webpage operation instruction generating module is used for generating an HTML event and/or processing information corresponding to the HTML event into a webpage operation instruction according to the HTML event occurring in the webpage, and recording and adding the webpage operation instruction and the time information of the HTML event to webpage operation instruction sequence data according to a corresponding relation;
the server request processing module is used for recording the request information and the server return information according to the corresponding relation and generating server request record data when the processing information corresponding to the HTML event comprises a request sent to a server, or recording the webpage operation instruction and the server return information according to the corresponding relation and generating server request record data;
the data storage module is used for performing structured storage on one or more of the webpage operation instruction sequence data, the webpage basic access data, the server request record data, the operation environment data and the external environment data in the webpage operation process to generate webpage operation process record data; the message digest generating module is also used for generating message digest information according to the message digest;
and the message abstract generating module is used for generating a message abstract by applying a message abstract algorithm according to the webpage operation process record data stored by the data storage module.
11. A web page operation process playback apparatus, characterized in that the web page operation process playback apparatus comprises:
the data reading module is used for reading the recorded data of the webpage operation process;
the data analysis module is used for analyzing the webpage operation process record data and the data contained in the webpage operation process record data, wherein the webpage operation process data comprises one or more of webpage operation instruction sequence data, webpage basic access data, server request record data, operation environment data and external environment data in the webpage operation process;
the operation environment information setting module is used for judging whether the current operation environment meets the playback requirement or not based on the operation environment data and setting a webpage operation environment based on the operation environment data;
the webpage data writing module is used for writing webpage data into the browser based on the webpage basic access data to restore and display a webpage;
the webpage operation instruction execution module is used for reading data records in the webpage operation instruction sequence data, arranging and generating calling time of the data records according to the time information of the data records, and executing the webpage operation instructions contained in the data records based on the calling time of the data records;
the server request operation execution module is used for capturing the current request sent to the server and calling the server request proxy service module to process the request when the webpage operation instruction is determined to contain the request sent to the server;
the server request proxy service module is used for acquiring corresponding server request record data based on a current webpage operation instruction or current request information, acquiring server return data contained in the server request record data, taking the server return data as the return data requested to the server at this time, and returning the server return data to the webpage;
and the external environment audio and video data playing module is used for playing audio and/or video data contained in the external environment data in the webpage operation process.
12. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the method of any one of claims 1 to 7 or which, when being executed by a processor, carries out the steps of the method of any one of claims 8 to 9.
CN202010651352.9A 2020-07-08 2020-07-08 Method and device for recording and playing back webpage operation process Pending CN112148571A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010651352.9A CN112148571A (en) 2020-07-08 2020-07-08 Method and device for recording and playing back webpage operation process

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010651352.9A CN112148571A (en) 2020-07-08 2020-07-08 Method and device for recording and playing back webpage operation process

Publications (1)

Publication Number Publication Date
CN112148571A true CN112148571A (en) 2020-12-29

Family

ID=73888248

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010651352.9A Pending CN112148571A (en) 2020-07-08 2020-07-08 Method and device for recording and playing back webpage operation process

Country Status (1)

Country Link
CN (1) CN112148571A (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112835776A (en) * 2021-02-22 2021-05-25 广州虎牙科技有限公司 Page event reproduction method, page event acquisition method, page event reproduction device and electronic equipment
CN113342629A (en) * 2021-06-08 2021-09-03 微民保险代理有限公司 Operation track restoration method and device, computer equipment and storage medium
CN113821748A (en) * 2021-09-26 2021-12-21 杭州米络星科技(集团)有限公司 Data recording method based on webpage, server, electronic equipment and medium
CN115357820A (en) * 2022-10-17 2022-11-18 北京大学 Digital object packaging and entity access method and system based on record playback
CN117632885A (en) * 2024-01-25 2024-03-01 太平金融科技服务(上海)有限公司 Resource synchronization method, device, equipment and medium in backtracking system

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104714948A (en) * 2013-12-11 2015-06-17 部落邦(北京)科技有限责任公司 Method, system and thermodynamic diagram display device for replaying user web page operation behavior
US20170109327A1 (en) * 2015-05-20 2017-04-20 Shenzhen Skyworth-Rgb Electronic Co., Ltd Method and system for webpage processing
CN106897347A (en) * 2016-08-15 2017-06-27 阿里巴巴集团控股有限公司 A kind of web page display method, Action Events recording method and device
CN110324410A (en) * 2019-06-18 2019-10-11 中国南方电网有限责任公司 Initiate method, apparatus, computer equipment and the storage medium of web-page requests

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104714948A (en) * 2013-12-11 2015-06-17 部落邦(北京)科技有限责任公司 Method, system and thermodynamic diagram display device for replaying user web page operation behavior
US20170109327A1 (en) * 2015-05-20 2017-04-20 Shenzhen Skyworth-Rgb Electronic Co., Ltd Method and system for webpage processing
CN106897347A (en) * 2016-08-15 2017-06-27 阿里巴巴集团控股有限公司 A kind of web page display method, Action Events recording method and device
CN110324410A (en) * 2019-06-18 2019-10-11 中国南方电网有限责任公司 Initiate method, apparatus, computer equipment and the storage medium of web-page requests

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112835776A (en) * 2021-02-22 2021-05-25 广州虎牙科技有限公司 Page event reproduction method, page event acquisition method, page event reproduction device and electronic equipment
CN113342629A (en) * 2021-06-08 2021-09-03 微民保险代理有限公司 Operation track restoration method and device, computer equipment and storage medium
CN113342629B (en) * 2021-06-08 2023-03-07 微民保险代理有限公司 Operation track restoration method and device, computer equipment and storage medium
CN113821748A (en) * 2021-09-26 2021-12-21 杭州米络星科技(集团)有限公司 Data recording method based on webpage, server, electronic equipment and medium
CN113821748B (en) * 2021-09-26 2023-11-07 杭州米络星科技(集团)有限公司 Webpage-based data recording method, server, electronic equipment and medium
CN115357820A (en) * 2022-10-17 2022-11-18 北京大学 Digital object packaging and entity access method and system based on record playback
CN115357820B (en) * 2022-10-17 2023-01-13 北京大学 Digital object packaging and entity access method and system based on record playback
CN117632885A (en) * 2024-01-25 2024-03-01 太平金融科技服务(上海)有限公司 Resource synchronization method, device, equipment and medium in backtracking system
CN117632885B (en) * 2024-01-25 2024-04-16 太平金融科技服务(上海)有限公司 Resource synchronization method, device, equipment and medium in backtracking system

Similar Documents

Publication Publication Date Title
CN112148571A (en) Method and device for recording and playing back webpage operation process
EP3457295B1 (en) Method for recording, editing and reproduction of computer session
US8306195B2 (en) Visual test automation tool for message-based applications, web applications and SOA systems
WO2021088724A1 (en) Testing method and apparatus
CN111818123B (en) Network front-end remote playback method, device, equipment and storage medium
US8135572B2 (en) Integrated debugger simulator
EP2291745A2 (en) Systems and methods for remote tracking and replay of user interaction with a webpage
JP2006018827A (en) Smart user interface record and reproduction framework
CN111488259B (en) Recording method for webpage and playback method for recorded file
CN112148573A (en) Method and device for recording and playing back webpage operation process
CN103678487A (en) Method and device for generating web page snapshot
CN111078519A (en) Method and device for backtracking abnormal monitoring behaviors and electronic equipment
WO2012086217A1 (en) Operation log collection method and device
CN111930703A (en) Automatic log file capturing method and device and computer equipment
CN113987393A (en) Web page operation recorder, system, device and method
CN112131085A (en) Method, system and device for recording and playing back Internet business process
JP2005258877A (en) Operation recording/reproducing method in web synchronous system
CN113485909A (en) Test method, test device, computing device, and medium
CN110837467B (en) Software testing method, device and system
CN111475423A (en) Data entry method and device, electronic equipment and readable storage medium
KR101111956B1 (en) System for providing substance about monitoring of computing device and method thereof
CN113051095B (en) Method and device for reproducing operation errors of client, electronic equipment and storage medium
Horsman et al. A forensic exploration of the Microsoft Windows 10 timeline
CN100410921C (en) Apparatus and method for reproducing content and information storage medium therefor
CN109101429A (en) A kind of method and device of the browser page debugging of set-top box

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
CB02 Change of applicant information

Country or region after: China

Address after: 266041 room 602, unit 3, building 19, Jingyuan xinju, 1046 Jinshui Road, Licang District, Qingdao City, Shandong Province

Applicant after: Qingdao Huazi Biotechnology Co.,Ltd.

Address before: 266041 room 602, unit 3, building 19, Jingyuan xinju, 1046 Jinshui Road, Licang District, Qingdao City, Shandong Province

Applicant before: Qingdao Window Technology Co.,Ltd.

Country or region before: China

CB02 Change of applicant information