CN111931090A - Webpage display method, device, equipment and readable storage medium - Google Patents

Webpage display method, device, equipment and readable storage medium Download PDF

Info

Publication number
CN111931090A
CN111931090A CN202010605548.4A CN202010605548A CN111931090A CN 111931090 A CN111931090 A CN 111931090A CN 202010605548 A CN202010605548 A CN 202010605548A CN 111931090 A CN111931090 A CN 111931090A
Authority
CN
China
Prior art keywords
website
intermediate file
processing scheme
file
web page
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202010605548.4A
Other languages
Chinese (zh)
Inventor
不公告发明人
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Xiamen Hanyin Electronic Technology Co Ltd
Original Assignee
Xiamen Hanyin Electronic 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 Xiamen Hanyin Electronic Technology Co Ltd filed Critical Xiamen Hanyin Electronic Technology Co Ltd
Priority to CN202010605548.4A priority Critical patent/CN111931090A/en
Publication of CN111931090A publication Critical patent/CN111931090A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/957Browsing optimisation, e.g. caching or content distillation
    • G06F16/9577Optimising the visualization of content, e.g. distillation of HTML documents
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/958Organisation or management of web site content, e.g. publishing, maintaining pages or automatic linking
    • G06F16/986Document structures and storage, e.g. HTML extensions

Landscapes

  • Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The invention discloses a webpage display method, a device, equipment and a readable storage medium, wherein the method comprises the following steps: acquiring a website to be accessed by a user; judging whether a processing scheme corresponding to the website exists or not; when judging that the corresponding processing scheme exists, initiating an access request to a Web server corresponding to the website, and intercepting an intermediate file returned by the Web server according to the access request; processing the intermediate file through the processing scheme to generate a processed intermediate file; and generating a webpage displayed on an interface according to the processed intermediate file.

Description

