CN118013143A - Page loading method and device, electronic equipment and readable storage medium - Google Patents

Page loading method and device, electronic equipment and readable storage medium Download PDF

Info

Publication number
CN118013143A
CN118013143A CN202410139470.XA CN202410139470A CN118013143A CN 118013143 A CN118013143 A CN 118013143A CN 202410139470 A CN202410139470 A CN 202410139470A CN 118013143 A CN118013143 A CN 118013143A
Authority
CN
China
Prior art keywords
page
target
input
pages
acquiring
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
CN202410139470.XA
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.)
Du Xiaoman Technology Beijing Co Ltd
Original Assignee
Du Xiaoman Technology Beijing 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 Du Xiaoman Technology Beijing Co Ltd filed Critical Du Xiaoman Technology Beijing Co Ltd
Priority to CN202410139470.XA priority Critical patent/CN118013143A/en
Publication of CN118013143A publication Critical patent/CN118013143A/en
Pending legal-status Critical Current

Links

Landscapes

  • Information Transfer Between Computers (AREA)

Abstract

The invention provides a page loading method, a page loading device, electronic equipment and a readable storage medium, wherein the page loading method comprises the following steps: receiving a first input, wherein the first input is a first signal of a user opening a first page of software; in response to the first input, preloading a plurality of second pages with jumping relation with the first page in a hidden window, intercepting interface requests of the plurality of second pages, and storing a request sequence; receiving a second input, wherein the second input is a second signal for triggering a target second page, and the second signal is a signal for releasing the request sequence corresponding to the target second page; and responding to the second input, acquiring dynamic data of the target second page, and rendering and displaying the target second page. The invention solves the problems of poor timeliness of data, inaccurate data statistics and aggravated back-end service load in the existing preloading scheme.

Description

