Embodiment one
Processing method is redirected the embodiments of the invention provide a kind of Webpage.
Fig. 1 is the flow chart for redirecting processing method of Webpage according to embodiments of the present invention.As shown in figure 1, the net
Page the page redirect processing method include step it is as follows:
Step S102, Webpage is shown on the interface of browser;
Redirected specifically, the embodiment of the present invention is applied to control Webpage, before Webpage is realized, it is determined that currently
The Webpage shown on the interface of browser is the page before redirecting, i.e. the Webpage before next page is redirected to.
Step S104, receive redirection and delete instruction, and deleted in Webpage and preserved according to redirection deletion instruction
Redirection instruction;
Specifically, the redirection received deletes instruction, can delete in the Webpage shown in above-mentioned steps S102
What is preserved jumps to the initial redirection instruction for redirecting the page.
For example, current display page is page A, initial redirect in instruction is will to jump to page B from page A, connecing
After having received redirection deletion instruction, redirecting deletion instruction can be jumped to control is used in initial redirection instruction by page A
Page B control command is deleted.
Step S106, target is edited in the page setup of Webpage by Web page editor and redirects mark, wherein, mesh
Mark redirects the jump information that mark is used to characterize target jump page;
Specifically, after step S104 deletes the redirection instruction preserved in Webpage, in order to ensure Webpage
Smoothly redirect, and avoid due to caused by the setting of redirection after redirecting the page perform retract when, still rest on this
The situation of current page occurs, and by Web page editor, target is edited in the page setup of the Webpage before triggering redirects
Mark is redirected, to cause, when Webpage redirects, mark is redirected by target and jumps to target jump page, wherein, target
It is the webpage link address of target jump page to redirect in jump information of the mark for characterizing target jump page, specifically
As described in following step S108.
For example, still exemplified by being illustrated in step S104, page B is correspondingly jumped in initial redirection instruction is deleted
Control command after, in order to which Logistics networks user can smoothly jump to target jump page by page A, then edit target
Target corresponding to jump page redirects mark, so that target jump page can be jumped to by page A by obtaining user.It is of the invention real
It is specially any Webpage that network linking is established with page A to apply the unlimited jump page that sets the goal of example, to realize that the present invention is real
The processing method that redirects for applying the Webpage of example offer is defined, and does not limit specifically.
Step S108, after Webpage triggers jump instruction, Webpage redirects mark according to target and jumps to mesh
Mark jump page.
Specifically, completed according in step S106 in editor after target redirects mark, when Webpage triggers jump instruction
Afterwards, the Webpage will redirect mark according to target and jump to target jump page.
For example, still by taking the citing in above-mentioned steps as an example, after jump instruction is triggered, page A is according in step S106
The target for having edited completion redirects mark and will jump to target jump page.Assuming that target jump page is page C, if in step
Deleted after S104 and the redirection of original webpage is set, the target for editing sensing page C is redirected into mark in step s 106, then
Page A redirects mark according to page C target in this step S108, jumps to page C.
Webpage provided in an embodiment of the present invention redirects processing method, by showing webpage on the interface of browser
The page;Receive redirection and delete instruction, and the redirection preserved in Webpage is deleted according to redirection deletion instruction and is instructed;
Target is edited in the page setup of Webpage by Web page editor and redirects mark, wherein, target redirects mark and is used for table
Levy the jump information of target jump page;After Webpage triggers jump instruction, Webpage redirects mark according to target
Target jump page is jumped to, solves the problems, such as to redirect failure because webpage caused by the setting that webpage redirects retreats, reaches
The effect of the stability redirected to guarantee webpage.
Preferably, in step S104, instruct what the redirection preserved in deletion Webpage instructed according to redirecting to delete
Step includes:
The redirection deleted according to redirecting in instruction deletion Webpage in page metamessage meta label instructs.
Specifically, redirect delete that instruction deletes for the redirection in page metamessage meta label in Webpage
Instruction, wherein, meta is used for the attribute for describing web document, and the attribute of the web document comprises at least:Author, the date, the time,
Webpage description, keyword and page furbishing.
For example, it is used for the instruction for indicating Webpage in label meta:
Meta http-equiv=" ... ", redirect delete instruction will delete it is above-mentioned " ... " in the specific net of instruction
The operation part of page
Preferably, Fig. 2 is the flow chart for redirecting processing method of Webpage according to the preferred embodiment of the invention.Such as figure
Shown in 2, after the redirection instruction that step S104 is deleted and preserved in instruction deletion Webpage according to redirecting, the present invention is real
Applying the processing method that redirects of the Webpage of example offer also includes:
Step S105, the deletion instruction of webpage assignment is received, and instruction is deleted according to webpage assignment and deletes assignment command local
The URL url assignment of the redirection instruction preserved in Webpage is corresponded in window;
Specifically, by taking native window assignment command window.location as an example, deleted due to above-mentioned in step S104
Redirection instruction in Webpage in page metamessage meta label, exemplified by avoid during page jump due to net
The interference of other initial orders in page setting causes Webpage to redirect failure, therefore after above-mentioned steps S104 is completed, connects
Webpage assignment delete command is received, and deletes the assignment in window.location according to webpage assignment delete command, its
In, by taking URL (Uniform Resoure Locator, abbreviation url) as an example, receive webpage assignment and delete life
After order, the url in window.location is deleted according to webpage assignment delete command.
Step S107, receive webpage and redirect object deletion instruction, and object deletion instruction is redirected according to webpage and deleted currently
The jump information of jump page is redirected corresponding to redirection instruction in window skip command.
Specifically, by taking current window skip command window.location.href () as an example, redirected receiving webpage
After object deletes instruction, redirecting object deletion instruction according to the webpage will correspondingly redirect in window.location.href ()
The jump information of the page is deleted, for example, being that will be redirected from page A in still being instructed with the initial redirection in above-mentioned steps S104
It is by window.location.href () when execution webpage redirects object and deletes instruction exemplified by page B into page B
Jump information in middle corresponding page B is deleted.
Preferably, step S106 edits target in the page setup of Webpage by Web page editor and redirects mark
Step includes:
By Web page editor in the page setup of Webpage, the advance unified resource for obtaining target pages is positioned
Symbol url is arranged to target and redirects mark targetURL.
Specifically, the URL for the target jump page for assuming to need to redirect is url, then the url is set
It is set to target and redirects mark targetURL.
Preferably, step S108, Webpage redirect mark according to target and jump to target jump page, including:
Step1. target is redirected into mark and is configured at skip command;
Specifically, by taking skip command window.location.replace () as an example, by above-mentioned steps S106
TargetURL is configured at window.location.replace (), then obtains window.location.replace
(targetURL)。
Step2. the skip command after mark is redirected according to configuration target target jump page is jumped to by Webpage, matched somebody with somebody
Put target redirect mark after skip command be used for according to target redirect mark targetURL jump to target jump page.
Specifically, redirect the skip command window.location.replace after identifying according to target is configured in Step1
(targetURL) targetURL target jump page will, be jumped to.
Due to window.location.replace () during redirection with window.location.href
Turn function shown by () is identical, but from target jump page perform retract when, due to
Window.location.replace () does not have to just retract from current goal jump page to source page by accessing server
Face so that do not produce redirect history while, still be able to point to the source url that prestores by performing to retract, will not occur
The situation of rollback " failure ", also, in target redirects the script js environment of page, redirect refer attributes and remain in that source url,
Therefore to script will not have an impact.
What the embodiment of the present invention additionally provided a kind of Webpage redirects processing unit.The device can pass through Webpage
The processing method that redirects realize its function.It should be noted that the processing unit that redirects of the Webpage of the embodiment of the present invention can
The Webpage provided for the execution embodiment of the present invention redirects processing method, the Webpage of the embodiment of the present invention
Processing unit can also be redirected to perform by the Webpage that the embodiment of the present invention is provided by redirecting processing method.
Fig. 3 is the schematic diagram for redirecting processing unit of Webpage according to embodiments of the present invention.As shown in figure 3, the net
The page page redirects processing unit, including:Display module 32, receiving module 34, control module 36, editor module 38 and redirect mould
Block 40, wherein,
Display module 32, for showing Webpage on the interface of browser;
Receiving module 34, instruction is deleted for receiving to redirect;
Control module 36, establish and electrically connect with receiving module 34, Webpage is deleted for deleting instruction according to redirection
The redirection instruction of middle preservation;
Editor module 38, mark is redirected for editing target in the page setup of Webpage by Web page editor,
Wherein, target redirects the jump information that mark is used to characterize target jump page;
Jump module 40, establish and electrically connect with editor module 38, after triggering jump instruction in Webpage, webpage
The page redirects mark according to target and jumps to target jump page.
Preferably, Fig. 4 is the schematic diagram for redirecting processing unit of Webpage according to the preferred embodiment of the invention.Such as figure
Shown in 4, control module 36 includes:
Control unit 361, for according to the label for redirecting page metamessage meta in deletion instruction deletion Webpage
In redirection instruction.
Preferably, Fig. 5 is the schematic diagram for redirecting processing unit of Webpage according to the preferred embodiment of the invention.Such as figure
Shown in 5, the device also includes:
First command reception module 37, for the redirection preserved in instruction deletion Webpage is deleted according to redirection
After instruction, receive webpage assignment and delete instruction;
First deletes editor module 39, establishes and electrically connects with the first command reception module 37, for being deleted according to webpage assignment
Except instruction, the URL that the redirection instruction preserved in Webpage is corresponded in assignment command native window is deleted
Url assignment;
Second command reception module 41, object deletion instruction is redirected for receiving webpage;
Second deletes editor module 42, establishes and electrically connects with the second command reception module 41, for being redirected pair according to webpage
Instructed as deleting, delete the jump information that jump page is redirected corresponding to the redirection instruction in current window skip command.
Preferably, Fig. 6 is the schematic diagram for redirecting processing unit of Webpage according to the preferred embodiment of the invention.Such as figure
Shown in 6, editor module 38 includes:
Edit cell 381, in the page setup of Webpage, page object will to be obtained in advance by Web page editor
The URL url in face is arranged to target and redirects mark targetURL.
Preferably, Fig. 7 is the schematic diagram for redirecting processing unit of Webpage according to the preferred embodiment of the invention.Such as figure
Shown in 7, jump module 40 includes:
Dispensing unit 401, skip command is configured at for target to be redirected into mark;
Jump-transfer unit 402, establish and electrically connect with dispensing unit 401, for redirecting redirecting after identifying according to configuration target
Order jumps to target jump page by Webpage, and configuration target redirects the skip command after identifying and is used to redirect according to target
Mark targetURL jumps to target jump page.
It should be noted that for foregoing each method embodiment, in order to be briefly described, therefore it is all expressed as a series of
Combination of actions, but those skilled in the art should know, the present invention is not limited by described sequence of movement because
According to the present invention, some steps can use other orders or carry out simultaneously.Secondly, those skilled in the art should also know
Know, embodiment described in this description belongs to preferred embodiment, and involved action and module are not necessarily of the invention
It is necessary.
In the above-described embodiments, the description to each embodiment all emphasizes particularly on different fields, and does not have the portion being described in detail in some embodiment
Point, it may refer to the associated description of other embodiment.
In several embodiments provided herein, it should be understood that disclosed device, can be by another way
Realize.For example, device embodiment described above is only schematical, such as the division of the unit, it is only one kind
Division of logic function, can there is an other dividing mode when actually realizing, such as multiple units or component can combine or can
To be integrated into another system, or some features can be ignored, or not perform.Another, shown or discussed is mutual
Coupling direct-coupling or communication connection can be by some interfaces, the INDIRECT COUPLING or communication connection of device or unit,
Can be electrical or other forms.
The unit illustrated as separating component can be or may not be physically separate, show as unit
The part shown can be or may not be physical location, you can with positioned at a place, or can also be distributed to multiple
On NE.Some or all of unit therein can be selected to realize the mesh of this embodiment scheme according to the actual needs
's.
In addition, each functional unit in each embodiment of the present invention can be integrated in a processing unit, can also
That unit is individually physically present, can also two or more units it is integrated in a unit.Above-mentioned integrated list
Member can both be realized in the form of hardware, can also be realized in the form of SFU software functional unit.
If the integrated unit is realized in the form of SFU software functional unit and is used as independent production marketing or use
When, it can be stored in a computer read/write memory medium.Based on such understanding, technical scheme is substantially
The part to be contributed in other words to prior art or all or part of the technical scheme can be in the form of software products
Embody, the computer software product is stored in a storage medium, including some instructions are causing a computer
Equipment (can be personal computer, mobile terminal, server or network equipment etc.) performs side described in each embodiment of the present invention
The all or part of step of method.And foregoing storage medium includes:USB flash disk, read-only storage (ROM, Read-Only Memory),
Random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disc or CD etc. are various to be stored
The medium of program code.
The preferred embodiments of the present invention are the foregoing is only, are not intended to limit the invention, for the skill of this area
For art personnel, the present invention can have various modifications and variations.Within the spirit and principles of the invention, that is made any repaiies
Change, equivalent substitution, improvement etc., should be included in the scope of the protection.