Disclosure of Invention
In view of this, embodiments of the present invention provide a method and an apparatus for redirecting a multi-level page, which can implement, through rendering a page for multiple times, after a frame page based on layout is submitted through a form, an autonomous selection to jump to a certain specified page of the multi-level page.
To achieve the above object, according to an aspect of the embodiments of the present invention, there is provided a method for displaying a multi-level page, the multi-level page including a first page and at least one second page, the method including: responding to a form submission request of a user, and generating full address information; acquiring the full address information through a preset buried point, and determining an identifier of a page to be loaded according to the full address information; and loading the page according to the identifier of the page to be loaded so as to redirect to the page to be loaded.
Optionally, loading the page according to the identifier of the page to be loaded includes:
when the identifier of the page to be loaded is the identifier of the home page, loading the home page;
and when the identifier of the page to be loaded is the identifier of the secondary page, loading the first page first, and after the loading of the first page is finished, loading the secondary page.
Optionally, after the loading of the first page is completed, the loading of the secondary page includes:
after the loading of the home page is finished, outputting a confirmation bullet frame;
and loading the secondary page in response to the confirmation operation of the user.
Optionally, the identifier of the multi-level page is set according to the following rule:
the identification of the first page is composed of one parameter, and the identification of the N-level page is composed of N parameters, wherein N is an integer greater than or equal to 1.
To achieve the above object, according to another aspect of the embodiments of the present invention, there is provided a redirection apparatus for a multi-level page, the multi-level page including a first page and at least one secondary page, the apparatus including: the information generation module is used for responding to a form submission request of a user and generating full address information; the page identification determining module is used for acquiring the full address information through a preset buried point and determining the identification of the page to be loaded according to the full address information; and the page rendering module is used for loading the page according to the identifier of the page to be loaded so as to redirect to the page to be loaded.
Optionally, the page rendering module is further configured to: when the identifier of the page to be loaded is the identifier of the home page, loading the home page; and when the identifier of the page to be loaded is the identifier of the secondary page, loading the first page first, and after the loading of the first page is finished, loading the secondary page.
Optionally, the page rendering module is further configured to: after the loading of the home page is finished, outputting a confirmation bullet frame; and loading the secondary page in response to the confirmation operation of the user.
Optionally, the identifier of the multi-level page is set according to the following rule:
the identification of the first page is composed of one parameter, and the identification of the N-level page is composed of N parameters, wherein N is an integer greater than or equal to 1.
To achieve the above object, according to still another aspect of embodiments of the present invention, there is provided an electronic apparatus including: one or more processors; the storage device is used for storing one or more programs, and when the one or more programs are executed by the one or more processors, the one or more processors realize the redirection method of the multi-level page in the embodiment of the invention.
To achieve the above object, according to still another aspect of the embodiments of the present invention, there is provided a computer readable medium having stored thereon a computer program, which when executed by a processor, implements a redirection method of a multi-level page of the embodiments of the present invention.
One embodiment of the above invention has the following advantages or benefits: because the form submission request responding to the user is adopted, the full address information is generated; acquiring the full address information through a preset buried point, and determining an identifier of a page to be loaded according to the full address information; according to the technical means of loading the page according to the identifier of the page to be loaded, the page can be rendered for multiple times, and after the page is submitted through a form in a framework page based on layout, the user can autonomously select to jump to a certain specified page of a multi-level page.
Further effects of the above-mentioned non-conventional alternatives will be described below in connection with the embodiments.
Detailed Description
Exemplary embodiments of the present invention are described below with reference to the accompanying drawings, in which various details of embodiments of the invention are included to assist understanding, and which are to be considered as merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the invention. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
Fig. 1 is a schematic diagram of a main flow of a redirection method of a multi-level page according to an embodiment of the present invention. The method is suitable for a multi-level page constructed based on a layout frame page mode, and the address bar only shows the domain name and does not show the connection address information of the URI. As a specific example, the full address information is http:// talk.jr.com/mail controller.htm? 100& type-1, the only information shown in the address column is the domain name http:// talk.jr.com, and the connection address information/mail controller.htm? id 100& type-1.
As shown in fig. 1, the method includes:
step S101: and responding to a form submission request of a user, and generating full address information.
The user submits the form in a certain secondary page, at the moment, the data in the form is sent to the background server for processing, and the background server generates the full address information after processing the data. The full address information may be composed of a domain name and connection address information of the URI, or may be composed of a domain name and an identifier of a page to be loaded.
In an alternative embodiment, the identity of the page may be set according to the following: the identification of the first page is composed of one parameter, and the identification of the N-level page is composed of N parameters, wherein N is an integer greater than or equal to 1. For example, the identifier of the primary page is composed of one parameter (e.g., style), the parameter takes different values to represent different primary pages, the identifier of the secondary page is composed of two parameters (e.g., style and id), and the parameter takes different values to represent which secondary page under which primary page the secondary page is. When the requirement changes, the redirected page also needs to change, and the parameters in the code need to be changed, so that the identifier of the page is set according to the method, the change is easy, and the management is convenient.
In other alternative embodiments, the page identifier may be set in other manners, for example, different pages are represented by different natural numbers, and the invention is not limited herein.
Step S102: and acquiring the full address information through a preset buried point, and determining the identification of the page to be loaded according to the full address information.
In an alternative embodiment the buried dots are pre-added in the top page. A buried point is a related technology and its implementation process for capturing, processing and transmitting specific user behavior or events. In this embodiment, the buried point is a related technology and implementation process thereof for capturing, processing and sending user behavior submitted by form.
Step S103: and loading the page according to the identifier of the page to be loaded.
When the identifier of the page to be loaded is the identifier of the home page, loading the home page;
and when the identifier of the page to be loaded is the identifier of the secondary page, loading the first page first, and after the loading of the first page is finished, loading the secondary page.
The redirection method of the multi-level page adopts a form submission request responding to a user to generate full address information; acquiring the full address information through a preset buried point, and determining an identifier of a page to be loaded according to the full address information; according to the technical means of loading the page according to the identifier of the page to be loaded, the page can be rendered for multiple times, and after the page is submitted through a form in a framework page based on layout, the page can be automatically selected to jump to a certain specified page of a multi-level page.
In an optional embodiment, the method further comprises outputting a confirmation bullet box after the first page loading is completed; and loading the secondary page in response to the confirmation operation of the user.
And when the page to be loaded is a secondary page, loading the primary page first and controlling the right to the back end. After the home page is loaded, a confirmation bullet box is output, the control right is handed over to a front-end user, if the user does not want page redirection at the moment, the page redirection can be prevented, the user is more humanized, and the user experience is improved.
As shown in fig. 2, a multi-level page jump method according to an embodiment of the present invention is described by using a specific example.
(1) And adding a buried point in the home page to prepare for page redirection, wherein the buried point value is transmitted by the background server.
(2) Clicking a left menu item (such as menu 2) in the home page, and loading a list 1 page (the list 1 page is a first-level page) by the page placeholder part at the moment; clicking a button 1 in a page of the list 1, loading a page of the list 2 by a page placeholder part (the page of the list 2 is a secondary page) at the moment, and transmitting a buried point to the page of the list 2; clicking a button 2 in the page of the list 2, at this time, loading the form detail page (the form detail page is a three-level page) by the page placeholder part, and transferring the buried point to the form detail page.
(3) After completing the completion of the submission of the detail page, the user clicks the form submission button 3 in the form detail page, at this time, the data is sent to the background, after the background finishes processing the data, the full address information is generated, and the buried point acquires the full address information and analyzes and determines the identifier of the page to be loaded.
(4) And loading a js script of the home page, taking the value of the embedded point by the js script, and judging the value of the embedded point. If the first page needs to be loaded, directly loading; if the list 1 page or the list 2 page needs to be loaded, the first page is loaded at this time, then a confirmation popup box pops up, the list 1 page or the list 2 page is loaded after the confirmation of the user, different pages are rendered and loaded for multiple times, and the file form of the multi-level page is submitted and then returned to a specified middle page.
Fig. 3 is a schematic diagram of main blocks of a redirection apparatus 300 for a multi-level page according to an embodiment of the present invention, the multi-level page including a first page and at least one secondary page.
As shown in fig. 3, the apparatus 300 includes:
the information generating module 301 is configured to generate full address information in response to a form submission request of a user;
a page identifier determining module 302, configured to obtain the full address information through a preset buried point, and determine an identifier of a page to be loaded according to the full address information;
and a page rendering module 303, configured to load a page according to the identifier of the page to be loaded.
Optionally, the page rendering module 303 is further configured to: when the identifier of the page to be loaded is the identifier of the home page, loading the home page; and when the identifier of the page to be loaded is the identifier of the secondary page, loading the first page first, and after the loading of the first page is finished, loading the secondary page.
Optionally, the page rendering module is further configured to: after the loading of the home page is finished, outputting a confirmation bullet frame; and loading the secondary page in response to the confirmation operation of the user.
Optionally, the identifier of the multi-level page is set according to the following rule: the identification of the first page is composed of one parameter, and the identification of the N-level page is composed of N parameters, wherein N is an integer greater than or equal to 1.
The redirection device of the multi-level page of the embodiment of the invention adopts a form submission request responding to a user to generate full address information; acquiring the full address information through a preset buried point, and determining an identifier of a page to be loaded according to the full address information; according to the technical means of loading the page according to the identifier of the page to be loaded, the page can be rendered for multiple times, and after the page is submitted through a form in a framework page based on layout, the user can autonomously select to jump to a certain specified page of a multi-level page.
The device can execute the method provided by the embodiment of the invention, and has the corresponding functional modules and beneficial effects of the execution method. For technical details that are not described in detail in this embodiment, reference may be made to the method provided by the embodiment of the present invention.
Fig. 4 illustrates an exemplary system architecture 400 of a redirection method for a multi-level page or a redirection apparatus for a multi-level page to which an embodiment of the present invention may be applied.
As shown in fig. 4, the system architecture 400 may include terminal devices 401, 402, 403, a network 404, and a server 405. The network 404 serves as a medium for providing communication links between the terminal devices 401, 402, 403 and the server 405. Network 404 may include various types of connections, such as wire, wireless communication links, or fiber optic cables, to name a few.
A user may use terminal devices 401, 402, 403 to interact with a server 405 over a network 404 to receive or send messages or the like. The terminal devices 401, 402, 403 may have various communication client applications installed thereon, such as shopping applications, web browser applications, search applications, instant messaging tools, mailbox clients, social platform software, and the like.
The terminal devices 401, 402, 403 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop portable computers, desktop computers, and the like.
The server 405 may be a server that provides various services, such as a background management server that supports shopping websites browsed by users using the terminal devices 401, 402, and 403. The background management server may analyze and perform other processing on the received data such as the product information query request, and feed back a processing result (e.g., target push information and product information) to the terminal device.
It should be noted that the redirection method for the multi-level page provided by the embodiment of the present invention is generally executed by the server 405, and accordingly, the redirection apparatus for the multi-level page is generally disposed in the server 405.
It should be understood that the number of terminal devices, networks, and servers in fig. 4 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for implementation.
Referring now to FIG. 5, shown is a block diagram of a computer system 500 suitable for use with a terminal device implementing an embodiment of the present invention. The terminal device shown in fig. 5 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present invention.
As shown in fig. 5, the computer system 500 includes a Central Processing Unit (CPU)501 that can perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM)502 or a program loaded from a storage section 508 into a Random Access Memory (RAM) 503. In the RAM 503, various programs and data necessary for the operation of the system 500 are also stored. The CPU 501, ROM 502, and RAM 503 are connected to each other via a bus 504. An input/output (I/O) interface 505 is also connected to bus 504.
The following components are connected to the I/O interface 505: an input portion 506 including a keyboard, a mouse, and the like; an output portion 507 including a display such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, and a speaker; a storage portion 508 including a hard disk and the like; and a communication section 509 including a network interface card such as a LAN card, a modem, or the like. The communication section 509 performs communication processing via a network such as the internet. The driver 510 is also connected to the I/O interface 505 as necessary. A removable medium 511 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 510 as necessary, so that a computer program read out therefrom is mounted into the storage section 508 as necessary.
In particular, according to the embodiments of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network through the communication section 509, and/or installed from the removable medium 511. The computer program performs the above-described functions defined in the system of the present invention when executed by the Central Processing Unit (CPU) 501.
It should be noted that the computer readable medium shown in the present invention can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present invention, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present invention, however, a computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The modules described in the embodiments of the present invention may be implemented by software or hardware. The described modules may also be provided in a processor, which may be described as: a processor includes a sending module, an obtaining module, a determining module, and a first processing module. The names of these modules do not in some cases constitute a limitation on the unit itself, and for example, the sending module may also be described as a "module that sends a picture acquisition request to a connected server".
As another aspect, the present invention also provides a computer-readable medium that may be contained in the apparatus described in the above embodiments; or may be separate and not incorporated into the device. The computer readable medium carries one or more programs which, when executed by a device, cause the device to comprise:
responding to a form submission request of a user, and generating full address information;
acquiring the full address information through a preset buried point, and determining an identifier of a page to be loaded according to the full address information;
and loading the page according to the identifier of the page to be loaded so as to redirect to the page to be loaded.
According to the technical scheme of the embodiment of the invention, full address information is generated by adopting a form submission request responding to a user; acquiring the full address information through a preset buried point, and determining an identifier of a page to be loaded according to the full address information; according to the technical means of loading the page according to the identifier of the page to be loaded, the page can be rendered for multiple times, and after the page is submitted through a form in a framework page based on layout, the page can be automatically selected to jump to a certain specified page of a multi-level page.
The above-described embodiments should not be construed as limiting the scope of the invention. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions can occur, depending on design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.