Page loading method and device, electronic equipment and readable storage medium
Technical Field
The present invention relates to the field of information processing technologies, and in particular, to a page loading method, a page loading device, an electronic device, and a readable storage medium.
Background
The method comprises the steps that after software is started, a predicted next-stage browsing page is preloaded, so that after a page loading request of a user is received, if the loaded page comprises a target page of the request, the loaded target page can be directly called to directly carry out output setting, and a loading step after the request is received is not needed, and the output speed of the page is improved.
The existing preloading mode has good page straightening effect, but causes the following problems:
(1) Data statistics are inaccurate: when the user does not access the page, the complete page is preloaded, all interfaces in the page are requested, the statistics of the embedded points of the page is inaccurate, and the PV (page view) is multiplied and cannot reflect real data.
(2) Increasing the back-end link load: the access amount of all interfaces in the preloaded page increases dramatically, so that the back-end link of the whole interface is overloaded, which threatens the stability of the service.
(3) The real-time property of the data cannot be ensured: the time of preloading the page deviates from the time of the real access of the user, and when the time-efficiency requirement of the page display on the data is high, the user can operate abnormally on the page with the data expiration.
Disclosure of Invention
In view of this, the embodiments of the present invention provide a page loading method, apparatus, electronic device, and readable storage medium, so as to solve the problems of poor pre-loading data timeliness, inaccurate data statistics, and aggravated back-end service load.
According to an aspect of the present invention, there is provided a page loading method, including:
receiving a first input, wherein the first input is a first signal of a user opening a first page of software;
in response to the first input, preloading a plurality of second pages with jumping relation with the first page in a hidden window, intercepting interface requests of the plurality of second pages, and storing a request sequence;
receiving a second input, wherein the second input is a release signal for triggering a request sequence corresponding to a second page of a release target;
and responding to the second input, acquiring dynamic data of the target second page, and rendering and displaying the target second page.
Optionally, the preloading, in the hidden window, a number of second pages having a skip relation with the first page, and intercepting interface requests of the number of second pages, and storing a request sequence, in response to the first input, includes:
Acquiring a hypertext markup language of the first page, analyzing and acquiring static resources in the first page, executing page logic in the first page, and confirming a plurality of second pages with jump relation with the first page;
acquiring the preloading state information of the second page;
Intercepting a plurality of interface requests of the second page, and storing the request sequence corresponding to the interface requests.
Optionally, the responding to the second input, acquiring the dynamic data of the target second page, rendering and displaying the target second page, and includes:
receiving a page identifier of the target second page, responding to the page identifier of the target second page, acquiring the request sequence corresponding to the target second page, and acquiring dynamic data of the target second page;
and rendering and displaying the target second page according to the dynamic data of the target second page.
Optionally, before the hiding window preloads a plurality of second pages having a jump relationship with the first page and intercepts a plurality of interface requests of the second pages, the method further includes:
receiving a third input, wherein the third input is category information of the first page;
Responding to the third input, and under the condition that the first page is a software home page, the second pages are next-level pages with a jump relation with the home page; and under the condition that the first page is not a software head page, the plurality of second pages are next-level pages and/or previous-level pages which have a jump relation with the head page.
According to a second aspect of the present invention, there is provided a page loading apparatus comprising:
The first receiving module is used for receiving a first input, wherein the first input is a first signal of opening a first page of software by a user;
The processing module is used for responding to the first input, preloading a plurality of second pages with jumping relation with the first page in the hidden window, intercepting a plurality of interface requests of the second pages and storing a request sequence;
The second receiving module is used for receiving a second input, wherein the second input is a release signal for triggering a request sequence corresponding to a second page of a release target;
and the rendering module is used for responding to the second input, acquiring the dynamic data of the target second page, and rendering and displaying the target second page.
Optionally, the processing module includes:
the confirming module is used for acquiring the hypertext markup language of the first page, analyzing and acquiring static resources in the first page, executing page logic in the first page, and confirming a plurality of second pages with jump relation with the first page;
the acquisition module is used for acquiring the preloading state information of the second page;
And the storage module is used for intercepting a plurality of interface requests of the second page and storing the request sequence corresponding to the interface requests.
Optionally, the rendering module includes:
the third receiving module is used for receiving the page identification of the target second page, responding to the page identification of the target second page, acquiring the request sequence corresponding to the target second page, and acquiring the dynamic data of the target second page;
And the rendering sub-module is used for rendering and displaying the target second page according to the dynamic data of the target second page.
Optionally, the page loading device further includes:
The fourth receiving module is used for receiving a third input, and the third input is category information of the first page;
The selecting module responds to the third input, and when the first page is a first page of software, a plurality of second pages are next-level pages with a jump relation with the first page; and under the condition that the first page is not a software head page, the plurality of second pages are next-level pages and/or previous-level pages which have a jump relation with the head page.
According to a third aspect of the present invention, there is provided an electronic device comprising:
a processor; and
A memory in which a program is stored,
Wherein the program comprises instructions which, when executed by a processor, cause the processor to perform the method according to any of the first aspects of the invention.
According to a fourth aspect of the present invention there is provided a non-transitory computer readable storage medium storing computer instructions for causing a computer to perform the method according to any one of the first aspects of the present invention.
According to one or more technical schemes provided by the embodiment of the invention, a plurality of second pages with a jump relation with a current first page are acquired, the second pages are preloaded, request sequences for storing the second pages are intercepted and designated, when a user triggers a page, the request sequences of target second pages are released, and dynamic data of the target second pages are updated for rendering and displaying. On the basis of ensuring the page loading performance optimization effect, the method has the advantages that the time consumption for acquiring dynamic data is only contained in the page loading time perceived by a user, the method is greatly optimized compared with a non-preloading scheme, and meanwhile, the problems of poor data timeliness, inaccurate data statistics and aggravated back-end service load in the existing preloading scheme are solved.
Drawings
Further details, features and advantages of the invention are disclosed in the following description of exemplary embodiments with reference to the following drawings, in which:
FIG. 1 illustrates a flow chart of a variety of page loading methods;
FIG. 2 illustrates a flow chart of a page loading method according to an exemplary embodiment of the invention;
FIG. 3 illustrates a page load implementation diagram according to an exemplary embodiment of the present invention;
FIG. 4 illustrates a flowchart of an intercept and release request sequence according to an exemplary embodiment of the present invention;
FIG. 5 shows a schematic block diagram of a page loading apparatus according to an exemplary embodiment of the present invention;
fig. 6 shows a block diagram of an exemplary electronic device that can be used to implement an embodiment of the invention.
Detailed Description
Embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. While the invention is susceptible of embodiment in the drawings, it is to be understood that the invention may be embodied in various forms and should not be construed as limited to the embodiments set forth herein, but rather are provided to provide a more thorough and complete understanding of the invention. It should be understood that the drawings and embodiments of the invention are for illustration purposes only and are not intended to limit the scope of the present invention.
It should be understood that the various steps recited in the method embodiments of the present invention may be performed in a different order and/or performed in parallel. Furthermore, method embodiments may include additional steps and/or omit performing the illustrated steps. The scope of the invention is not limited in this respect.
The term "including" and variations thereof as used herein are intended to be open-ended, i.e., including, but not limited to. The term "based on" is based at least in part on. The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments. Related definitions of other terms will be given in the description below. It should be noted that the terms "first," "second," and the like herein are merely used for distinguishing between different devices, modules, or units and not for limiting the order or interdependence of the functions performed by such devices, modules, or units.
It should be noted that references to "one", "a plurality" and "a plurality" in this disclosure are intended to be illustrative rather than limiting, and those skilled in the art will appreciate that "one or more" is intended to be construed as "one or more" unless the context clearly indicates otherwise.
The names of messages or information interacted between the devices in the embodiments of the present invention are for illustrative purposes only and are not intended to limit the scope of such messages or information.
The following describes the scheme of the present invention with reference to the drawings, and the technical scheme provided by the embodiment of the present invention is described in detail through specific embodiments and application scenarios thereof.
As shown in FIG. 1, for rendering of a non-preloaded page, the page loading mode without the preloading mode consumes longer time, static resources such as hypertext markup language html, css/JS and the like are required to be acquired, a JS file is loaded and executed, then a rear-end interface acquires dynamic data, rendering of the page is performed, the whole process consumes longer time, a user is required to wait, and the process from the user triggering of an entry to complete rendering of the page is the page loading time perceived by the user. The JavaScript (JS) is a scripting language widely used for web page development. Cascading style sheets (css, english holonomy: CASCADING STYLE SHEETS) are a type of computer language used to represent file styles such as HTML (an application of standard generalized markup language) or XML (a subset of standard generalized markup language).
The existing preloading mode is to preload the predicted next-level browsing page after the software is started, namely, preloading a plurality of second pages with jump relation, at this time, the software starts a hidden background webview to preload the next-level page in the background, the loading process is still to obtain hypertext markup language html, the loading execution JS file is carried out, and the step of obtaining dynamic data at the rear-end interface is carried out in the background. After receiving the page loading request of the user, the software is matched with the background webview of the corresponding page and is directly pushed to the foreground, so that the user can see the complete next-stage page. If the loaded page comprises the target page of the request, the loaded target page can be directly called to directly carry out output setting without going through a loading step after receiving the request, thereby realizing the output speed acceleration of the page. Wherein WebView is a core view class in the WebKit framework for managing interactions between WebFrame and WebFrameView classes. To embed web content in an application, only one WebView object needs to be created, attached to the window, and a load message sent to its main frame.
The preloading mode enables a user to only pass through the process of APP calling up the corresponding webview from the time of triggering the page entry to the time of seeing the complete page, so that the time consuming processes of html, static resource acquisition, js analysis and execution, dynamic data acquisition and the like are omitted, the effect of direct output can be achieved, and the page performance is greatly optimized. However, in this scheme, since the data in the page is obtained in advance, and the logic (such as access dotting) in the page is executed before the user actually triggers the page, the problems of poor data timeliness, inaccurate data statistics and aggravated back-end service load are caused.
In view of the foregoing, the present invention provides a page loading method, apparatus, electronic device and readable storage medium, where the page loading method is applied to any electronic device with a page loading function, and the electronic device includes but is not limited to: personal mobile terminal devices, computers or server devices, etc.
As shown in fig. 2, fig. 2 is a flow chart of a page loading method according to an embodiment of the present invention, where the method may include steps S201 to S204 as follows:
s201, receiving a first input, wherein the first input is a first signal of opening a first page of software by a user.
In this embodiment, the first page may be a home page after the software is started, or may be any page in the software running process. When the user opens the first page at the client, instruction information of the operation of opening the first page, namely the first input is generated, and secondly, the first input can also be an operation instruction generated when the first page is operated, wherein the first page can be a webpage or an application program, and can also be an APP of the mobile terminal.
S202, preloading a plurality of second pages with jumping relation with the first page in a hidden window in response to the first input, intercepting a plurality of interface requests of the second pages, and storing a request sequence.
In this embodiment, when a user opens the software or enters a certain page of the software, a second page which the user may enter next stage is prejudged, specifically, after the user opens a first page of the software, the user obtains a plurality of second pages corresponding to the behavior data embedded point information based on the behavior data embedded point information of the user on the first page.
For example, assuming that a first page of the user opening software is a commodity display page, based on a click operation of the user on the commodity display page, identifying whether the click operation includes a purchasing behavior, if so, the second page includes a payment accounting page, a payment result display page, and the like, and based on the click operation, the payment accounting page, the payment result display page, and the like are preloaded. At this time, the software starts a hidden background webview to preload a plurality of second pages in the background, the background webview obtains html files of the second pages, obtains static resources in the pages after analysis, and obtains preloaded js files.
The preloading is a way of reducing the webpage loading speed and providing user experience. And opening the hidden webview in advance to load the webpage which the user possibly accesses, and directly outputting the loaded window when the user really accesses the webpage, so as to achieve the effect of directly outputting the webpage.
In one embodiment, when executing step S202, the request sequence number of each second page may be obtained in combination with the preset interception tool based on the preloaded processing js file, and the obtained request sequence number of the second page may be stored in the target request sequence. At this time, the static contents of each second page except the dynamic data are loaded.
As a specific implementation manner, each second page to be preloaded is obtained through JSBridge methods, js files (JavaScript, script language files for web page development) of each second page are preloaded into the hidden window, and simultaneously, an AJAX (Asynchronous Javasript And XML, a web page development technology of an interactive web page application) request in each second page is also obtained in the preloading stage, so that the subsequent acquisition of XMLHttpRequest objects of the second page according to the AJAX request is facilitated, and the data of the target second page is dynamically updated.
JSBridge is a technique for communicating between a terminal application and an H5 page developed using HTML5 technology, JSBridge method can allow application developers to call JavaScript functions in native code.
Therefore, in this embodiment, JSBridge registers the Javascript function of the second page in the WebView of the first page, so that after receiving the first signal for opening the first page of the software, the WebView of the first page starts to pre-load js files of each second page, obtains data in the second page, and forms dynamically updated webpages quickly from the data of each second page.
S203, receiving a second input, wherein the second input is a release signal for triggering a request sequence corresponding to a second page of a release target.
In this embodiment, the release signal is a signal formed by a click signal or a selection signal input by the user, which is used to determine a target second page jumped by the first page.
S204, responding to the second input, acquiring dynamic data of the target second page, and rendering and displaying the target second page.
In this embodiment, according to a release signal for releasing a request sequence corresponding to a target second page, a next-stage second page entry is triggered, a page identifier of the target second page is matched to a corresponding hidden webview, and meanwhile, the hidden target second page is displayed by a JSBridge triggering onActive method, and onActive refers to a triggering method for activating and displaying the second page twice or more under the condition that the second page is hidden and opened. At this moment, the pre-loading processing js file in the target second page monitors onActive events, dynamically updates the target second page, and sends the target second page to the rendering interface for rendering through the send method, and at this time, the user can see the complete target second page.
In one embodiment of the present invention, S202, in response to the first input, preloading a plurality of second pages having a skip relationship with the first page in a hidden window, and intercepting interface requests of the plurality of second pages, and storing a request sequence, including:
S2021, acquiring a hypertext markup language of the first page, analyzing and acquiring static resources in the first page, executing page logic in the first page, and confirming a plurality of second pages with jump relation with the first page;
s2022, acquiring the preloading state information of the second page;
S2023, intercepting a plurality of interface requests of the second page, and storing the request sequence corresponding to the interface requests.
In this embodiment, after confirming a plurality of second pages having a skip relationship with the first page according to the page logic of the first page, the WebView of the first page starts to pre-load js files of the second pages, obtains data in the second pages, and forms dynamically updated webpages from the data of the second pages. Meanwhile, an interception means is used for intercepting and designating the interface request for storing the second page, and a request sequence corresponding to the interface request of the second page is generated.
As one implementation mode, a send method is used for sending the webpage of the second page, an interception function is set in the sending process, so that the sending process jumps to the interception function, the sent data is reserved in a designated hidden storage position, a file path for storing the data is reserved, and a request serial number of the second page is generated and stored.
In one embodiment of the present invention, S204, in response to the second input, the obtaining the dynamic data of the target second page, rendering and displaying the target second page, includes:
S2041, receiving a page identifier of the target second page, responding to the page identifier of the target second page, acquiring the request sequence corresponding to the target second page, and acquiring dynamic data of the target second page;
and S2042, rendering and displaying the target second page according to the dynamic data of the target second page.
In this embodiment, according to the release signal triggering the request sequence corresponding to the release target second page, the page identifier of the target second page corresponding to the release signal is determined, so that in order to avoid poor real-time performance of the preloaded dynamic data, after the target second page is determined, the preloaded target second page needs to be acquired and updated for rendering and displaying, so that the preloaded data statistics result is accurate.
As one implementation, the data of the target second page is dynamically updated through XMLHttpRequest, and after the target second page is hit, the preloaded target second page is sent to the rendering port. The adoption of the XMLHttpRequest function set ensures that a user sees data in real time on one hand, and avoids the increase of the number of the preloading interface requests on the other hand, so that the pressure caused by back-end service is relieved.
The method for acquiring the dynamic data is suitable for all scenes accessing the preloading function after being packaged, only the preloaded js file is needed to be introduced, secondary development is not needed, and the cost of information access is greatly saved. Meanwhile, the dynamic data acquisition means is decoupled from the technical stack developed by the H5 page, and can be applied to all the conditions of preloading pages.
In one embodiment of the present invention, S202, in response to the first input, before preloading a plurality of second pages having a skip relationship with the first page in the hidden window, and intercepting interface requests of the plurality of second pages, and before storing a request sequence, further includes:
s202a, receiving a third input, wherein the third input is category information of the first page;
S202b, responding to the third input, wherein when the first page is a software head page, a plurality of second pages are next-level pages with a jump relation with the head page; and under the condition that the first page is not a software head page, the plurality of second pages are next-level pages and/or previous-level pages which have a jump relation with the head page.
In this embodiment, according to the category information of the first page, it is determined whether the first page is the first page of the software, so as to determine the selection range of the second page.
In one embodiment, when the first page is a login page displayed first after the software is opened, the static resources in the login page are obtained by parsing according to the hypertext markup language of the login page, and page logic in the login page is executed, so that a second page which jumps after the login page is confirmed, for example, the second page is a software function page which jumps after the login is successful or an error promotion page which jumps after the login is failed.
In one embodiment, in the case that the first page is a functional page that is not first displayed after the software is opened, according to the hypertext markup language of the functional page, the static resources in the functional page are obtained by parsing, and page logic in the functional page is executed, so that a second page that jumps to the upper level or jumps to the lower level after the functional page is confirmed, for example, the functional page is a menu page, and the second page is a display page of an entry menu item or a display page of an exit menu item.
As an implementation manner, as shown in fig. 3, a user opens software to access a first page, confirms a plurality of second pages having a skip relation with the first page according to page logic displayed in the first page WebView, obtains a hypertext markup language (i.e. html file) of the second page, starts preloading js files of the second page in a hidden web page view of the first page, intercepts a request of preloading an interface by using an interception means, and specifies and stores interception contents to generate a request sequence corresponding to the interface request of the second page.
The preloading process of the second page is performed in a hidden mode, a user does not feel in the whole preloading process until a release signal triggering a request sequence corresponding to the target second page to be released is received, the stored request sequence is released, update data of the target second page is obtained, and page rendering of the target second page is performed.
As an implementation manner, as shown in fig. 4, when a user opens WebView of a first page of software at an APP end, determining a plurality of second pages having a skip relation with the first page according to page logic in the first page, preloading static resources of the second pages in a web page view WebView hidden in the first page, sending web pages of the second pages by adopting a send method in the preloading process, setting an interception function in the sending process, enabling the sending process to skip to the interception function, retaining the sent data in a designated hidden storage position, retaining a file path of the stored data, generating a request serial number of the second pages, storing the request serial number, and recording the preloading time preloadUsable Time of each second page in the storing process.
Then receiving a signal of clicking the target second page by a user, forwarding the clicked signal to a Proxy server Proxy through an encrypted tunnel, generating a release signal for triggering a request sequence corresponding to releasing the target second page, then taking out the request sequence of the target second page from a hidden storage position according to the release signal, dynamically updating data of the target second page by adopting XMLHttpRequest, rendering, and displaying the target second page to webview of an APP end.
According to the page loading method provided by the embodiment of the invention, a plurality of second pages with a jump relation with the current first page are acquired, the second pages are preloaded, the request sequences for storing the second pages are intercepted and designated, when a user triggers a page, the request sequences of the target second page are released, and the dynamic data of the target second page are updated for rendering and displaying. On the basis of ensuring the page loading performance optimization effect, the method has the advantages that the time consumption for acquiring dynamic data is only contained in the page loading time perceived by a user, the method is greatly optimized compared with a non-preloading scheme, and meanwhile, the problems of poor data timeliness, inaccurate data statistics and aggravated back-end service load in the existing preloading scheme are solved.
Corresponding to the above embodiment, referring to fig. 5, an embodiment of the present invention further provides a page loading device 500, including:
a first receiving module 501, configured to receive a first input, where the first input is a first signal that a user opens a first page of software;
The processing module 502 is used for preloading a plurality of second pages with jumping relation with the first page in a hidden window in response to the first input, intercepting interface requests of the plurality of second pages and storing a request sequence;
A second receiving module 503, configured to receive a second input, where the second input is a release signal that triggers a request sequence corresponding to a second page of a release target;
and the rendering module 504 is used for responding to the second input, acquiring the dynamic data of the target second page and rendering and displaying the target second page.
Optionally, the processing module 502 includes:
The confirmation module 5021 is configured to obtain a hypertext markup language of the first page, parse to obtain static resources in the first page, execute page logic in the first page, and confirm a plurality of second pages having a skip relationship with the first page;
an obtaining module 5022, configured to obtain preload state information of the second page;
And the storage module 5023 is used for intercepting a plurality of interface requests of the second page and storing the request sequence corresponding to the interface requests.
Optionally, the rendering module 504 includes:
A third receiving module 5041, configured to receive a page identifier of the target second page, obtain the request sequence corresponding to the target second page in response to the page identifier of the target second page, and obtain dynamic data of the target second page;
and the rendering submodule 5042 is used for rendering and displaying the target second page according to the dynamic data of the target second page.
Optionally, the page loading device 500 further includes:
A fourth receiving module 505, configured to receive a third input, where the third input is category information of the first page;
The selecting module 506 is configured to respond to the third input, where, in a case where the first page is a first page of software, the plurality of second pages are next-level pages having a skip relationship with the first page; and under the condition that the first page is not a software head page, the plurality of second pages are next-level pages and/or previous-level pages which have a jump relation with the head page.
The page loading device provided by the embodiment of the invention acquires a plurality of second pages with a jump relation with the current first page, preloads the second pages, intercepts and designates a request sequence for storing the second pages, releases the request sequence of a target second page when a user triggers the page, and updates dynamic data of the target second page for rendering and displaying. On the basis of ensuring the page loading performance optimization effect, the method has the advantages that the time consumption for acquiring dynamic data is only contained in the page loading time perceived by a user, the method is greatly optimized compared with a non-preloading scheme, and meanwhile, the problems of poor data timeliness, inaccurate data statistics and aggravated back-end service load in the existing preloading scheme are solved.
The exemplary embodiment of the invention also provides an electronic device, including: at least one processor; and a memory communicatively coupled to the at least one processor. The memory stores a computer program executable by the at least one processor for causing the electronic device to perform a method according to an embodiment of the invention when executed by the at least one processor.
The exemplary embodiments of the present invention also provide a non-transitory computer-readable storage medium storing a computer program, wherein the computer program, when executed by a processor of a computer, is for causing the computer to perform a method according to an embodiment of the present invention.
The exemplary embodiments of the invention also provide a computer program product comprising a computer program, wherein the computer program, when being executed by a processor of a computer, is for causing the computer to perform a method according to an embodiment of the invention.
Referring to fig. 6, a block diagram of an electronic device 600 that may be a server or a client of the present invention will now be described, which is an example of a hardware device that may be applied to aspects of the present invention. Electronic devices are intended to represent various forms of digital electronic computer devices, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other suitable computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular telephones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be exemplary only, and are not meant to limit implementations of the inventions described and/or claimed herein.
As shown in fig. 6, the electronic device 600 includes a computing unit 601 that can perform various appropriate actions and processes according to a computer program stored in a Read Only Memory (ROM) 602 or a computer program loaded from a storage unit 608 into a Random Access Memory (RAM) 603. In the RAM 603, various programs and data required for the operation of the electronic device 600 can also be stored. The computing unit 601, ROM 602, and RAM 603 are connected to each other by a bus 604. An input/output (I/O) interface 605 is also connected to bus 604.
A number of components in the electronic device 600 are connected to the I/O interface 605, including: an input unit 606, an output unit 607, a storage unit 608, and a communication unit 609. The input unit 606 may be any type of device capable of inputting information to the electronic device 600, and the input unit 606 may receive input numeric or character information and generate key signal inputs related to user settings and/or function controls of the electronic device. The output unit 607 may be any type of device capable of presenting information and may include, but is not limited to, a display, speakers, video/audio output terminals, vibrators, and/or printers. Storage unit 608 may include, but is not limited to, magnetic disks, optical disks. The communication unit 609 allows the electronic device 600 to exchange information/data with other devices through a computer network, such as the internet, and/or various telecommunications networks, and may include, but is not limited to, modems, network cards, infrared communication devices, wireless communication transceivers and/or chipsets, such as bluetooth (TM) devices, wiFi devices, wiMax devices, cellular communication devices, and/or the like.
The computing unit 601 may be a variety of general and/or special purpose processing components having processing and computing capabilities. Some examples of computing unit 601 include, but are not limited to, a central processing module (CPU), a graphics processing module (GPU), various specialized Artificial Intelligence (AI) computing chips, various computing units running machine learning model algorithms, a Digital Signal Processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 601 performs the various methods and processes described above. For example, in some embodiments, the page loading method may be implemented as a computer software program tangibly embodied on a machine-readable medium, such as storage unit 608. In some embodiments, part or all of the computer program may be loaded and/or installed onto the electronic device 600 via the ROM 602 and/or the communication unit 609. In some embodiments, the computing unit 601 may be configured to perform the page loading method by any other suitable means (e.g., by means of firmware).
Program code for carrying out methods of the present invention may be written in any combination of one or more programming languages. These program code may be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable page loading apparatus, such that the program code, when executed by the processor or controller, causes the functions/operations specified in the flowchart and/or block diagram to be implemented. The program code may execute entirely on the machine, partly on the machine, as a stand-alone software package, partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of the present invention, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. The machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
As used herein, the terms "machine-readable medium" and "computer-readable medium" refer to any computer program product, apparatus, and/or device (e.g., magnetic discs, optical disks, memory, programmable Logic Devices (PLDs)) used to provide machine instructions and/or data to a programmable processor, including a machine-readable medium that receives machine instructions as a machine-readable signal. The term "machine-readable signal" refers to any signal used to provide machine instructions and/or data to a programmable processor.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and pointing device (e.g., a mouse or trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user may be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic input, speech input, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a background component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such background, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), wide Area Networks (WANs), and the internet.
The computer system may include a client and a server. The client and server are typically remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other.

