CN109902248B - Page display method and device, computer equipment and readable storage medium - Google Patents

Page display method and device, computer equipment and readable storage medium Download PDF

Info

Publication number
CN109902248B
CN109902248B CN201910138773.9A CN201910138773A CN109902248B CN 109902248 B CN109902248 B CN 109902248B CN 201910138773 A CN201910138773 A CN 201910138773A CN 109902248 B CN109902248 B CN 109902248B
Authority
CN
China
Prior art keywords
page
target page
skeleton screen
target
server
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.)
Active
Application number
CN201910138773.9A
Other languages
Chinese (zh)
Other versions
CN109902248A (en
Inventor
刘俊启
沈航
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Baidu Netcom Science and Technology Co Ltd
Original Assignee
Beijing Baidu Netcom Science and 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 Beijing Baidu Netcom Science and Technology Co Ltd filed Critical Beijing Baidu Netcom Science and Technology Co Ltd
Priority to CN201910138773.9A priority Critical patent/CN109902248B/en
Publication of CN109902248A publication Critical patent/CN109902248A/en
Application granted granted Critical
Publication of CN109902248B publication Critical patent/CN109902248B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Information Transfer Between Computers (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The application provides a page display method, a page display device, computer equipment and a readable storage medium, wherein the method comprises the following steps: sending a resource request; the resource request is used for acquiring a target page; in a time interval between sending the resource request and obtaining the target page, inquiring and displaying a skeleton screen page corresponding to the target page; the skeleton screen page corresponding to the target page is generated according to the structure of the target page when the target page is accessed historically; and when the target page is acquired, displaying the target page and hiding the skeleton screen page. The method can display the skeleton screen page corresponding to the target page in advance before the target page is loaded unsuccessfully, so that a user can know the framework corresponding to the target page in advance, the user is prevented from being in a waiting state or a loading state all the time, and the use experience of the user can be improved.

Description

Page display method and device, computer equipment and readable storage medium
Technical Field
The present application relates to the field of terminal technologies, and in particular, to a page display method and apparatus, a computer device, and a readable storage medium.
Background
With the continuous development of terminal technology, various mobile devices (mobile phones, tablet computers and the like) are continuously popularized, and the mobile internet becomes a main way for users to acquire information, so that how to optimize the searching and browsing experience of the mobile device side is of great importance. However, in optimizing the search and browsing experience, the applicant finds that, due to different factors such as sites, networks and the like, the following problems may exist in the process of opening a webpage by a user: the loading speed of the web page is slow, the loading of the web page is wrong, only partial elements are loaded, and the like.
In the prior art, the problem of slow loading speed is mainly solved by the following two ways: in the first mode, the background color of the browsing kernel is displayed in the loading process of the webpage, such as white screen display; in the second mode, during the loading process of the webpage, a progress bar is displayed, such as a "loading" prompt.
However, in the above two ways, before the web page is loaded, the display interface is always in the loading state, that is, the user is always in the loading state or the waiting state, at this time, the search and browsing experience of the user still cannot be improved, and even an excessive prompt may be caused to the user.
Disclosure of Invention
The application provides a page display method, a page display device, computer equipment and a readable storage medium, so that a skeleton screen page corresponding to a target page is displayed in advance before the target page is loaded unsuccessfully, a user can know a framework corresponding to the target page in advance conveniently, the user is prevented from being in a waiting state or a loading state all the time, and the use experience of the user can be improved. In addition, the skeleton screen page is generated according to the framework of the target page, so that the skeleton screen page is matched with the real content of the target page, the searching and browsing experience of a user can be improved, and the technical problems that in the prior art, before the webpage is loaded and obtained, the display interface is always in a loading state, and the searching and browsing experience of the user is reduced are solved.
An embodiment of a first aspect of the present application provides a page display method, including:
sending a resource request; the resource request is used for acquiring a target page;
in a time period between the resource request is sent and the target page is obtained, inquiring and displaying a skeleton screen page corresponding to the target page; the skeleton screen page corresponding to the target page is generated according to the framework of the target page when the target page is accessed historically;
and when the target page is acquired, displaying the target page and hiding the skeleton screen page.
According to the page display method, the resource request is sent; the method comprises the steps that a resource request is used for obtaining a target page, and then a skeleton screen page corresponding to the target page is inquired and displayed in a time interval between the resource request is sent and the target page is obtained; and finally, when the target page is obtained, displaying the target page and hiding the skeleton screen page. Therefore, the skeleton screen page corresponding to the target page can be displayed in advance before the target page is loaded unsuccessfully, so that a user can know the framework corresponding to the target page in advance, the user is prevented from being in a waiting state or a loading state all the time, and the use experience of the user can be improved. In addition, the skeleton screen page is generated according to the framework of the target page, so that the skeleton screen page is matched with the real content of the target page, and the searching and browsing experience of a user can be improved.
An embodiment of a second aspect of the present application provides a page display apparatus, including:
a sending module, configured to send a resource request; the resource request is used for acquiring a target page;
the query module is used for querying and displaying a skeleton screen page corresponding to the target page in a time period between the resource request is sent and the target page is obtained; the skeleton screen page corresponding to the target page is generated according to the framework of the target page when the target page is accessed historically;
and the display module is used for displaying the target page and hiding the skeleton screen page when the target page is acquired.
The page display device of the embodiment of the application sends the resource request; the method comprises the steps that a resource request is used for obtaining a target page, and then a skeleton screen page corresponding to the target page is inquired and displayed in a time interval between the resource request is sent and the target page is obtained; and finally, when the target page is obtained, displaying the target page and hiding the skeleton screen page. Therefore, before the target page is loaded unsuccessfully, the skeleton screen page corresponding to the target page can be displayed in advance, so that a user can know the framework corresponding to the target page in advance, the user is prevented from being in a waiting state or a loading state all the time, and the use experience of the user can be improved. In addition, the skeleton screen page is generated according to the framework of the target page, so that the skeleton screen page is matched with the real content of the target page, and the searching and browsing experience of a user can be improved.
An embodiment of a third aspect of the present application provides a computer device, including: the page display method comprises a memory, a processor and a computer program stored on the memory and capable of running on the processor, wherein when the processor executes the program, the page display method is realized.
An embodiment of a fourth aspect of the present application provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the page display method as set forth in the embodiment of the first aspect of the present application.
Additional aspects and advantages of the present application will be set forth in part in the description which follows and, in part, will be obvious from the description, or may be learned by practice of the present application.
Drawings
The foregoing and/or additional aspects and advantages of the present application will become apparent and readily appreciated from the following description of the embodiments, taken in conjunction with the accompanying drawings of which:
fig. 1 is a schematic flowchart of a page display method according to an embodiment of the present application;
fig. 2 is a schematic flowchart of a page display method according to a second embodiment of the present application;
fig. 3 is a schematic flowchart of a page display method according to a third embodiment of the present application;
fig. 4 is a schematic flowchart of a page display method according to a fourth embodiment of the present application;
fig. 5 is a schematic flowchart of a page display method according to a fifth embodiment of the present application;
FIG. 6 is a schematic view of a skeletal screen page in an embodiment of the present application;
FIG. 7 is a schematic diagram of a target page in an embodiment of the present application;
fig. 8 is a schematic flowchart of a page display method according to a sixth embodiment of the present application;
fig. 9 is a schematic flowchart of a page display method according to a seventh embodiment of the present application;
fig. 10 is a schematic flowchart of a page display method according to an eighth embodiment of the present application;
fig. 11 is a schematic flowchart of a page display method according to a ninth embodiment of the present application;
FIG. 12 is a first schematic diagram illustrating an interaction process between a client and a server according to an embodiment of the present application;
FIG. 13 is a schematic structural diagram of a page display system according to an embodiment of the present application;
FIG. 14 is a diagram illustrating a second interaction process between the client and the server according to an embodiment of the present application;
fig. 15 is a schematic structural diagram of a page display device according to a tenth embodiment of the present application;
fig. 16 is a schematic structural diagram of a page display device according to an eleventh embodiment of the present application;
FIG. 17 illustrates a block diagram of an exemplary computer device suitable for use in implementing embodiments of the present application.
Detailed Description
Reference will now be made in detail to embodiments of the present application, examples of which are illustrated in the accompanying drawings, wherein like or similar reference numerals refer to the same or similar elements or elements having the same or similar function throughout. The embodiments described below with reference to the drawings are exemplary and intended to be used for explaining the present application and should not be construed as limiting the present application.
With the continuous development of terminal technology, various mobile devices (mobile phones, tablet computers and the like) are continuously popularized, and the mobile internet becomes a main way for users to acquire information, so that how to optimize the searching and browsing experience of the mobile device side is of great importance.
Currently, when optimizing search and browsing experience, there are three limitations:
ecological standard factors: the whole search ecology is based on the Web ecology, the Web ecology depends on the World Wide Web (W3C for short) standard, namely browsing kernel, the loading process of the webpage is standardized, and the optimization space is limited.
Content source difference factor: when the user uses mobile search, the search engine carries out query matching according to the requirements of the user and recommends a group of search results with highest relevance to the user. However, due to the diversity of content sources, the following problems may exist: 1) the problem of deployment of web site servers leads to slow connection speed in some networks, for example, users moving in China access sites in Unicom China; 2) geographic location issues, such as users in china visiting foreign websites; 3) the website self-framework problem, for example, the website does not perform content optimization on the mobile device, and the mobile device is slow in loading or displaying speed due to the fact that a large image, a moving image and other memory occupy large resources.
Network factors: in the use process of the mobile equipment, the network environment is not stable for the random mobility of the user, for example, the network signal is good and bad.
In summary, the applicant believes that, in a mobile device, due to the influence of factors such as ecology, sites and networks, the following problems may exist in the process of opening a webpage: the loading speed of the web page is slow, the loading of the web page is wrong, only partial elements are loaded, and the like.
In the prior art, the problem of slow loading speed is mainly solved by the following three ways: in the first mode, the background color of the browsing kernel is displayed in the loading process of the webpage, such as white screen display; in the second mode, in the process of loading the webpage, a progress bar is displayed, such as a 'loading in progress' prompt; in the third mode, for the webpage with the definite content format, the false graph is used as the skeleton of the real content of the webpage, and in the loading process of the webpage, the false graph is firstly displayed, and when the webpage is loaded, the real webpage is displayed.
However, before the web page is loaded, the display interface is always in the loading state, that is, the user is always in the loading state or the waiting state, at this time, the search and browsing experience of the user still cannot be improved, and even an excessive prompt may be caused to the user.
The application mainly aims at the technical problem that in the prior art, the searching and browsing experience of a user is poor, and provides a page display method.
According to the page display method, the resource request is sent; the method comprises the steps that a resource request is used for obtaining a target page, and then a skeleton screen page corresponding to the target page is inquired and displayed in a time interval between the resource request is sent and the target page is obtained; and finally, when the target page is obtained, displaying the target page and hiding the skeleton screen page. Therefore, the skeleton screen page corresponding to the target page can be displayed in advance before the target page is loaded unsuccessfully, so that a user can know the framework corresponding to the target page in advance, the user is prevented from being in a waiting state or a loading state all the time, and the use experience of the user can be improved. In addition, the skeleton screen page is generated according to the framework of the target page, so that the skeleton screen page is matched with the real content of the target page, and the searching and browsing experience of a user can be improved.
Page display methods, apparatuses, computer devices, and readable storage media according to embodiments of the present application are described below with reference to the accompanying drawings.
Fig. 1 is a schematic flowchart of a page display method according to an embodiment of the present application.
The page display method is exemplified by being configured in a page display device in the embodiments of the present application, and the page display device may be applied to any computer device, so that the computer device may perform a page display function.
The Computer device may be a Personal Computer (PC), a cloud device, a mobile device, and the like, and the mobile device may be a hardware device having various operating systems, touch screens, and/or display screens, such as a mobile phone, a tablet Computer, a Personal digital assistant, a wearable device, and an in-vehicle device.
As shown in fig. 1, the page display method includes the steps of:
step 101, sending a resource request; the resource request is used for acquiring a target page.
The execution subject of the embodiment of the present application may specifically refer to a client running in a computer device. The client refers to a program corresponding to the server and providing local services for the user, such as a search Application (APP), a video APP, and the like.
In this embodiment of the application, a user may send a resource request through the client, for example, the user may input a network address, that is, an IP address, of a target page based on the client on a computer device to trigger the resource request, or the user may trigger the resource request by inputting a keyword, for example, the user may trigger a corresponding resource request by inputting a keyword corresponding to the target page, or the user may trigger a corresponding resource request by triggering a preset function option on a display interface of the client or triggering a hot zone, and the like, which is not limited herein. The input manner of the IP address or the keyword may include, but is not limited to, touch input (e.g., sliding, clicking, etc.), keyboard input, voice input, etc.
In the embodiment of the application, after the client side intercepts the resource request triggered by the user in an intercepting mode, the resource request can be sent to the server side so as to obtain the corresponding target page from the server side.
102, in a time interval between sending a resource request and obtaining a target page, inquiring and displaying a skeleton screen page corresponding to the target page; and the skeleton screen page corresponding to the target page is generated according to the structure of the target page when the target page is accessed historically.
In the embodiment of the present application, a Skeleton Screen (skeeleton Screen) page refers to a specific structure of a target page displayed at a client before page resources of the target page are not loaded, and is denoted as an architecture in the present application.
As a possible implementation manner, the skeleton screen page corresponding to the target page is generated according to the framework of the target page when the client accesses the target page historically, for example, the client accesses the target page 2 days ago, and after the client loads the target page, the corresponding skeleton screen page may be generated according to the framework of the target page. After the client generates the skeleton screen page, the client can send the skeleton screen page to the server for storage, so that when other clients access the target page, the skeleton screen page corresponding to the target page is obtained. Therefore, the skeleton screen page is stored at the server side, and resource sharing can be achieved.
As another possible implementation manner, after the client generates the skeleton screen page, the skeleton screen page may be stored locally, so that when the client accesses the target page next time, the client may directly obtain and display the corresponding skeleton screen page locally, and therefore, the client does not need to access the server, and query efficiency of the skeleton screen page is improved.
As another possible implementation manner, after the client generates the skeleton screen page, the skeleton screen page may be stored locally, so that after the client accesses the target page next time, the client may directly obtain and display the corresponding skeleton screen page locally, thereby improving the query efficiency of the skeleton screen page. Meanwhile, the client can also send the skeleton screen page to the server for storage, so that when other clients access the target page, the skeleton screen page corresponding to the target page is obtained, and therefore the skeleton screen page is stored at the server, and resource sharing can be achieved. In addition, when other clients access the target page, the corresponding skeleton screen page does not need to be regenerated, so that the resource occupation can be reduced, the real-time performance of skeleton screen page acquisition can be improved, and the browsing experience of the user can be improved.
In the embodiment of the application, after the client sends the resource request and before the client does not acquire the target page, the client can query to obtain the skeleton screen page corresponding to the target page. For example, in order to improve the efficiency of skeleton screen page query, the client may determine whether a skeleton screen page corresponding to the target page is stored locally, if so, directly obtain the skeleton screen page corresponding to the target page from the local, and if not, query the skeleton screen page corresponding to the target page from the server.
As a possible implementation manner, the resource request may carry a network identifier, such as an IP address, of the target page, and the client may query to obtain a skeleton screen page corresponding to the target page according to the network identifier carried in the resource request. For example, the client may store a corresponding relationship between a network identifier and a skeleton screen page, and/or the server may store a corresponding relationship between a network identifier and a skeleton screen page, and the client may query whether a skeleton screen page corresponding to a target page is stored locally according to the network identifier, if so, directly obtain the skeleton screen page corresponding to the target page from the local according to the network identifier, and if not, query the server according to the network identifier to obtain the skeleton screen page corresponding to the target page stored by the server.
It should be noted that, although the server may directly generate the corresponding skeleton screen page according to the target page, and the client queries and acquires the corresponding skeleton screen page after sending the resource request, the server generates the skeleton screen page corresponding to the target page, which has the following problems:
first, computational cost and bandwidth issues: because page resources in the internet are in the order of billions and are continuously increasing every day, for a server, the calculation amount of new data and the consumption of resources are large, the calculation cost is high, and the bandwidth occupation is high;
second, authenticity issues: some pages can be seen only after the user logs in, such as 163 mailbox, for such pages, the server cannot acquire the logged-in page resources, so that the server cannot generate a corresponding skeleton screen page;
thirdly, site anti-cheating problem: if the same server or the same group of servers frequently acquire data from the same page, the page can hit the data.
In the embodiment of the application, the client generates the corresponding skeleton screen page according to the architecture of the target page, so that the resource occupation of the server can be reduced, and the calculation cost can be reduced. Moreover, even for the page needing to be logged in, the client can obtain the corresponding page resource, so that the corresponding skeleton screen page can be generated, meanwhile, the attack and defense strategy of the site does not influence each client, and the effectiveness of the page display method can be improved. In addition, the client stores the generated skeleton screen page to the server, when other clients access the target page, the corresponding skeleton screen page can be directly acquired, the skeleton screen page does not need to be regenerated, the acquisition instantaneity of the skeleton screen page can be improved, and therefore the browsing experience of a user is improved.
And 103, displaying the target page and hiding the skeleton screen page when the target page is acquired.
In the embodiment of the application, when the client queries the skeleton screen page corresponding to the target page, the server can query the target page according to the network identifier of the target page carried in the resource request and return the target page to the client.
According to the page display method, the resource request is sent; the method comprises the steps that a resource request is used for obtaining a target page, and then a skeleton screen page corresponding to the target page is inquired and displayed in a time interval between the resource request is sent and the target page is obtained; and finally, when the target page is obtained, displaying the target page and hiding the skeleton screen page. Therefore, the skeleton screen page corresponding to the target page can be displayed in advance before the target page is loaded unsuccessfully, so that a user can know the framework corresponding to the target page in advance, the user is prevented from being in a waiting state or a loading state all the time, and the use experience of the user can be improved. In addition, the skeleton screen page is generated according to the framework of the target page, so that the skeleton screen page is matched with the real content of the target page, and the searching and browsing experience of a user can be improved.
As an application scenario, when a client accesses a target page historically, a corresponding skeleton screen page can be generated according to the structure of the target page. After the client generates the corresponding skeleton screen page, the skeleton screen page can be stored to the local part of the client, so that when the client accesses the target page next time, the skeleton screen page corresponding to the target page can be directly inquired and displayed from the locally stored data, and the inquiry efficiency of the skeleton screen page is improved. The above process is described in detail below with reference to fig. 2.
Fig. 2 is a schematic flowchart of a page display method according to a second embodiment of the present application.
As shown in fig. 2, the page display method may include the following sub-steps:
step 201, when the client accesses the target page historically, generating and storing a corresponding skeleton screen page according to the architecture of the target page.
As a possible implementation manner, after generating a skeleton screen page corresponding to a target page, a client may store a network identifier of the target page and the skeleton screen page correspondingly, that is, the client may store a corresponding relationship between the network identifier of the target page and the skeleton screen page.
Step 202, the client sends a resource request to the server to obtain a target page.
In the embodiment of the application, when the user wants to open the target page again according to the self requirement, the resource request can be sent to the server side through the client side so as to obtain the corresponding target page.
In step 203, the client queries and displays a skeleton screen page corresponding to the target page from the locally stored data in the time period between the sending of the resource request and the acquisition of the target page.
As a possible implementation manner, the resource request may carry a network identifier of the target page, and the client may query a correspondence between the network identifier and the skeleton screen page according to the network identifier carried in the resource request, so as to obtain the corresponding skeleton screen page. After the skeleton screen page is inquired, the skeleton screen page can be directly displayed on the display interface.
And 204, when the client acquires the target page, displaying the target page and hiding the skeleton screen page.
The execution process of step 204 may refer to the execution process of step 103 in the above embodiments, which is not described herein again.
According to the page display method, the skeleton screen page corresponding to the target page is generated and stored by the client, so that when the client accesses the target page next time, the skeleton screen page corresponding to the target page can be directly inquired from locally stored data, the inquiry efficiency of the skeleton screen page can be improved, the user can be prevented from being in a waiting state, and the search and browsing experience of the user is improved.
As another application scenario, when a client accesses a target page for the first time, the client does not store a skeleton screen page corresponding to the target page, and in order to normally load the skeleton screen page corresponding to the target page, the client may query the corresponding skeleton screen page from a server. Therefore, as another possible implementation manner of the embodiment of the present application, in order to implement resource sharing, after a certain client accesses a target page and generates a corresponding skeleton screen page according to a framework of the target page, the skeleton screen page may be sent to a server for storage, so that when other clients access the target page, the skeleton screen page corresponding to the target page may be queried and displayed from the server. The above process is described in detail below with reference to fig. 3.
Fig. 3 is a schematic flowchart of a page display method according to a third embodiment of the present application.
As shown in fig. 3, the page display method may include the steps of:
step 301, when the client accesses the target page historically, generating a corresponding skeleton screen page according to the architecture of the target page.
And step 302, the client sends the skeleton screen page corresponding to the target page to the server for storage.
As a possible implementation manner, after the client generates a skeleton screen page corresponding to the target page and sends the skeleton screen page to the server, the server may store the network identifier of the target page and the skeleton screen page correspondingly, that is, the server may store a corresponding relationship between the network identifier and the skeleton screen page.
Step 303, the other clients send resource requests to the server to obtain the target page.
And step 304, other clients inquire and display the skeleton screen page corresponding to the target page from the server in the time period between the resource request sending and the target page obtaining.
In the embodiment of the application, other clients may query the skeleton screen page corresponding to the target page from the server, for example, the server may be queried according to the network identifier of the target page, so as to obtain the skeleton screen page corresponding to the target page stored by the server.
Step 305, when other clients acquire the target page, displaying the target page and hiding the skeleton screen page.
According to the page display method, after the skeleton screen page corresponding to the target page is generated at the client, the skeleton screen page is sent to the server to be stored, so that when other clients access the target page for the first time, the corresponding skeleton screen page does not need to be generated, and resource occupation can be reduced.
As another application scenario, after the client generates a corresponding skeleton screen page and stores the skeleton screen page to the local of the client, if the user releases part of the memory in the display device according to the user's own requirements, for example, deletes the skeleton screen page corresponding to the target page, at this time, the skeleton screen page corresponding to the target page is not stored in the client. Therefore, in order to normally load the skeleton screen page corresponding to the target page, at this time, the client may query the corresponding skeleton screen page from the server. Therefore, as another possible implementation manner of the embodiment of the present application, in order to implement resource sharing, after a certain client accesses a target page and generates a corresponding skeleton screen page according to a framework of the target page, the skeleton screen page may be stored in both a local client and a server, so that when the client accesses the target page, it may be determined whether the skeleton screen page corresponding to the target page is stored locally, if so, the skeleton screen page corresponding to the target page is directly obtained locally, and if not, the skeleton screen page corresponding to the target page is queried from the server. The above process is described in detail below with reference to fig. 4.
Fig. 4 is a schematic flowchart of a page display method according to a fourth embodiment of the present application.
As shown in fig. 4, the page display method may include the steps of:
step 401, when the client accesses the target page historically, generating and storing a corresponding skeleton screen page according to the architecture of the target page.
As a possible implementation manner, after generating a skeleton screen page corresponding to a target page, a client may store a network identifier of the target page and the skeleton screen page correspondingly, that is, the client may store a corresponding relationship between the network identifier of the target page and the skeleton screen page.
And 402, the client sends the skeleton screen page corresponding to the target page to the server for storage.
As a possible implementation manner, after the client generates a skeleton screen page corresponding to the target page and sends the skeleton screen page to the server, the server may store the network identifier of the target page and the skeleton screen page correspondingly, that is, the server may store a corresponding relationship between the network identifier and the skeleton screen page.
In step 403, the client sends a resource request to the server to obtain a target page.
In step 404, the client determines whether the locally stored data has a skeleton screen page corresponding to the target page in the time period between sending the resource request and obtaining the target page, if so, step 405 is executed, and if not, step 406 is executed.
As a possible implementation manner, the resource request may carry a network identifier of a target page, and the client may query whether a skeleton screen page corresponding to the target page is stored locally according to the network identifier carried by the resource request, if so, directly query the skeleton screen page corresponding to the target page from the local according to the network identifier, and if not, query the server according to the network identifier, so as to obtain the skeleton screen page corresponding to the target page stored by the server.
And 405, directly inquiring and displaying a skeleton screen page corresponding to the target page from the local.
And 406, inquiring and displaying a skeleton screen page corresponding to the target page from the server side.
Step 407, when the client acquires the target page, displaying the target page and hiding the skeleton screen page.
According to the page display method, the skeleton screen pages corresponding to the target page are stored in the client locally and the server simultaneously, the situation that the skeleton screen pages cannot be inquired when data stored in the client is deleted can be prevented, the skeleton screen pages corresponding to the target page are inquired and obtained from the server, the corresponding skeleton screen pages do not need to be regenerated, resource occupation can be reduced, the real-time performance of obtaining the skeleton screen pages can be improved, and therefore browsing experience of a user is improved.
It should be noted that, the skeleton screen page is generated by the client according to the framework of the target page, and when the display device of the client is operated differently, the generated skeleton screen page may be different, for example, when the display parameters of the display device are different, such as the resolutions are different, the resolutions of the generated skeleton screen page are also different, that is, after the client generates the skeleton screen page and sends the skeleton screen page to the server for storage, the skeleton screen page stored in the server is only matched with the display device generating the skeleton screen page. Therefore, in the application, after the client acquires the skeleton screen page of the target page from the server, whether the model of the skeleton screen page is matched with the current display equipment of the user can be judged, if not, the occupied areas are typeset in the skeleton screen page according to the display parameters of the current display equipment, and therefore the display effect of the skeleton screen page is improved. The above process is described in detail below with reference to fig. 5.
Fig. 5 is a schematic flowchart of a page display method according to a fifth embodiment of the present application.
As shown in fig. 5, the page display method may include the steps of:
step 501, sending a resource request; the resource request is used for acquiring a target page.
In the embodiment of the present application, the resource request may carry a network identifier of a target page, for example, an IP address.
Step 502, inquiring the server side according to the network identifier carried by the resource request to obtain a skeleton screen page corresponding to the target page stored by the server side.
In the embodiment of the application, the server side stores the corresponding relationship between the network identifier and the skeleton screen page, so that after the network identifier carried by the resource request is determined, the corresponding relationship can be inquired, and the skeleton screen page corresponding to the target page is obtained.
Step 503, judging whether the model adapted to the skeleton screen page is matched with the current display device, if so, executing step 504, and if not, executing step 505.
In the embodiment of the application, after the client generates the skeleton screen page corresponding to the target page, the skeleton screen page, the network identifier corresponding to the target page and the model of the display device running the client (i.e., the model of the skeleton screen page adaptation) can be sent to the server, so that the server can correspondingly store the skeleton screen page obtained according to the target page, the corresponding network identifier and the model of the skeleton screen page adaptation.
In the embodiment of the application, after the client queries the skeleton screen page, the corresponding relationship can be queried to obtain the model suitable for the skeleton screen page, the model suitable for the skeleton screen page is matched with the current display device, the model suitable for the skeleton screen page is judged to be matched with the current display device, if yes, step 504 is executed, and if not, step 505 is executed.
And step 504, displaying the skeleton screen page through the display equipment.
In the embodiment of the application, when the model of the skeleton screen page adaptation is matched with the current display device, the skeleton screen page can be directly displayed through the display device.
And 505, typesetting each occupied area in the skeleton screen page according to the display parameters of the display equipment.
In the embodiment of the present application, occupied areas filled with gray scales are displayed in a page of the skeleton screen, as shown in fig. 6, where each occupied area in fig. 6 corresponds to a corresponding page element of the target page in fig. 7 one to one.
In the embodiment of the present application, the parameter indicating the parameter for obtaining the best display effect under the limitation of the display performance of the display device includes: resolution, margin, dot pitch, etc. It is understood that when the display parameters of the display devices are different, for example, the resolutions are different, the resolutions of the generated skeleton screen pages are also different. Therefore, in the embodiment of the application, in order to improve the display effect of the skeleton screen page, when the model of the skeleton screen page adaptation is not matched with the current display device, the layout of each occupied area in the skeleton screen page can be performed according to the display parameters of the display device.
As a possible implementation manner, when the content type of the placeholder area is different, the composition rule may be different, for example, when the content type of the placeholder area is a picture type, the composition rule may be zooming, and when the content type of the placeholder area is a text type, the composition rule may be adjusting the length or the number of words of each line, and re-determining the number of lines, and the like. Therefore, in the application, the corresponding occupied areas can be typeset according to the content types of the occupied areas, so that the typeset skeleton screen page is matched with the display parameters of the display equipment. And the content type of each occupied area is the content type of the page element corresponding to the corresponding occupied area.
Step 506, when the target page is obtained, displaying the target page and hiding the skeleton screen page.
The process of step 506 may refer to the process of step 103 in the above embodiments, which is not described herein again.
According to the page display method, the server side is inquired according to the network identification carried by the resource request, so that a skeleton screen page corresponding to a target page stored by the server side is obtained, whether the model of the skeleton screen page is matched with the current display equipment or not is judged, if yes, the skeleton screen page is displayed through the display equipment, and if not, each occupied area is typeset in the skeleton screen page according to the display parameters of the display equipment. Therefore, the display effect of the skeleton screen page can be improved, and the browsing experience of a user is improved.
As a possible implementation manner, in order to implement dynamic maintenance and real-time update on a skeleton screen page of a target page stored at a server, so as to ensure accuracy of the skeleton screen page stored at the server, after a client loads the target page, a corresponding skeleton screen page may be regenerated according to the target page, the generated skeleton screen page is compared with a skeleton screen page obtained by querying the server, whether the skeleton screen page is consistent with the skeleton screen page obtained by querying the server is judged, and if not, the skeleton screen page stored in the server is updated according to the skeleton screen page generated by the client. The above process is described in detail below with reference to fig. 8.
Fig. 8 is a schematic flowchart of a page display method according to a sixth embodiment of the present application.
As shown in fig. 8, after displaying the target page and hiding the skeleton screen page, the page display method may further include the steps of:
step 601, performing framework extraction on the displayed target page to obtain a skeleton screen page obtained by accessing the target page this time.
In the embodiment of the application, for a target page, the positions and the outlines of page elements can be extracted from top to bottom, and in a blank page, the outlines of the page elements are filled with gray scales at corresponding positions to obtain a skeleton screen page.
Step 602, comparing the skeleton screen page obtained by accessing the target page this time with the skeleton screen page obtained by querying the server; and the skeleton screen page stored at the server side is generated by the client side of the historical access target page and is sent to the server for storage.
Step 603, if the skeleton screen page obtained by accessing the target page at this time is different from the skeleton screen page obtained by querying the server, sending the skeleton screen page obtained by accessing the target page at this time and the network identifier of the target page to the server for updating and storing.
The server side is used for storing the skeleton screen page obtained by the current access of the target page and the corresponding network identification.
In the embodiment of the application, after the client extracts the skeleton screen page obtained by accessing the target page this time, if the skeleton screen page obtained by accessing the target page this time is different from the skeleton screen page obtained by querying the server, that is, when the skeleton screen page corresponding to the target page generated by the client is inconsistent with the skeleton screen page stored by the server, the skeleton screen page obtained by accessing the target page this time and the network identifier of the target page are sent to the server for updating and storing, so that the skeleton screen page of the target page stored by the server can be dynamically maintained and updated in real time, and the accuracy of the skeleton screen page stored by the server is ensured.
It can be understood that when the user is located in different regions, the required target page may be different, and therefore, the required skeleton screen page may be different. Therefore, in the present application, in order to provide customized search services for different users, after step 502, the queried skeleton screen pages may be further screened according to the region where each skeleton screen page is adapted, so as to retain the skeleton screen page in the region where the adapted display device is located, thereby further improving the processing efficiency. The above process is described in detail below with reference to fig. 9.
Fig. 9 is a flowchart illustrating a page display method according to a seventh embodiment of the present application.
As shown in fig. 9, after step 502, the page display method may further include the steps of:
and 701, screening the inquired skeleton screen pages according to the regions matched with the skeleton screen pages so as to reserve the skeleton screen pages matched with the regions where the display equipment is located.
In the embodiment of the present application, a geographic Position acquisition device, such as a Global Positioning System (GPS) and the like, may be built in the display device, and is used to acquire a region where the display device is located. After the client generates the skeleton screen page, the client can send the skeleton screen page, the corresponding network identifier and the region where the display device is located to the server, so that the server can correspondingly store the skeleton screen page, the corresponding network identifier and the region. After the client determines the network identifier of the target page carried by the resource request, the corresponding relation can be inquired from the server, the region where each framework screen page is adapted is determined, and each framework screen page is screened according to the region where the current display equipment is located so as to reserve the framework screen page of the region where the adapted display equipment is located.
And step 702, performing architecture extraction on the displayed target page to obtain a skeleton screen page obtained by accessing the target page this time.
In the embodiment of the application, for a target page, the positions and the outlines of page elements can be extracted from top to bottom, and in a blank page, the outlines of the page elements are filled with gray scales at corresponding positions to obtain a skeleton screen page.
Step 703, comparing the skeleton screen page obtained by accessing the target page this time with the skeleton screen page obtained by querying the server; and the skeleton screen page stored at the server side is generated by the client side of the historical access target page and is sent to the server for storage.
Step 704, if the skeleton screen page obtained by accessing the target page at this time is different from the skeleton screen page obtained by querying the server, sending the skeleton screen page obtained by accessing the target page at this time, the network identifier of the target page and the region where the display device is located to the server for updating and storing.
The server is used for storing the skeleton screen page obtained by accessing the target page, the corresponding network identification and the corresponding region.
In the embodiment of the application, after the client extracts the skeleton screen page obtained by accessing the target page this time, if the skeleton screen page obtained by accessing the target page this time is different from the skeleton screen page obtained by querying the server, that is, when the skeleton screen page corresponding to the target page generated by the client is inconsistent with the skeleton screen page stored by the server, the skeleton screen page obtained by accessing the target page this time, the network identifier of the target page and the region where the display device is located can be sent to the server for updating and storing, so that the dynamic maintenance and real-time updating of the skeleton screen page of the target page stored by the server can be realized, and the accuracy of the skeleton screen page stored by the server can be ensured.
As a possible implementation manner, the server side can also time the storage duration of the skeleton screen page, and when the time reaches the set storage duration, the stored skeleton screen page can be deleted, so that the resource occupation of the server side is saved. Wherein the storage time duration is set to be preset.
According to the page display method, when the skeleton screen page obtained by accessing the target page at this time is different from the skeleton screen page obtained by inquiring the server, the skeleton screen page obtained by accessing the target page at this time, the network identifier of the target page and the region where the display device is located are sent to the server to be updated and stored, and therefore dynamic maintenance and real-time updating of the skeleton screen page of the target page can be achieved, and accuracy of the skeleton screen page stored by the server is guaranteed.
It should be noted that, if any client does not access the target page, at this time, the server does not store the skeleton screen page corresponding to the target page, and therefore, in the embodiments of fig. 1 to 9, when the client queries the server according to the network identifier carried by the resource request and determines that the server does not store the skeleton screen page corresponding to the target page, the target page may be directly displayed. That is, after the client sends the resource request, the target page can be directly displayed when the client acquires the target page.
As a possible implementation manner, it may be determined whether a corresponding skeleton screen page needs to be pre-displayed before a target page is displayed according to dimensions such as opening speed and stability of the target page, specifically, whether the target page is abnormal in a historical access process, such as too slow loading speed, loading error, and the like, if so, it is determined that the corresponding skeleton screen page needs to be pre-displayed, at this time, the skeleton screen page corresponding to the target page may be queried and displayed to improve search and browsing experience of a user, if not, it indicates that the opening speed of the target page is fast, at this time, it is not necessary to pre-display the corresponding skeleton screen page, after a client sends a resource request, when the client acquires the target page, the client directly displays the corresponding target page, that is, when the client acquires the target page from a server, the target page can be directly displayed so as to improve the flexibility and the applicability of the page display method. The above process is explained in detail with reference to fig. 10.
Fig. 10 is a flowchart illustrating a page display method according to an eighth embodiment of the present application.
As shown in fig. 10, the page display method may include the steps of:
step 801, sending a resource request; the resource request is used for acquiring a target page.
Step 802, determining whether the target page has access abnormality in the history access process, if yes, executing step 803, and if not, executing step 805.
As a possible implementation manner, statistics and analysis may be performed according to historical loading data of a target page, and whether the target page is abnormal in a historical access process is determined, for example, when it is determined that the target page is too slow in a historical access process, and a loading error occurs in the historical access process according to the historical loading data, it is determined that the target page is abnormal in access in the historical access process, and at this time, a corresponding skeleton screen page needs to be displayed in advance, so step 803 may be executed, and when it is determined that the target page is faster in the historical access process, and no loading error occurs in the historical access process according to the historical loading data, it is determined that the target page is not abnormal in access in the historical access process, and at this time, it is not necessary to display the corresponding skeleton screen page in advance, and therefore step 805 may be executed.
As another possible implementation manner, a white list may also be preset, where the white list is used to record each page that does not need to display a skeleton screen page, that is, the white list is used to record a page that is normally accessed, after a resource request is obtained, the white list may be queried, whether a target page is in the white list is determined, if yes, it is determined that the target page has no access abnormality in a historical access process, at this time, step 805 may be executed, if no, it is determined that the target page has access abnormality in the historical access process, at this time, step 803 may be executed.
For example, a network identifier of a page that is normally accessed may be stored in a white list, after a resource request is obtained, the white list may be queried according to the network identifier of a target page carried in the resource request, and it is determined whether the network identifier of the target page is stored in the white list, if so, it is determined that a skeleton screen page corresponding to the target page does not need to be displayed in advance, at this time, step 805 may be executed, and if not, it is determined that the skeleton screen page corresponding to the target page needs to be displayed in advance, at this time, step 803 may be executed.
As another possible implementation manner, a blacklist may be preset, where the blacklist is used to record each page corresponding to a page that needs to be displayed on the skeleton screen, that is, the blacklist is used to record a page that is abnormally accessed, after a resource request is obtained, the blacklist may be queried, whether a target page is in the blacklist is determined, if yes, it is determined that the target page has access abnormality in a historical access process, at this time, step 803 may be executed, if no, it is determined that the target page has no access abnormality in the historical access process, and at this time, step 805 may be executed.
For example, a network identifier of a page that is accessed abnormally may be stored in a blacklist, after a resource request is obtained, the blacklist may be queried according to a network identifier of a target page carried in the resource request, and it is determined whether the network identifier of the target page is stored in the blacklist, if so, it is determined that a skeleton screen page corresponding to the target page needs to be displayed in advance, at this time, step 803 may be executed, if not, it is determined that the skeleton screen page corresponding to the target page does not need to be displayed in advance, at this time, step 803 may be executed.
Step 803, in the time interval between sending the resource request and obtaining the target page, inquiring and displaying a skeleton screen page corresponding to the target page; and the skeleton screen page corresponding to the target page is generated according to the structure of the target page when the target page is accessed historically.
And step 804, when the target page is obtained, displaying the target page and hiding the skeleton screen page.
Step 805, when the target page is to be acquired, the target page is displayed.
In the embodiment of the application, only when the target page has access abnormality in the historical access process, the corresponding skeleton screen page is inquired and displayed, and when the target page does not have access abnormality in the historical access process, the target page is directly displayed when the target page is to be acquired, so that the flexibility and the applicability of the page display method can be improved.
As a possible implementation manner, when there is no abnormality in the current access target page, the target page may be added to the white list, and when there is abnormality in the current access target page, the target page may be deleted from the white list. Therefore, dynamic maintenance and supplement of the white list can be realized, and all pages which are always normally visited and recorded in the white list are guaranteed.
As a possible implementation manner, when there is no abnormality in the current access target page, the target page may be deleted from the blacklist, and when there is abnormality in the current access target page, the target page may be added to the blacklist. Therefore, dynamic maintenance and supplement of the blacklist can be realized, and all pages which are recorded in the blacklist and are always abnormally accessed are guaranteed.
As a possible implementation manner, when the client displays the target page, the page which is possibly opened by the user can be predicted, and the skeleton screen page corresponding to the page is obtained in advance, so that when the user opens the page, the user does not need to query and obtain the corresponding skeleton screen page, and the searching and browsing experience of the user is further improved. The above process is described in detail below with reference to fig. 11.
Fig. 11 is a flowchart illustrating a page display method according to a ninth embodiment of the present application.
As shown in fig. 11, based on the embodiments shown in fig. 1 to 10, the page display method may further include the following steps:
step 901, determining a relevant page according to a network link set in the target page.
In the embodiment of the application, when the client displays the target page, the related page can be determined according to the network link set in the target page. For example, a network link a and a network link 1 are arranged in the target page, the related page corresponding to the network link a is page 1, and the related page corresponding to the network link B is page B.
And step 902, acquiring a skeleton screen page corresponding to the related page.
In the embodiment of the application, the network link is used for linking to the network address of the related page, so that the network address of the related page can be determined according to the network link, and the skeleton screen page corresponding to the related page can be inquired according to the network address. Specifically, the client may query, according to the network address, a skeleton screen page corresponding to the relevant page from locally stored data, and determine whether the skeleton screen page corresponding to the relevant page is locally stored, if so, directly obtain the skeleton screen page corresponding to the target page from the local, and if not, query the skeleton screen page corresponding to the target page from the server.
For example, the skeleton screen page corresponding to page 1 may be queried according to network link a, and the skeleton screen page corresponding to page 2 may be queried according to network link B.
Step 903, when the user operation of triggering the network link is detected, displaying a skeleton screen page corresponding to the related page.
In the embodiment of the application, the user operation is an operation of triggering the network link for the user, for example, an operation of clicking the network link for the user. The client can detect the user operation of triggering the network link by the user in a listening mode, and when the user operation is detected, for example, when the user clicks the network link, the skeleton screen page corresponding to the related page can be directly displayed.
According to the page display method, the related page is determined according to the network link arranged in the target page, and the skeleton screen page corresponding to the related page is obtained, so that the skeleton screen page corresponding to the related page is displayed when the user operation of triggering the network link is detected. Therefore, the method and the device can predict the page which is possibly opened by the user and acquire the skeleton screen page corresponding to the page in advance, so that when the user opens the page, the user does not need to inquire and acquire the corresponding skeleton screen page, and the searching and browsing experience of the user is further improved.
As an example, referring to fig. 12, the client generates a skeleton screen page: after a certain page is loaded, a client can perform framework extraction on the page to obtain a skeleton screen page of the page, and judge whether the skeleton screen page is different from the skeleton screen page obtained by inquiring a server, if so, the skeleton screen page is uploaded to the server to be updated and stored, or judge whether the skeleton screen page is stored in the server, if not, the skeleton screen page is uploaded to the server to be stored, or judge whether the storage duration of the skeleton screen page reaches a set storage duration, and if so, delete the skeleton screen page to save the resource occupation of the server.
When the client loads the target page, whether a skeleton screen page corresponding to the target page is stored locally or not can be inquired according to the network identifier, if so, the skeleton screen page corresponding to the target page is directly acquired locally according to the network identifier, if not, the skeleton screen page corresponding to the target page is inquired from the server according to the network identifier, and the server can return the corresponding skeleton screen page to the client. It should be noted that, in fig. 6, only the client does not store the skeleton screen page corresponding to the target page, and the server stores the skeleton screen page example corresponding to the target page, that is, the client directly queries the skeleton screen page corresponding to the target page from the server, and the server returns the corresponding skeleton screen page example to the client.
As an example, referring to fig. 13, fig. 13 is a schematic structural diagram of a page display system in an embodiment of the present application. The page display system comprises a framework screen display strategy module, a framework screen acquisition module, a framework screen generation strategy module and a framework screen uploading module.
The framework screen display strategy module is used for managing whether a currently loaded page displays a framework screen page or not, and mainly realizes the following 3 functions:
1. judging whether a page loaded by a client currently needs to show a skeleton screen page in advance, for example, judging according to a set white list or black list, or judging according to historical loading data;
2. updating and synchronizing information in the white list or the black list, for example, updating or dynamically maintaining the network identifier of each page in the white list or the black list in real time;
3. and reporting abnormal page information in the historical access process to the server, such as page information with too low loading speed and loading errors.
The framework screen acquisition module is used for inquiring the framework screen page corresponding to the currently loaded page from the server side and acquiring a group of general framework screen pages from the server side, for example, the client side can acquire the framework screen page of the related page corresponding to the network link set in the target page from the server side.
And the skeleton screen generation strategy module is used for generating a corresponding skeleton screen page according to the framework of the loaded page after the page is loaded.
After the client generates the skeleton screen page, whether the skeleton screen page is stored in the server or not can be judged, if not, the skeleton screen page is uploaded to the server to be stored, if yes, whether the generated skeleton screen page is different from the skeleton screen page stored in the server or not is judged, and if yes, the generated skeleton screen page is uploaded to the server to be updated and stored. Meanwhile, the server side can also time the storage duration of the skeleton screen page, and when the time reaches the set storage duration, the stored skeleton screen page is deleted, so that the resource occupation of the server side is reduced.
And the skeleton screen uploading module is used for uploading the generated skeleton screen page, the model of the skeleton screen page adaptation, the region of the skeleton screen page adaptation and other information to the server side.
It should be noted that the skeleton screen page may also be generated by the server side. Referring to fig. 14, a process of generating a skeleton screen page by a server side: the server side can acquire page resources from the third-party website, perform architecture extraction and generate a corresponding skeleton screen page. When the client loads the target page, the server can query the skeleton screen page corresponding to the target page, and the server can return the corresponding skeleton screen page to the client.
In order to implement the above embodiments, the present application further provides a page display device.
Fig. 15 is a schematic structural diagram of a page display device according to a tenth embodiment of the present application.
As shown in fig. 15, the page display apparatus includes: a sending module 101, a query module 102, and a display module 103.
The sending module 101 is configured to send a resource request; the resource request is used for acquiring a target page.
The query module 102 is configured to query and display a skeleton screen page corresponding to a target page in a time period between sending a resource request and obtaining the target page; and the skeleton screen page corresponding to the target page is generated according to the structure of the target page when the target page is accessed historically.
As a possible implementation, the resource request carries the network identifier of the target page.
The query module 102 is specifically configured to: inquiring the server side according to the network identification carried by the resource request to obtain a skeleton screen page corresponding to a target page stored by the server side; and if the model of the framework screen page is matched with the current display equipment, displaying the framework screen page through the display equipment.
The display module 103 is configured to display the target page and hide the skeleton screen page when the target page is acquired.
Further, in a possible implementation manner of the embodiment of the present application, referring to fig. 16, on the basis of the embodiment shown in fig. 15, the page display apparatus may further include:
as a possible implementation mode, occupied areas filled with gray scales are displayed in the page of the skeleton screen, correspond to all page elements in the target page one by one, and are identified according to the network carried by the resource request.
And the typesetting module 104 is used for, after querying the server side to obtain a skeleton screen page corresponding to the target page stored by the server side, typesetting each occupied area in the skeleton screen page according to the display parameters of the display device if the model adapted to the skeleton screen page is not matched with the current display device.
As a possible implementation manner, the typesetting module 104 is specifically configured to: typesetting the corresponding occupied areas according to the content types of the occupied areas so as to enable the typeset skeleton screen page to match with the display parameters; the content type of each occupied area is the content type of the page element corresponding to the corresponding occupied area.
And the screening module 105 is configured to, after querying the server side according to the network identifier carried by the resource request to obtain a skeleton screen page corresponding to the target page stored by the server side, screen the queried skeleton screen page according to a region where each skeleton screen page is adapted, so as to reserve the skeleton screen page adapted to the region where the display device is located.
And the extraction module 106 is configured to perform framework extraction on the displayed target page to obtain a skeleton screen page obtained by accessing the target page this time.
The processing module 107 is configured to compare the skeleton screen page obtained by accessing the target page this time with the skeleton screen page obtained by querying the server; and if the skeleton screen page obtained by accessing the target page at the time is different from the skeleton screen page obtained by inquiring the server, the skeleton screen page obtained by accessing the target page at the time and the network identifier of the target page are sent to the server so as to update and store.
The server is used for storing the skeleton screen page obtained by accessing the target page, the corresponding network identification and the corresponding region.
And the server side is also used for timing the storage duration of the skeleton screen page, and deleting the stored skeleton screen page when the timing reaches the set storage duration.
As a possible implementation manner, the display module 103 is further configured to: and if the server side is queried, determining that the server side does not store the skeleton screen page corresponding to the target page, and displaying the target page when the target page is to be acquired.
The determining module 108 is configured to determine whether an access exception exists in the history access process of the target page after the resource request is sent.
As a possible implementation manner, the query module 102 is specifically configured to: and if the target page has access abnormality in the historical access process, inquiring and displaying a skeleton screen page corresponding to the target page.
As a possible implementation manner, the display module 103 is further configured to: after judging whether the target page has access abnormality in the historical access process, if the target page does not have access abnormality in the historical access process, displaying the target page when the target page is to be acquired.
As a possible implementation manner, the determining module 108 is specifically configured to: inquiring a white list; the white list is used for recording pages which are normally accessed; if the target page is in the white list, determining that the target page has no access abnormality in the historical access process; and if the target page is not in the white list, determining that the target page has access abnormity in the historical access process.
As another possible implementation manner, the determining module 108 is specifically configured to: inquiring a blacklist; the blacklist is used for recording the page accessed abnormally; if the target page is in the blacklist, determining that the target page has access abnormality in the historical access process; and if the target page is not in the blacklist, determining that the target page has no access abnormality in the historical access process.
The maintenance module 109 is configured to add the target page to the white list if the target page is not abnormal during the current access; and if the target page accessed at this time is abnormal, deleting the target page from the white list.
As a possible implementation, the maintenance module 109 is further configured to: if the target page accessed at this time is not abnormal, deleting the target page from the blacklist; and if the target page accessed at this time is abnormal, adding the target page into the blacklist.
The determining module 110 is configured to determine, after the target page is displayed and the skeleton screen page is hidden, a relevant page according to a network link set in the target page.
The obtaining module 111 is configured to obtain a skeleton screen page corresponding to the related page.
The display module 103 is further configured to display a skeleton screen page corresponding to the relevant page when the user operation of triggering the network link is detected.
It should be noted that the foregoing explanation on the embodiment of the page display method is also applicable to the page display apparatus of this embodiment, and is not repeated here.
The page display device of the embodiment of the application sends the resource request; the method comprises the steps that a resource request is used for obtaining a target page, and then a skeleton screen page corresponding to the target page is inquired and displayed in a time interval between the resource request is sent and the target page is obtained; and finally, when the target page is obtained, displaying the target page and hiding the skeleton screen page. Therefore, the skeleton screen page corresponding to the target page can be displayed in advance before the target page is loaded unsuccessfully, so that a user can know the framework corresponding to the target page in advance, the user is prevented from being in a waiting state or a loading state all the time, and the use experience of the user can be improved. In addition, the skeleton screen page is generated according to the framework of the target page, so that the skeleton screen page is matched with the real content of the target page, and the searching and browsing experience of a user can be improved.
In order to implement the foregoing embodiments, the present application also provides a computer device, including: the page display method comprises a memory, a processor and a computer program which is stored on the memory and can run on the processor, wherein when the processor executes the program, the page display method is realized.
In order to implement the foregoing embodiments, the present application also proposes a computer-readable storage medium on which a computer program is stored, which when executed by a processor implements the page display method as proposed in the foregoing embodiments of the present application.
FIG. 17 illustrates a block diagram of an exemplary computer device suitable for use in implementing embodiments of the present application. The computer device 12 shown in fig. 17 is only an example, and should not bring any limitation to the function and the scope of use of the embodiments of the present application.
As shown in FIG. 17, computer device 12 is embodied in the form of a general purpose computing device. The components of computer device 12 may include, but are not limited to: one or more processors or processing units 16, a system memory 28, and a bus 18 that couples various system components including the system memory 28 and the processing unit 16.
Bus 18 represents one or more of any of several types of bus structures, including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, and a processor or local bus using any of a variety of bus architectures. These architectures include, but are not limited to, Industry Standard Architecture (ISA) bus, Micro Channel Architecture (MAC) bus, enhanced ISA bus, Video Electronics Standards Association (VESA) local bus, and Peripheral Component Interconnect (PCI) bus, to name a few.
Computer device 12 typically includes a variety of computer system readable media. Such media may be any available media that is accessible by computer device 12 and includes both volatile and nonvolatile media, removable and non-removable media.
Memory 28 may include computer system readable media in the form of volatile Memory, such as Random Access Memory (RAM) 30 and/or cache Memory 32. Computer device 12 may further include other removable/non-removable, volatile/nonvolatile computer system storage media. By way of example only, storage system 34 may be used to read from and write to non-removable, nonvolatile magnetic media (not shown in FIG. 17, commonly referred to as a "hard drive"). Although not shown in FIG. 17, a disk drive for reading from and writing to a removable, nonvolatile magnetic disk (e.g., a "floppy disk") and an optical disk drive for reading from or writing to a removable, nonvolatile optical disk (e.g., a Compact disk Read Only Memory (CD-ROM), a Digital versatile disk Read Only Memory (DVD-ROM), or other optical media) may be provided. In these cases, each drive may be connected to bus 18 by one or more data media interfaces. Memory 28 may include at least one program product having a set (e.g., at least one) of program modules that are configured to carry out the functions of embodiments of the application.
A program/utility 40 having a set (at least one) of program modules 42 may be stored, for example, in memory 28, such program modules 42 including, but not limited to, an operating system, one or more application programs, other program modules, and program data, each of which examples or some combination thereof may comprise an implementation of a network environment. Program modules 42 generally perform the functions and/or methodologies of the embodiments described herein.
Computer device 12 may also communicate with one or more external devices 14 (e.g., keyboard, pointing device, display 24, etc.), with one or more devices that enable a user to interact with computer device 12, and/or with any devices (e.g., network card, modem, etc.) that enable computer device 12 to communicate with one or more other computing devices. Such communication may be through an input/output (I/O) interface 22. Moreover, computer device 12 may also communicate with one or more networks (e.g., a Local Area Network (LAN), a Wide Area Network (WAN), and/or a public Network such as the Internet) via Network adapter 20. As shown, network adapter 20 communicates with the other modules of computer device 12 via bus 18. It should be understood that although not shown in the figures, other hardware and/or software modules may be used in conjunction with computer device 12, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, among others.
The processing unit 16 executes various functional applications and data processing, such as implementing the page display method mentioned in the foregoing embodiments, by executing programs stored in the system memory 28.
In the description herein, reference to the description of the term "one embodiment," "some embodiments," "an example," "a specific example," or "some examples," etc., means that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the application. In this specification, the schematic representations of the terms used above are not necessarily intended to refer to the same embodiment or example. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples. Furthermore, various embodiments or examples and features of different embodiments or examples described in this specification can be combined and combined by one skilled in the art without contradiction.
Furthermore, the terms "first", "second" and "first" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one such feature. In the description of the present application, "plurality" means at least two, e.g., two, three, etc., unless specifically limited otherwise.
Any process or method descriptions in flow charts or otherwise described herein may be understood as representing modules, segments, or portions of code which include one or more executable instructions for implementing steps of a custom logic function or process, and alternate implementations are included within the scope of the preferred embodiment of the present application in which functions may be executed out of order from that shown or discussed, including substantially concurrently or in reverse order, depending on the functionality involved, as would be understood by those reasonably skilled in the art of the present application.
The logic and/or steps represented in the flowcharts or otherwise described herein, e.g., an ordered listing of executable instructions that can be considered to implement logical functions, can be embodied in any computer-readable medium for use by or in connection with an instruction execution system, apparatus, or device, such as a computer-based system, processor-containing system, or other system that can fetch the instructions from the instruction execution system, apparatus, or device and execute the instructions. For the purposes of this description, a "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transport the program for use by or in connection with the instruction execution system, apparatus, or device. More specific examples (a non-exhaustive list) of the computer-readable medium would include the following: an electrical connection (electronic device) having one or more wires, a portable computer diskette (magnetic device), a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). Additionally, the computer-readable medium could even be paper or another suitable medium upon which the program is printed, as the program can be electronically captured, via for instance optical scanning of the paper or other medium, then compiled, interpreted or otherwise processed in a suitable manner if necessary, and then stored in a computer memory.
It should be understood that portions of the present application may be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, the various steps or methods may be implemented in software or firmware stored in memory and executed by a suitable instruction execution system. If implemented in hardware, as in another embodiment, any one or combination of the following techniques, which are known in the art, may be used: a discrete logic circuit having a logic gate circuit for implementing a logic function on a data signal, an application specific integrated circuit having an appropriate combinational logic gate circuit, a Programmable Gate Array (PGA), a Field Programmable Gate Array (FPGA), or the like.
It will be understood by those skilled in the art that all or part of the steps carried by the method for implementing the above embodiments may be implemented by hardware related to instructions of a program, which may be stored in a computer readable storage medium, and when the program is executed, the program includes one or a combination of the steps of the method embodiments.
In addition, functional units in the embodiments of the present application may be integrated into one processing module, or each unit may exist alone physically, or two or more units are integrated into one module. The integrated module can be realized in a hardware mode, and can also be realized in a software functional module mode. The integrated module, if implemented in the form of a software functional module and sold or used as a stand-alone product, may also be stored in a computer readable storage medium.
The storage medium mentioned above may be a read-only memory, a magnetic or optical disk, etc. Although embodiments of the present application have been shown and described above, it is understood that the above embodiments are exemplary and should not be construed as limiting the present application, and that variations, modifications, substitutions and alterations may be made to the above embodiments by those of ordinary skill in the art within the scope of the present application.