Webpage display method, device, equipment and readable storage medium
Technical Field
The present invention relates to the field of computer technologies, and in particular, to a method, an apparatus, a device, and a readable storage medium for displaying a web page.
Background
Browsers are application programs used to retrieve, present, and deliver Web information resources. A Web information Resource is tagged by a Uniform Resource Identifier (URI), which is a Web page, a picture, a piece of video, or any content presented on the Web. The user can browse the information associated with each other through a browser by means of Hyperlinks (Hyperlinks).
The existing browser can only check fixed content information provided by a development company, for example, a manufacturer purchases SAAS platform software, if a display interface of the platform software needs to be modified or secondarily developed according to own requirements, any modification or secondary development can be realized through the development company, and not only is the process complicated, but also the situations that the development company does not agree with the modification exist.
Disclosure of Invention
In view of the foregoing problems, an object of the present invention is to provide a method, an apparatus, a device and a readable storage medium for displaying a web page, which enable a user to perform secondary development on the displayed web page according to his own needs.
The embodiment of the invention provides a webpage display method, which comprises the following steps:
acquiring a website to be accessed by a user;
judging whether a processing scheme corresponding to the website exists or not;
when judging that the corresponding processing scheme exists, initiating an access request to a Web server corresponding to the website, and intercepting an intermediate file returned by the Web server according to the access request;
processing the intermediate file through the processing scheme to generate a processed intermediate file;
and generating a webpage displayed on an interface according to the processed intermediate file.
Preferably, the intermediate file includes an HTML file and a JS script file.
Preferably, the method further comprises the following steps:
acquiring a website input by a user and a processing scheme corresponding to the website, associating the website with the processing scheme, and storing the associated website and the processing scheme in a database.
Preferably, the processing scheme includes an intermediate replacement file for replacement;
processing the intermediate file through the processing scheme to generate a processed intermediate file, which specifically includes:
and replacing the original intermediate file with the intermediate replacement file to generate a processed intermediate file.
Preferably, the treatment protocol comprises at least one of:
setting the font, font size or font color of the intermediate file;
adding a preset tool control on the intermediate file;
and changing the display style and the page layout of the intermediate file.
The embodiment of the present invention further provides a browser webpage display apparatus, including:
the website acquisition unit is used for acquiring a website to be accessed by a user;
the judging unit is used for judging whether a processing scheme corresponding to the website exists or not;
the intercepting unit is used for initiating an access request to the Web server corresponding to the website when judging that the corresponding processing scheme exists, and intercepting an intermediate file returned by the Web server according to the access request;
the processing unit is used for processing the intermediate file through the processing scheme to generate a processed intermediate file;
and the display unit is used for generating a webpage displayed on an interface according to the processed intermediate file.
Preferably, the method further comprises the following steps:
and the association unit is used for acquiring the website input by the user and the processing scheme corresponding to the website, associating the website with the processing scheme and storing the associated website and the processing scheme in a database.
Preferably, the processing scheme includes an intermediate replacement file for replacement;
the processing unit is specifically configured to:
and replacing the original intermediate file with the intermediate replacement file to generate a processed intermediate file.
The embodiment of the invention also provides a webpage display device, which comprises a memory and a processor, wherein the processor is configured to execute a computer program stored in the memory to realize the webpage display method.
An embodiment of the present invention further provides a computer-readable storage medium, in which a computer program is stored, where the computer program can be executed by a processor of a device in which the storage medium is located, so as to implement the above-mentioned web page display method.
In the embodiment, the intermediate file returned by the Web server is intercepted and processed according to the preset processing scheme, so that the user can perform secondary development and modification on the preset webpage according to the actual requirement of the user without going through a development company of the webpage or software, thereby simplifying the flow of the secondary development of the whole webpage and saving the cost of the secondary development.
Drawings
In order to more clearly illustrate the technical solution of the present invention, the drawings needed to be used in the embodiments will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art that other drawings can be obtained according to the drawings without creative efforts.
Fig. 1 is a flowchart illustrating a web page display method according to a first embodiment of the present invention.
Fig. 2 is a schematic structural diagram of a web page display device according to a second embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
For better understanding of the technical solutions of the present invention, the following detailed descriptions of the embodiments of the present invention are provided with reference to the accompanying drawings.
It should be understood that the described embodiments are only some embodiments of the invention, and not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The terminology used in the embodiments of the invention is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. As used in the examples of the present invention and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise.
It should be understood that the term "and/or" as used herein is merely one type of association that describes an associated object, meaning that three relationships may exist, e.g., a and/or B may mean: a exists alone, A and B exist simultaneously, and B exists alone. In addition, the character "/" herein generally indicates that the former and latter related objects are in an "or" relationship.
The word "if" as used herein may be interpreted as "at … …" or "when … …" or "in response to a determination" or "in response to a detection", depending on the context. Similarly, the phrases "if determined" or "if detected (a stated condition or event)" may be interpreted as "when determined" or "in response to a determination" or "when detected (a stated condition or event)" or "in response to a detection (a stated condition or event)", depending on the context.
In the embodiments, the references to "first \ second" are merely to distinguish similar objects and do not represent a specific ordering for the objects, and it is to be understood that "first \ second" may be interchanged with a specific order or sequence, where permitted. It should be understood that "first \ second" distinct objects may be interchanged under appropriate circumstances such that the embodiments described herein may be practiced in sequences other than those illustrated or described herein.
Referring to fig. 1, a first embodiment of the present invention provides a web page display method, which can be executed by a web page display device, and in particular, executed by one or more processors in the web page display device, to implement the following steps:
s101, acquiring a website to be accessed by a user.
In this embodiment, the web page display device may be a terminal with data processing and computing capabilities, such as a desktop computer, a notebook computer, an intelligent mobile terminal, and various PDAs. The Web page display device at least has a browser installed therein to realize retrieval, display and transfer of Web information resources.
In this embodiment, the user may input a website in the website input field of the browser to access a predetermined webpage, or may access a webpage through a website collected in the collection field. When a user initiates access to a preset website, the webpage display equipment can acquire the website to be accessed by the user.
And S102, judging whether a processing scheme corresponding to the website exists or not.
S103, when judging that the corresponding processing scheme exists, initiating an access request to the Web server corresponding to the website, and intercepting an intermediate file returned by the Web server according to the access request.
And S104, processing the intermediate file through the processing scheme to generate a processed intermediate file.
And S105, generating a webpage displayed on an interface according to the processed intermediate file.
In this embodiment, the user may set a corresponding processing scheme for the website that needs to be processed or developed for the second time.
Specifically, before use, a user firstly inputs a website to be processed, and then sets a processing scheme corresponding to the website, wherein the website is stored in a local database after being associated with the processing scheme.
When the method is used, when the website to be accessed by the user is obtained, the webpage display equipment firstly inquires whether a processing scheme corresponding to the website to be accessed exists from the database.
If the intermediate file does not exist, the Web page display device initiates an access request to the corresponding Web server, the Web server returns a corresponding intermediate file (for example, including an HTML file and a JS script file) according to the access request, and the Web page display device generates a corresponding Web page according to the intermediate file for display, namely, the normal Web page browsing process is realized.
If the intermediate file exists, the Web page display equipment firstly initiates an access request to the corresponding Web server, the Web server returns the corresponding intermediate file (such as an HTML file and a JS script file) according to the access request, the Web page display equipment processes the intermediate file according to the processing scheme to generate the processed intermediate file, and then, the Web page is displayed according to the processed intermediate file.
In one implementation, the processing scheme includes an intermediate replacement file for replacement;
processing the intermediate file through the processing scheme to generate a processed intermediate file, which specifically comprises:
and replacing the original intermediate file with the intermediate replacement file to generate a processed intermediate file.
Specifically, in this implementation manner, the user may prepare an intermediate replacement file corresponding to the website in advance as a processing scheme of the website. And after the intermediate file returned by the Web server according to the access request is intercepted, the webpage display equipment replaces the intermediate file by using an intermediate replacement file and displays the webpage according to the intermediate replacement file.
The user can perform secondary development according to actual requirements of the user to make an intermediate replacement file, for example, the design of fonts, word sizes and overall page layout can be performed, some small tools can be added to the original webpage, and the method is specifically determined according to the actual secondary development requirements, and is not specifically limited.
In another implementation, the processing scheme includes at least one of:
setting the font, font size or font color of the intermediate file;
adding a preset tool control on the intermediate file;
and changing the display style and the page layout of the intermediate file.
In this embodiment, the processing scheme may be a script, and the replacement of the key field may be defined in the script, for example, when the font of the web page corresponding to the intermediate file is to be set, the value of the key field corresponding to the font may be set in the script, so as to change the font. For another example, when a predetermined tool control is to be added to the web page corresponding to the intermediate file, the display position, the related function, and the like of the tool control may be defined in the script.
In summary, according to the Web page display method provided by this embodiment, by intercepting the intermediate file returned by the Web server and processing the intermediate file according to the preset processing scheme, the user can perform secondary development and modification on the predetermined Web page according to the actual needs of the user without going through a Web page or a software development company, thereby simplifying the whole Web page secondary development process and saving the cost of secondary development.
Referring to fig. 2, a second embodiment of the present invention further provides a web page display device, including:
a website acquisition unit 210, configured to acquire a website to be accessed by a user;
a determining unit 220, configured to determine whether a processing scheme corresponding to the website exists;
the intercepting unit 230 is configured to, when it is determined that a corresponding processing scheme exists, initiate an access request to a Web server corresponding to the website, and intercept an intermediate file returned by the Web server according to the access request;
a processing unit 240, configured to process the intermediate file according to the processing scheme, and generate a processed intermediate file;
and a display unit 250, configured to generate a web page displayed on the interface according to the processed intermediate file.
Preferably, the method further comprises the following steps:
and the association unit is used for acquiring the website input by the user and the processing scheme corresponding to the website, associating the website with the processing scheme and storing the associated website and the processing scheme in a database.
Preferably, the processing scheme includes an intermediate replacement file for replacement;
the processing unit 240 is specifically configured to:
and replacing the original intermediate file with the intermediate replacement file to generate a processed intermediate file.
The third embodiment of the present invention also provides a browser webpage display device, which includes a memory and a processor, wherein the processor is configured to execute a computer program stored in the memory to implement the webpage display method.
The fourth embodiment of the present invention also provides a computer-readable storage medium, which stores a computer program, where the computer program can be executed by a processor of a device in which the storage medium is located, so as to implement the web page display method as described above.
Illustratively, the computer program may be divided into one or more units, which are stored in the memory and executed by the processor to accomplish the present invention. The one or more units may be a series of computer program instruction segments capable of performing specific functions, which are used to describe the execution of the computer program in the printer.
The printer may include, but is not limited to, a processor, memory. Those skilled in the art will appreciate that the schematic diagram is merely an example of a printer and is not meant to be limiting, and may include more or fewer components than those shown, or some components in combination, or different components, e.g., the printer may also include input and output devices, network access devices, buses, etc.
The Processor may be a Central Processing Unit (CPU), other general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), an off-the-shelf Programmable Gate Array (FPGA) or other Programmable logic device, discrete Gate or transistor logic, discrete hardware components, etc. The general purpose processor may be a microprocessor or the processor may be any conventional processor or the like, the control center of the printer, connecting the various parts of the overall printer using various interfaces and lines.
The memory may be used to store the computer programs and/or modules, and the processor may implement the various functions of the printer by running or executing the computer programs and/or modules stored in the memory, as well as by invoking data stored in the memory. The memory may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required by at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area may store data (such as audio data, a phonebook, etc.) created according to the use of the cellular phone, and the like. In addition, the memory may include high speed random access memory, and may also include non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), at least one magnetic disk storage device, a Flash memory device, or other volatile solid state storage device.
Wherein the printer integrated unit, if implemented in the form of a software functional unit and sold or used as a separate product, may be stored in a computer-readable storage medium. Based on such understanding, all or part of the flow of the method according to the embodiments of the present invention may also be implemented by a computer program, which may be stored in a computer-readable storage medium, and when the computer program is executed by a processor, the steps of the method embodiments may be implemented. Wherein the computer program comprises computer program code, which may be in the form of source code, object code, an executable file or some intermediate form, etc. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, usb disk, removable hard disk, magnetic disk, optical disk, computer Memory, Read-Only Memory (ROM), Random Access Memory (RAM), electrical carrier wave signals, telecommunications signals, software distribution medium, and the like. It should be noted that the computer readable medium may contain content that is subject to appropriate increase or decrease as required by legislation and patent practice in jurisdictions, for example, in some jurisdictions, computer readable media does not include electrical carrier signals and telecommunications signals as is required by legislation and patent practice.
It should be noted that the above-described device embodiments are merely illustrative, where the units described as separate parts may or may not be physically separate, and the parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. In addition, in the drawings of the embodiment of the apparatus provided by the present invention, the connection relationship between the modules indicates that there is a communication connection between them, and may be specifically implemented as one or more communication buses or signal lines. One of ordinary skill in the art can understand and implement it without inventive effort.
While the foregoing is directed to the preferred embodiment of the present invention, it will be understood by those skilled in the art that various changes and modifications may be made without departing from the spirit and scope of the invention.