Claims (10)

1. A method for loading a page, comprising:
receiving a first input, wherein the first input is a first signal of a user opening a first page of software;
in response to the first input, preloading a plurality of second pages with jumping relation with the first page in a hidden window, intercepting interface requests of the plurality of second pages, and storing a request sequence;
receiving a second input, wherein the second input is a release signal for triggering a request sequence corresponding to a second page of a release target;
and responding to the second input, acquiring dynamic data of the target second page, and rendering and displaying the target second page.
2. The page loading method as recited in claim 1, wherein said preloading a number of second pages in a jumping relationship with said first page in a hidden window in response to said first input and intercepting interface requests for a number of said second pages, storing a sequence of requests, comprises:
Acquiring a hypertext markup language of the first page, analyzing and acquiring static resources in the first page, executing page logic in the first page, and confirming a plurality of second pages with jump relation with the first page;
acquiring the preloading state information of the second page;
Intercepting a plurality of interface requests of the second page, and storing the request sequence corresponding to the interface requests.
3. The page loading method as recited in claim 1, wherein the obtaining the dynamic data of the target second page in response to the second input, rendering and displaying the target second page, comprises:
receiving a page identifier of the target second page, responding to the page identifier of the target second page, acquiring the request sequence corresponding to the target second page, and acquiring dynamic data of the target second page;
and rendering and displaying the target second page according to the dynamic data of the target second page.
4. The page loading method as recited in claim 1, wherein in response to the first input, before preloading a number of second pages in a skip relation with the first page in the hidden window and intercepting interface requests of the number of second pages, storing a request sequence, further comprises:
receiving a third input, wherein the third input is category information of the first page;
Responding to the third input, and under the condition that the first page is a software home page, the second pages are next-level pages with a jump relation with the home page; and under the condition that the first page is not a software head page, the plurality of second pages are next-level pages and/or previous-level pages which have a jump relation with the head page.
5. A page loading apparatus, comprising:
The first receiving module is used for receiving a first input, wherein the first input is a first signal of opening a first page of software by a user;
The processing module is used for responding to the first input, preloading a plurality of second pages with jumping relation with the first page in the hidden window, intercepting a plurality of interface requests of the second pages and storing a request sequence;
The second receiving module is used for receiving a second input, wherein the second input is a release signal for triggering a request sequence corresponding to a second page of a release target;
and the rendering module is used for responding to the second input, acquiring the dynamic data of the target second page, and rendering and displaying the target second page.
6. The page loading device of claim 5, wherein the processing module comprises:
the confirming module is used for acquiring the hypertext markup language of the first page, analyzing and acquiring static resources in the first page, executing page logic in the first page, and confirming a plurality of second pages with jump relation with the first page;
the acquisition module is used for acquiring the preloading state information of the second page;
And the storage module is used for intercepting a plurality of interface requests of the second page and storing the request sequence corresponding to the interface requests.
7. The page loading device of claim 5, wherein the rendering module comprises:
the third receiving module is used for receiving the page identification of the target second page, responding to the page identification of the target second page, acquiring the request sequence corresponding to the target second page, and acquiring the dynamic data of the target second page;
And the rendering sub-module is used for rendering and displaying the target second page according to the dynamic data of the target second page.
8. The page loading device as recited in claim 5, further comprising:
The fourth receiving module is used for receiving a third input, and the third input is category information of the first page;
The selecting module responds to the third input, and when the first page is a first page of software, a plurality of second pages are next-level pages with a jump relation with the first page; and under the condition that the first page is not a software head page, the plurality of second pages are next-level pages and/or previous-level pages which have a jump relation with the head page.
9. An electronic device, comprising:
a processor; and
A memory in which a program is stored,
Wherein the program comprises instructions which, when executed by the processor, cause the processor to perform the method according to any of claims 1-4.
10. A non-transitory computer readable storage medium storing computer instructions for causing a computer to perform the method of any one of claims 1-4.
CN202410139470.XA 2024-01-31 2024-01-31 Page loading method and device, electronic equipment and readable storage medium Pending CN118013143A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202410139470.XA CN118013143A (en) 2024-01-31 2024-01-31 Page loading method and device, electronic equipment and readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202410139470.XA CN118013143A (en) 2024-01-31 2024-01-31 Page loading method and device, electronic equipment and readable storage medium