Claims (19)

1. A method for displaying a page, the method comprising the steps of:
sending a resource request; the resource request is used for acquiring a target page;
in a time period between the resource request is sent and the target page is obtained, inquiring and displaying a skeleton screen page corresponding to the target page; when a client accesses the target page in history, the skeleton screen page corresponding to the target page is generated according to the structure of the target page, and the skeleton screen page corresponding to the target page generated on the client and the network identifier of the target page are sent to a server for storage; extracting the position and the outline of each page element of the target page, and filling the outline of each page element with gray scale at the corresponding position in a blank page to obtain the skeleton screen page;
and when the target page is acquired, displaying the target page and hiding the skeleton screen page.
2. The page display method according to claim 1, wherein the resource request carries a network identifier of a target page, and the querying and displaying of the skeleton screen page corresponding to the target page comprises:
inquiring a server side according to a network identifier carried by the resource request to obtain a skeleton screen page corresponding to the target page stored by the server side;
and if the model of the framework screen page is matched with the current display equipment, displaying the framework screen page through the display equipment.
3. The page display method according to claim 2, wherein the skeleton screen page displays a space occupying region filled with gray scale, the space occupying region corresponds to each page element in the target page one to one, and after querying the server according to the network identifier carried by the resource request to obtain the skeleton screen page corresponding to the target page stored by the server, the method further comprises:
and if the model of the framework screen page adaptation is not matched with the current display equipment, typesetting each occupied area in the framework screen page according to the display parameters of the display equipment.
4. The page display method according to claim 3, wherein the typesetting of each placeholder area in the skeleton screen page according to the display parameters of the display device comprises:
typesetting the corresponding occupied areas according to the content types of the occupied areas so as to enable the typeset skeleton screen page to be matched with the display parameters; the content type of each occupied area is the content type of the page element corresponding to the corresponding occupied area.
5. The page display method according to any one of claims 2 to 4, wherein after querying a server according to a network identifier carried by the resource request to obtain a skeleton screen page corresponding to the target page stored by the server, the method further comprises:
and screening the searched skeleton screen pages according to the regions matched with the skeleton screen pages so as to reserve the skeleton screen pages matched with the regions where the display equipment is located.
6. The page display method according to any one of claims 2 to 4, wherein after displaying the target page and hiding the skeleton screen page, the method further comprises:
performing framework extraction on the displayed target page to obtain a skeleton screen page obtained by accessing the target page at this time;
comparing the skeleton screen page obtained by accessing the target page with the skeleton screen page obtained by inquiring the server; the skeleton screen page stored by the server is generated by a client which historically accesses the target page and is sent to the server for storage;
and if the skeleton screen page obtained by accessing the target page at this time is different from the skeleton screen page obtained by inquiring the server, sending the skeleton screen page obtained by accessing the target page at this time and the network identifier of the target page to the server so as to update and store.
7. The page display method according to claim 6, wherein the server is configured to store the skeleton screen page obtained by accessing the target page this time, the corresponding network identifier, and the corresponding region.
8. The page display method according to claim 7, wherein the server is further configured to time a storage duration of the skeleton screen page, and delete the stored skeleton screen page when the time reaches the set storage duration.
9. The page display method according to any one of claims 2 to 4, wherein after querying the server according to the network identifier carried by the resource request, the method further comprises:
and if the server side is inquired, determining that the server side does not store the skeleton screen page corresponding to the target page, and displaying the target page when the target page is to be acquired.
10. The page display method according to any one of claims 1 to 4, wherein after said sending the resource request, further comprising:
judging whether the target page has access abnormality in the historical access process;
the inquiring and displaying of the skeleton screen page corresponding to the target page comprises the following steps:
and if the target page has access abnormality in the historical access process, inquiring and displaying a skeleton screen page corresponding to the target page.
11. The page display method according to claim 10, wherein after determining whether the target page has an access abnormality in a history access process, the method further comprises:
and if the target page has no access abnormality in the historical access process, displaying the target page when the target page is to be acquired.
12. The method for displaying the page according to claim 10, wherein the determining whether the target page has access abnormality in the history access process includes:
inquiring a white list; the white list is used for recording pages accessed normally;
if the target page is in the white list, determining that the target page has no access abnormality in the historical access process;
and if the target page is not in the white list, determining that the target page has access abnormity in the historical access process.
13. The page display method according to claim 12, wherein after said sending the resource request, further comprising:
if the target page is not abnormal during the current visit, adding the target page into the white list;
and if the target page accessed at this time is abnormal, deleting the target page from the white list.
14. The method for displaying the page according to claim 10, wherein the determining whether the target page has access abnormality in the history access process includes:
inquiring a blacklist; the blacklist is used for recording pages accessed abnormally;
if the target page is in the blacklist, determining that access abnormality exists in the target page in a historical access process;
and if the target page is not in the blacklist, determining that the target page has no access abnormality in the historical access process.
15. The page display method according to claim 14, wherein after said sending the resource request, further comprising:
if the target page is not abnormal during the current visit, deleting the target page from the blacklist;
and if the target page accessed this time is abnormal, adding the target page into the blacklist.
16. The page display method according to any one of claims 1 to 4, wherein after the target page is displayed and the skeleton screen page is hidden when the target page is acquired, the method further includes:
determining a related page according to a network link set in the target page;
acquiring a skeleton screen page corresponding to the related page;
and when the user operation of triggering the network link is detected, displaying a skeleton screen page corresponding to the related page.
17. A page display apparatus, characterized in that the apparatus comprises:
a sending module, configured to send a resource request; the resource request is used for acquiring a target page;
the query module is used for querying and displaying a skeleton screen page corresponding to the target page in a time period between the resource request is sent and the target page is obtained; when a client accesses the target page in history, the framework screen page corresponding to the target page is generated by the framework of the target page, and the framework screen page corresponding to the target page generated on the client and the network identifier of the target page are sent to a server for storage;
and the display module is used for displaying the target page and hiding the skeleton screen page when the target page is acquired.
18. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the page display method as claimed in any one of claims 1 to 16 when executing the program.
19. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out a page display method according to any one of claims 1 to 16.
CN201910138773.9A 2019-02-25 2019-02-25 Page display method and device, computer equipment and readable storage medium Active CN109902248B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910138773.9A CN109902248B (en) 2019-02-25 2019-02-25 Page display method and device, computer equipment and readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910138773.9A CN109902248B (en) 2019-02-25 2019-02-25 Page display method and device, computer equipment and readable storage medium