Claims (10)

1. A method for displaying a web page, comprising:
acquiring a website to be accessed by a user;
judging whether a processing scheme corresponding to the website exists or not;
when judging that the corresponding processing scheme exists, initiating an access request to a Web server corresponding to the website, and intercepting an intermediate file returned by the Web server according to the access request;
processing the intermediate file through the processing scheme to generate a processed intermediate file;
and generating a webpage displayed on an interface according to the processed intermediate file.
2. The web page display method according to claim 1, wherein the intermediate file includes an HTML file and a JS script file.
3. The web page display method according to claim 1, further comprising:
acquiring a website input by a user and a processing scheme corresponding to the website, associating the website with the processing scheme, and storing the associated website and the processing scheme in a database.
4. The web page display method according to claim 1, wherein the processing scheme includes an intermediate replacement file for replacement;
processing the intermediate file through the processing scheme to generate a processed intermediate file, which specifically includes:
and replacing the original intermediate file with the intermediate replacement file to generate a processed intermediate file.
5. The method of claim 1, wherein the processing scheme comprises at least one of:
setting the font, font size or font color of the intermediate file;
adding a preset tool control on the intermediate file;
and changing the display style and the page layout of the intermediate file.
6. A web page display apparatus, comprising:
the website acquisition unit is used for acquiring a website to be accessed by a user;
the judging unit is used for judging whether a processing scheme corresponding to the website exists or not;
the intercepting unit is used for initiating an access request to the Web server corresponding to the website when judging that the corresponding processing scheme exists, and intercepting an intermediate file returned by the Web server according to the access request;
the processing unit is used for processing the intermediate file through the processing scheme to generate a processed intermediate file;
and the display unit is used for generating a webpage displayed on an interface according to the processed intermediate file.
7. The web page display apparatus according to claim 6, further comprising:
and the association unit is used for acquiring the website input by the user and the processing scheme corresponding to the website, associating the website with the processing scheme and storing the associated website and the processing scheme in a database.
8. The browser web page display apparatus according to claim 6, wherein the processing scheme includes an intermediate replacement file for replacement;
the processing unit is specifically configured to:
and replacing the original intermediate file with the intermediate replacement file to generate a processed intermediate file.
9. A web page display apparatus comprising a memory and a processor configured to implement the web page display method according to any one of claims 1 to 5 by executing a computer program stored in the memory.
10. A computer-readable storage medium, in which a computer program is stored, the computer program being executable by a processor of a device on which the storage medium is located to implement the web page display method according to any one of claims 1 to 5.
CN202010605548.4A 2020-06-29 2020-06-29 Webpage display method, device, equipment and readable storage medium Pending CN111931090A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010605548.4A CN111931090A (en) 2020-06-29 2020-06-29 Webpage display method, device, equipment and readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010605548.4A CN111931090A (en) 2020-06-29 2020-06-29 Webpage display method, device, equipment and readable storage medium

