CN109542402A - A method of adaptive is used for more portal website's seamless switchings - Google Patents
A method of adaptive is used for more portal website's seamless switchings Download PDFInfo
- Publication number
- CN109542402A CN109542402A CN201811189978.1A CN201811189978A CN109542402A CN 109542402 A CN109542402 A CN 109542402A CN 201811189978 A CN201811189978 A CN 201811189978A CN 109542402 A CN109542402 A CN 109542402A
- Authority
- CN
- China
- Prior art keywords
- view
- portal website
- rewriting
- web application
- adaptive method
- 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
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/20—Software design
Abstract
The invention discloses a kind of adaptive methods for more portal website's seamless switchings, and particularly belong to Web Hosting field, this method comprises the following steps: S01, multiple and different domain names are connected to front server by the conversion and direction of dns server.S02, the front server are requested by reverse proxy Http, and key corresponding to each domain name is transmitted to the control layer applied in web application container.S03, the control layer carry out business logic processing, the corresponding view shown of web application container output according to key.S04, view file show after page rendering to user.The present invention has the advantages that adaptive different user and maintenance cost are low.
Description
Technical field
The invention belongs to Web Hosting field, specially a kind of adaptive side for more portal website's seamless switchings
Method.
Background technique
Currently, usually there are two types of modes when user needs to show project or own body by the way of personalized:
One, corresponding to present accordingly according to the self information of user, such as regional information after target user's logon account
Ways of presentation.However, the above method can not accomplish that the portal for judging that the user is adapted in the case where user exempts from login shows
Mode, universality be not strong.
Two, technical staff develops different website items by different domain name or network address.However, using aforesaid way
When, there are certain multiplexings, such as database data, picture and video for storage end.But almost all of logic business all needs
Again it to develop, when occurring only needing to be shown between different portal website or distributing adjustment, exist a large amount of
Overlapping development work, and the higher cost in updating maintenance.
Summary of the invention
The present invention provides a kind of adaptive method for more portal website's seamless switchings, this method has adaptive
The low advantage of different users and maintenance cost.
To achieve the above object, the invention provides the following technical scheme:
A method of adaptive is used for more portal website's seamless switchings, and this method comprises the following steps:
S01, multiple and different domain names are connected to front server by the conversion and direction of dns server;
S02, the front server are requested by reverse proxy Http, and key corresponding to each domain name is transmitted to web
The control layer applied in application container;
S03, the control layer carry out business logic processing, the corresponding view shown of web application container output according to key;
S04, view file show after page rendering to user.
Preferably, the view file includes rewriting view and base view in step S03.
As further preferred, in step S03: rewrite all view files in view be on demand with base view
The mode that view file is born the same name is placed in, and all view files rewritten in view can inherit the view text of base view automatically
Part.
Preferably, in step S03 further include: judge that the rewriting view whether there is, in the presence of rewriting view,
View is rewritten in the output of web application container;In the absence of rewriting view, web application container exports base view.
Preferably, step S03 further include: remove request using caching and remove key and rewrite view or base view
List corresponding to view-set, for increasing view or rewriting view.
Preferably, the front server is selected from least one of Nginx and Apache in step S01.
Preferably, web application container is selected from least one of Tomcat, jetty and JBoss.
The invention has the benefit that
Scheme provided by the invention differentiates different website portals using domain name.View layer and control by MVC
The characteristic of preparative layer separation uses different exhibition methods for different domain name Auto-matchings, and guarantees that the whole of control layer is multiple
With, while only needing to rewrite the page for the view layer for needing to rewrite with covering part, by the succession of the class in software development and again
It writes in the mode for extending to the MVC of Website development.The efficiency for greatly improving exploitation, using and disposing.
Detailed description of the invention
Fig. 1 is a kind of flow diagram of the adaptive method for more portal website's seamless switchings in the present embodiment.
Specific embodiment
The present embodiment provides a kind of technical solutions:
A method of adaptive is used for more portal website's seamless switchings, and this method comprises the following steps:
S01, multiple and different domain names pass through the conversion of dns server and are respectively directed to be connected in Nginx and Apache.
S02, above-mentioned front server Nginx and Apache are requested by reverse proxy Http, will be corresponding to each domain name
Key be transmitted to the control layer applied in web application container.Wherein web application container include Tomcat, jetty and
JBoss。
S03, control layer carry out corresponding business logic processing according to key.Wherein:
View mentioned by the present embodiment includes rewriting view and base view.Rewriting all view files in view is
The mode born the same name on demand with the view file of base view is placed in, and all view files rewritten in view can be inherited automatically
The view file of base view.
When technical staff needs to increase above-mentioned view or rewrites above-mentioned view, it caching can be used to remove request and remove
List corresponding to the view-set of key and rewriting view or base view.
Before showing view, also need to judge that the rewriting view whether there is, in the presence of rewriting view, web application
View is rewritten in container output;In the absence of rewriting view, web application container exports base view.
After business logic processing, the web application container, that is, exportable corresponding view shown.
S04, view show after page rendering to user.
Although the present invention is described in detail referring to the foregoing embodiments, for those skilled in the art,
It is still possible to modify the technical solutions described in the foregoing embodiments, or part of technical characteristic is carried out etc.
With replacement, all within the spirits and principles of the present invention, any modification, equivalent replacement, improvement and so on should be included in this
Within the protection scope of invention.
Claims (7)
1. a kind of adaptive method for more portal website's seamless switchings, which comprises the steps of:
S01, multiple and different domain names are connected to front server by the conversion and direction of dns server;
S02, the front server are requested by reverse proxy Http, and key corresponding to each domain name is transmitted to web application
The control layer applied in container;
S03, the control layer carry out business logic processing, the corresponding view shown of web application container output according to key;
S04, the view show after page rendering to user.
2. a kind of adaptive method for more portal website's seamless switchings according to claim 1, which is characterized in that
In step S03, the view file includes rewriting view and base view.
3. a kind of adaptive method for more portal website's seamless switchings according to claim 2, which is characterized in that
In step S03: rewriting all view files in view is that the mode born the same name on demand with the view file of base view is placed in,
And all view files rewritten in view can inherit the view file of base view automatically.
4. a kind of adaptive method for more portal website's seamless switchings according to claim 2 or 3, feature exist
In in step S03 further include: judge that the rewriting view whether there is, in the presence of rewriting view, the output of web application container
Rewrite view;In the absence of rewriting view, web application container exports base view.
5. a kind of adaptive method for more portal website's seamless switchings according to claim 2, which is characterized in that
Step S03 further include: remove request removing key using caching and rewrite column corresponding to the view-set of view or base view
Table, for increasing the view or rewriting the view.
6. a kind of adaptive method for more portal website's seamless switchings according to claim 1, which is characterized in that
In step S01, the front server is selected from least one of Nginx and Apache.
7. a kind of adaptive method for more portal website's seamless switchings according to claim 1, which is characterized in that
Web application container is selected from least one of Tomcat, jetty and JBoss.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811189978.1A CN109542402A (en) | 2018-10-12 | 2018-10-12 | A method of adaptive is used for more portal website's seamless switchings |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811189978.1A CN109542402A (en) | 2018-10-12 | 2018-10-12 | A method of adaptive is used for more portal website's seamless switchings |
Publications (1)
Publication Number | Publication Date |
---|---|
CN109542402A true CN109542402A (en) | 2019-03-29 |
Family
ID=65843877
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201811189978.1A Pending CN109542402A (en) | 2018-10-12 | 2018-10-12 | A method of adaptive is used for more portal website's seamless switchings |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109542402A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112035174A (en) * | 2019-05-16 | 2020-12-04 | 杭州海康威视数字技术股份有限公司 | Method, apparatus and computer storage medium for running web service |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103116580A (en) * | 2011-11-16 | 2013-05-22 | 中国移动通信集团公司 | Providing method, system and device of website content information |
CN103123593A (en) * | 2011-11-18 | 2013-05-29 | 腾讯科技(深圳)有限公司 | Java application server and method for processing Web service |
CN103973819A (en) * | 2013-01-25 | 2014-08-06 | 搜房媒体技术(北京)有限公司 | Method, related device and system for responding to request for community domain name |
US20150127706A1 (en) * | 2013-07-09 | 2015-05-07 | Tencent Technology (Shenzhen) Company Limited | Systems and Methods for Data Extraction |
-
2018
- 2018-10-12 CN CN201811189978.1A patent/CN109542402A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103116580A (en) * | 2011-11-16 | 2013-05-22 | 中国移动通信集团公司 | Providing method, system and device of website content information |
CN103123593A (en) * | 2011-11-18 | 2013-05-29 | 腾讯科技(深圳)有限公司 | Java application server and method for processing Web service |
CN103973819A (en) * | 2013-01-25 | 2014-08-06 | 搜房媒体技术(北京)有限公司 | Method, related device and system for responding to request for community domain name |
US20150127706A1 (en) * | 2013-07-09 | 2015-05-07 | Tencent Technology (Shenzhen) Company Limited | Systems and Methods for Data Extraction |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112035174A (en) * | 2019-05-16 | 2020-12-04 | 杭州海康威视数字技术股份有限公司 | Method, apparatus and computer storage medium for running web service |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109388766B (en) | Page loading method and device | |
CN100462964C (en) | Updating display method for webpage data | |
WO2008042877A3 (en) | Dynamically configured rendering of digital maps | |
US20070174420A1 (en) | Caching of web service requests | |
US20170270083A1 (en) | Web-intrinsic interactive documents | |
MXPA04008383A (en) | Systems and methods for ranking documents based upon structurally interrelated information. | |
US20100088326A1 (en) | Service oriented architecture aggregation | |
CN101571876B (en) | Script program operation logic expansion method, server and client | |
US9674309B2 (en) | Data sharing | |
US20150244827A1 (en) | Data Transmission | |
CN113900628B (en) | Vue-based multi-page label instance caching method | |
US11036923B2 (en) | Structured document creation and processing, dynamic data storage and reporting system | |
CN107545058A (en) | A kind of page loading method, server and browser | |
CN110826978A (en) | Unified backlog processing method and device based on enterprise browser | |
CN109542402A (en) | A method of adaptive is used for more portal website's seamless switchings | |
US20150256589A1 (en) | Data processing systems and methods | |
CN103678295A (en) | Method and device for providing files for user | |
JP2017521759A (en) | Computer-implemented method, computer program, and apparatus for correlating artifacts between versioned and unversioned domains | |
US11227009B1 (en) | Text de-obfuscation with image recognition of text | |
CN104461509A (en) | Information interaction framework and method | |
CN106598933B (en) | A kind of web-based type-setting document proofreading method and equipment | |
CN104361094A (en) | Storage method and device for file in search result, and browser client | |
US10324906B2 (en) | Intelligent XML file fragmentation | |
Edsall | Interface Modalities | |
CN107172130B (en) | MVC (model view controller) registration implementation method and server |
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 | ||
TA01 | Transfer of patent application right | ||
TA01 | Transfer of patent application right |
Effective date of registration: 20200710 Address after: Room 1101, building 3, No. 88, Xiangyuan Road, Gongshu District, Hangzhou City, Zhejiang Province Applicant after: ZHEJIANG TOP CLOUD-AGRI TECHNOLOGY Co.,Ltd. Address before: Yuhang District of Hangzhou city Zhejiang province 311100 Liangzhu Street Bridge Village Building 1 layer 1-2 Qixian Applicant before: HANGZHOU GONGYUE MACHINERY MANUFACTURING Co.,Ltd. |