Publications (2)

Publication Number Publication Date
CN109902248A CN109902248A (en) 2019-06-18
CN109902248B true CN109902248B (en) 2021-07-13

Family

ID=66945589

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910138773.9A Active CN109902248B (en) 2019-02-25 2019-02-25 Page display method and device, computer equipment and readable storage medium

Country Status (1)

Country Link
CN (1) CN109902248B (en)

Families Citing this family (21)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111737614B (en) * 2019-06-24 2024-02-06 北京京东尚科信息技术有限公司 Page display method, page display device, electronic equipment and storage medium
CN112395521B (en) * 2019-08-19 2023-05-16 腾讯科技(武汉)有限公司 Page processing method, page processing device, electronic equipment and computer readable storage medium
CN110765379B (en) * 2019-09-20 2023-06-20 苏州达家迎信息技术有限公司 Method, device, computer equipment and storage medium for loading resource file
CN110780939B (en) * 2019-09-20 2023-07-28 苏州达家迎信息技术有限公司 Method, device, computer equipment and storage medium for loading resource file
CN110795195B (en) * 2019-10-31 2023-09-26 百度在线网络技术(北京)有限公司 Webpage rendering method and device, electronic equipment and storage medium
CN110807161A (en) * 2019-11-08 2020-02-18 深圳乐信软件技术有限公司 Page framework rendering method, device, equipment and medium
CN111026988A (en) * 2019-11-15 2020-04-17 浙江数链科技有限公司 Page loading method, device and system and computer equipment
CN111522599B (en) * 2020-04-13 2023-06-30 百度在线网络技术(北京)有限公司 Method and device for transmitting information
CN111611503B (en) * 2020-05-27 2023-07-14 百度在线网络技术(北京)有限公司 Page processing method and device, electronic equipment and storage medium
CN111708962A (en) * 2020-06-23 2020-09-25 中国平安财产保险股份有限公司 Rendering method, device and equipment of skeleton screen and storage medium
CN111857878B (en) * 2020-07-21 2024-04-09 北京蚂蜂窝网络科技有限公司 Skeleton screen page generation method and device, electronic equipment and storage medium
CN111898056A (en) * 2020-08-28 2020-11-06 北京三快在线科技有限公司 Webpage display method and device, storage medium and electronic equipment
CN112306508A (en) * 2020-10-13 2021-02-02 武汉木仓科技股份有限公司 Configuration information file updating method and device and processing equipment
CN112380470A (en) * 2020-10-29 2021-02-19 北京华胜天成科技股份有限公司 Web application system display method and device and emergency management system
CN112417336B (en) * 2020-11-24 2022-11-01 天津五八到家货运服务有限公司 Page display method and device, electronic equipment and storage medium
CN112528274B (en) * 2020-12-24 2023-09-22 微医云(杭州)控股有限公司 Data processing method, device, electronic equipment and storage medium
CN112905280B (en) * 2021-02-07 2023-12-15 腾竞体育文化发展(上海)有限公司 Page display method, device, equipment and storage medium
CN113553523A (en) * 2021-06-10 2021-10-26 北京达佳互联信息技术有限公司 Method and device for generating skeleton screen page, electronic equipment, medium and product
CN113569177A (en) * 2021-07-16 2021-10-29 上海淇玥信息技术有限公司 Method and device for optimizing skipped web pages and electronic equipment
CN114661370A (en) * 2022-02-17 2022-06-24 上海哔哩哔哩科技有限公司 Resource loading method and device, electronic equipment and computer storage medium
CN115857932A (en) * 2022-12-21 2023-03-28 贝壳找房(北京)科技有限公司 Skeleton screen file generation method and device and skeleton screen display method and device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5504109B2 (en) * 2010-09-08 2014-05-28 株式会社日立製作所 Change display device for skeleton screen for power management
CN109254773A (en) * 2018-09-19 2019-01-22 广州视源电子科技股份有限公司 Skeleton page generation method, device, equipment and storage medium
CN109376318A (en) * 2018-09-03 2019-02-22 中国平安人寿保险股份有限公司 A kind of page loading method, computer readable storage medium and terminal device

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102722559B (en) * 2012-05-31 2015-09-16 北京奇虎科技有限公司 A kind of course control method of the abnormal page, device and system
CN103412928B (en) * 2013-08-16 2017-05-10 北京乐动卓越科技有限公司 Method and device for realizing browser page intelligent response-type layout on mobile terminal
CN104573025B (en) * 2015-01-12 2018-09-04 北京京东尚科信息技术有限公司 A kind of method and system improving page loading velocity
CN104657499A (en) * 2015-03-11 2015-05-27 网易(杭州)网络有限公司 Webpage loading method and device of client-side APP (Application)
CN107943803A (en) * 2016-10-12 2018-04-20 中国海洋大学 A kind of method and apparatus for realizing that webpage quickly loads based on big data
CN107122192B (en) * 2017-04-27 2019-04-26 北京三快在线科技有限公司 Webpage view methods of exhibiting, calculates equipment and storage medium at device
CN109298864A (en) * 2018-08-23 2019-02-01 深圳点猫科技有限公司 The method and electronic equipment of automation generation project skeleton screen under teaching platform

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5504109B2 (en) * 2010-09-08 2014-05-28 株式会社日立製作所 Change display device for skeleton screen for power management
CN109376318A (en) * 2018-09-03 2019-02-22 中国平安人寿保险股份有限公司 A kind of page loading method, computer readable storage medium and terminal device
CN109254773A (en) * 2018-09-19 2019-01-22 广州视源电子科技股份有限公司 Skeleton page generation method, device, equipment and storage medium