Publications (1)

Publication Number Publication Date
CN111931090A true CN111931090A (en) 2020-11-13

Family

ID=73316251

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010605548.4A Pending CN111931090A (en) 2020-06-29 2020-06-29 Webpage display method, device, equipment and readable storage medium

Country Status (1)

Country Link
CN (1) CN111931090A (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104426985A (en) * 2013-09-06 2015-03-18 腾讯科技(深圳)有限公司 Method, device and system for displaying webpage
CN106453216A (en) * 2015-08-13 2017-02-22 阿里巴巴集团控股有限公司 Malicious website interception method, malicious website interception device and client
US20180041590A1 (en) * 2015-12-28 2018-02-08 Huawei Technologies Co., Ltd. Website access method, apparatus, and website system
CN110750296A (en) * 2019-10-17 2020-02-04 江苏国泰新点软件有限公司 Application processing method and device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104426985A (en) * 2013-09-06 2015-03-18 腾讯科技(深圳)有限公司 Method, device and system for displaying webpage
CN106453216A (en) * 2015-08-13 2017-02-22 阿里巴巴集团控股有限公司 Malicious website interception method, malicious website interception device and client
US20180041590A1 (en) * 2015-12-28 2018-02-08 Huawei Technologies Co., Ltd. Website access method, apparatus, and website system
CN110750296A (en) * 2019-10-17 2020-02-04 江苏国泰新点软件有限公司 Application processing method and device

Similar Documents

Publication Publication Date Title
CN109254773B (en) Skeleton page generation method, device, equipment and storage medium
CN111782216B (en) Page generation method, server and storage medium
US20140222947A1 (en) Method and apparatus for browsings webpages, and storage medium
CN109684008B (en) Card rendering method, device, terminal and computer readable storage medium
CN105740330B (en) Method and device for displaying data in paging mode
CN105488125A (en) Page access method and apparatus
WO2021184896A1 (en) Page screenshot method and device
CN111782758A (en) Drawing review result viewing method based on CAD and related device
CN111414727A (en) Method and device for editing header and footer of PDF (Portable document Format) document and electronic equipment
CN109656592B (en) Card management method, device, terminal and computer readable storage medium
CN113434063A (en) Information display method, device and equipment
CN111367606A (en) Application page display method, device, terminal and medium
CN111931090A (en) Webpage display method, device, equipment and readable storage medium
CN115543317A (en) Front-end page development method and device
CN114647411A (en) Programming interface loading method and device, electronic equipment and storage medium
CN114860238A (en) Page generation method and device and electronic equipment
CN105589870B (en) Method and system for filtering webpage advertisements
CN113489678A (en) Network protocol switching method and device, computing equipment and storage medium
CN113296841A (en) Application program processing method, device, equipment and medium
CN112433778A (en) Mobile equipment page display method and device, electronic equipment and storage medium
CN112612611A (en) Information processing method, device and system
CN112950167A (en) Design service matching method, device, equipment and storage medium
CN113779438B (en) Webpage text information processing method and device and terminal equipment
CN112818268A (en) Data display method and device, terminal equipment and readable storage medium
CN118041995B (en) Method and device for realizing universal main stream media authorization homepage

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20201113