Publications (1)

Publication Number Publication Date
CN118013143A true CN118013143A (en) 2024-05-10

Family

ID=90943833

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202410139470.XA Pending CN118013143A (en) 2024-01-31 2024-01-31 Page loading method and device, electronic equipment and readable storage medium

Country Status (1)

Country Link
CN (1) CN118013143A (en)

Similar Documents

Publication Publication Date Title
US10003671B2 (en) Capturing and replaying application sessions using resource files
CN107368487B (en) Dynamic layout method, device and client for page components
US11119812B2 (en) Method and device for processing application program page according to a common interface container
US20110202854A1 (en) Metadata Capture for Screen Sharing
WO2020143159A1 (en) User interface processing method and device
JP5936103B2 (en) System, computer, method and program for calling Java method on client
US20210271456A1 (en) Child application development method and apparatus, computer device, and storage medium
US10541854B2 (en) Component loading based on user interactions
US10705858B2 (en) Automatic import of third party analytics
CN111782988A (en) Method, device, computer system and storage medium for determining source of application program
CN111813623A (en) Page monitoring method and device, electronic equipment and storage medium
US10725797B2 (en) Service-driven dynamic user interface technology
CN108319474B (en) Page information generation method, device and equipment
CN115309470A (en) Method, device and equipment for loading widgets and storage medium
CN111431767A (en) Multi-browser resource synchronization method and device, computer equipment and storage medium
CN113315829B (en) Client offline H5 page loading method and device, computer equipment and medium
CN110674435A (en) Page access method, server, terminal, electronic equipment and readable storage medium
CN112764746A (en) Data processing method and device, electronic equipment and storage medium
CN118013143A (en) Page loading method and device, electronic equipment and readable storage medium
CN113760274B (en) Front-end assembly logic injection method and device
CN115525305A (en) Data processing method, application starting method, device, computer equipment and storage medium
CN112596824A (en) Information interaction method and device, electronic equipment and storage medium
CN111767111A (en) Page data processing method and device, electronic equipment and storage medium
CN113791777A (en) Picture display method and device, computer readable storage medium and electronic equipment
CN109669737B (en) Application processing method, device, equipment and medium

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