Also Published As

Publication number Publication date
CN109902248A (en) 2019-06-18

Similar Documents

Publication Publication Date Title
CN109902248B (en) Page display method and device, computer equipment and readable storage medium
US11609839B2 (en) Distributed code tracing system
US11032388B2 (en) Methods for prerendering and methods for managing and configuring prerendering operations
CN107948314B (en) Business processing method and device based on rule file and server
US8135616B2 (en) Browsing and quality of service features
AU2016200352B2 (en) Method and system to provide video-based search results
US20170353584A1 (en) Access to network content
KR20090038894A (en) Enabling web analytics for interactive web applications
US10305768B2 (en) Page phase time
CN110209966B (en) Webpage refreshing method, webpage system and electronic equipment
US20120030562A1 (en) Device and method for generating customized webpages
CN112861050B (en) Page data backtracking method, device and equipment
CN109190067B (en) Browser input box display method and device, computer equipment and storage medium
CN105808221A (en) Card type desktop realization method and apparatus
US10198147B2 (en) Object management and visualization using a computing device
CN111488097A (en) Method and equipment for providing reading presentation information
US20070011336A1 (en) Method for managing contents of a web site
CN110781427A (en) Method, device, equipment and storage medium for calculating first screen time
US20040268233A1 (en) Information processing apparatus and information processing method
US20200183998A1 (en) Real-time generation of an improved graphical user interface for overlapping electronic content
RU2640635C2 (en) Method, system and server for transmitting personalized message to user electronic device
US10796079B1 (en) Generating a page layout based upon analysis of session variables with respect to a client device
CN111628904B (en) Quality evaluation method and system for cross-border E-commerce flow
CN113934954A (en) Webpage first screen rendering method and device in application program
US10185709B1 (en) Dynamic creation and storage of narratives in multiple languages based in part on the popularity of the subject entity

Legal Events

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