CN103235737A - Frameset-based browser dialog box simulation method - Google Patents

Frameset-based browser dialog box simulation method Download PDF

Info

Publication number
CN103235737A
CN103235737A CN2013101186323A CN201310118632A CN103235737A CN 103235737 A CN103235737 A CN 103235737A CN 2013101186323 A CN2013101186323 A CN 2013101186323A CN 201310118632 A CN201310118632 A CN 201310118632A CN 103235737 A CN103235737 A CN 103235737A
Authority
CN
China
Prior art keywords
dialog box
parameter
script
frameset
insert
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
CN2013101186323A
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 Meiya Pico Information Co Ltd
Original Assignee
Xiamen Meiya Pico Information 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 Meiya Pico Information Co Ltd filed Critical Xiamen Meiya Pico Information Co Ltd
Priority to CN2013101186323A priority Critical patent/CN103235737A/en
Publication of CN103235737A publication Critical patent/CN103235737A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • User Interface Of Digital Computer (AREA)

Abstract

The invention provides a Frameset-based browser dialog box simulation method. A Frameset page is embedded into a homepage, a transparent drawing layer capable of covering any element and a dialog box or Iframe window which supports any html are placed on the page, JS (JavaScript) codes are cached on the page, and execution can not be continued until the dialog box or the window is closed. Through the method, coverage of a Frameset framework is supported, a JS blockage simulation effect is achieved, and opening of modal windows is supported.

Description

Simulation browser session frame method based on Frameset
Technical field
The present invention relates to a kind of Internet technology, refer in particular to a kind of simulation browser session frame method based on Frameset.
Background technology
Browser carries four kinds of dialog box patterns at present
1, the dialog box pattern is Alert(warning window): browser can eject a prompting frame as shown in Figure 1.
2, the dialog box pattern is that Confirm(confirms window): browser can eject an affirmation window as shown in Figure 2.
3, the dialog box pattern is that browser ejects an input frame as shown in Figure 3.
The advantage of above-mentioned three kinds of dialog box patterns all is: call conveniently, can block the js(javaScript script) process.
Yet shortcoming then is: dialog interface is simple, does not support the portly prompting prompting of image content (namely with), and window title and button name can't change, and the prompting frame style is far short of what is expected, depends on that different browsers has different patterns respectively.
4, the dialog box pattern is that browser ejects a web page dialog box as shown in Figure 4.
The advantage of this kind dialog box pattern is: can call a self-defining page, can block the js(javaScript script) process.
Shortcoming: the time of opening length consuming time, the literal on the page can not be selected copy, supported web page right-click menu not, the frame ugliness is at page jump and Post(bulletin) in the Bug(fault is arranged).
As seen, the style disunity that though the dialog box that system carries is called the advantages of simplicity and high efficiency advantage, extendability is poor, show under the browser of different system, do not support the HTML prompting, realize that the simple and aesthetic property difference of function also is very fatal shortcoming.For this reason, the bullet window that carries except system, the method that many imitating shell windows are also arranged in the prior art, but it is to adopt div or Iframe to hide mode basically, yet this kind mode namely can not cover the Frameset framework, do not have simulated blocked js(javaScript script) process, some does not support to open window yet.
Summary of the invention
The objective of the invention is to overcome above-mentioned defective, a kind of simulation browser session frame method based on Frameset is provided.
The object of the present invention is achieved like this:
The method of the bullet window that carries than system and common imitating shell window, beneficial effect of the present invention has been to provide a kind of simulation browser session frame method based on Frameset, can support to cover the Frameset framework by this method, realize after the browser session frame is closed, continuing to carry out JS again, simulated blocked JS effect supports to open modal window.
Description of drawings
Below in conjunction with accompanying drawing in detail concrete structure of the present invention is described in detail
The dialog box synoptic diagram of the warning window pattern that Fig. 1 carries for existing system;
The dialog box synoptic diagram of the affirmation window pattern that Fig. 2 carries for existing system;
The dialog box synoptic diagram of the input frame pattern that Fig. 3 carries for existing system;
The web page dialog box synoptic diagram that Fig. 4 carries for existing system;
Fig. 5 is the dialog box synoptic diagram of the warning window pattern of the present invention's simulation;
Fig. 6 is the dialog box synoptic diagram of the affirmation window pattern of the present invention's simulation;
Fig. 7 is the dialog box synoptic diagram of the input frame pattern of the present invention's simulation;
The tabulation that Fig. 8 derives for the present invention arranges the dialog box synoptic diagram;
The Advanced Search dialog box synoptic diagram that Fig. 9 derives for the present invention;
Figure 10 is the web page dialog box synoptic diagram of the present invention's simulation.
Embodiment
By describing technology contents of the present invention, structural attitude in detail, realized purpose and effect, give explanation below in conjunction with embodiment and conjunction with figs. are detailed.
Because the Frameset page can't insert any other interface element again, so cover Frameset if desired, need the Frameset page is embedded into the Iframe the inside of a homepage, method below using can make the Frameset page in the use and the effect when not embedding is living.
The invention provides a kind of simulation browser session frame method based on Frameset, it comprises step,
A), use javaScript calls imitating shell frame function, and imports the dialog box parameter into;
B), forbidding Webpage scroll bar, and the Webpage back gauge is set is 0.
By the setting of this step, just can accomplish really full frame.
Example code:<body style=" margin:0px; Overflow:hidden; "
C), insert the Iframe of (width 100%, height 100%) all over the screen on Webpage (the top page---just embed the homepage of Frameset) top.
The purpose of using Iframe to cover is because the combobox control of some browsers can't be covered by other any elements except Iframe.
Example code:
<iframe?id="MainFrame"frameborder="0"scrolling="no"style="width:100%;height:100%;"src="MainFrm.html"></iframe>
D), insert the div layer of a grey transparency 50% all over the screen on the Webpage top.
The purpose of using this layer is for outstanding covering effect, allows the people understand that at a glance gray area is can not operating area
E), insert a table all over the screen on the Webpage top, be used as the container of placing dialog box.
Attribute placed in the middle with placed in the middle up and down about it is set, and it mainly acts on is to guarantee that source body can be fixed in the centre of forms.
F), in container, put into imitating shell frame function.
Specific embodiment 1:
Shown in Fig. 5-9, realize the imitating shell frame with the inventive method:
A), use javaScript calls imitating shell frame function, and imports dialog box parameter: title, msg, alertimg, sureScript, cancelScript, width, btnSureValue, btnCancelValue into
Wherein correspondence is defined as:
Title: the dialog box topic parameter, support html format (not recommending);
Msg: dialog box message content parameter, support html format;
Alertimg: the icon parameter of dialog box topic front, for the words of sky are used default icon;
Surescript: determine script, be a words close box of sky;
CancelScript: the cancellation script, for the words of sky do not have cancel button;
Width: the dialog box width parameter is the words acquiescence width of sky;
BtnSureValue: confirming button text parameter;
BtnCancelValue: cancel button text parameter.
Import surescript and cancelScript parameter in this step into, can simulate the script blocking-up event of dialog box.
Example code:
B), forbidding Webpage scroll bar, and the Webpage back gauge is set is 0.
By the setting of this step, just can accomplish really full frame.
Example code:<body style=" margin:0px; Overflow:hidden; "
C), insert the Iframe of (width 100%, height 100%) all over the screen on Webpage (the top page---just embed the homepage of Frameset) top.
The purpose of using Iframe to cover is because the combobox control of some browsers can't be covered by other any elements except Iframe.
Example code:
<iframe?id="frmMessage"frameborder="0"scrolling="no"style="position:abs-olute;z-index:3;width:100%;height:100%;filter:alpha(opacity=0);left:0px;top:0px;"></iframe>
D), insert the div layer of a grey transparency 50% all over the screen on the Webpage top.
The purpose of using this layer is for outstanding covering effect, allows the people understand that at a glance gray area is can not operating area.
Example code:
<div?id="dvMessageFilter"style="width:100%;height:100%;position:absolut-e;z-index:4;left:0px;top:0px;background-color:#000000;filter:alpha(opacity=50);-moz-opacity:0.50;opacity:0.50;"></div>
E), insert a table all over the screen on the Webpage top, be used as the container of placing dialog box.
Attribute placed in the middle with placed in the middle up and down about it is set, and it mainly acts on is to guarantee that source body can be fixed in the centre of forms.
Example code:
<table?id="tbMessageContainer"style="width:100%;height:100%;position:ab-solute;z-index:5;left:0px;top:0px;"><tr><td?style="vertical-align:middle;text-align:center;">
F), the table that inserts corresponding width according to dialog box width parameter width in container is as the message box main body, at these table insertion 3 row, respectively as header area, message area, button area;
G), in the row of header area, insert icon according to the icon parameter alertimg of dialog box topic front, insert caption text according to dialog box topic parametric t itle;
In the row of message area, put into content according to dialog box message content parameter m sg; This dialog box message content parameter m sg can comprise html.
Judge the cancellation script cancelScript that imports into, if sky then shields cancel button, in the row of button area, according to confirming button text parameter btnSureValue and cancel button text parameter btnCancelValue confirming button and cancel button are set;
Example code:
Figure BDA00003020048800061
H), will determine that script surescript deposits global variable in and determines among the script tmpsurescript, cancellation script cancelScript deposits among the global variable cancellation script tmpcancelScript, waits for the triggering of confirming button or cancel button;
I), after confirming button triggers.Judge global variable determines whether script tmpsurescript is empty, does not then carry out global variable for sky and determines script tmpsurescript, otherwise undo; After cancel button triggers.Judge whether global variable cancellation script tmpcancelScript is empty, then do not carry out global variable cancellation script tmpcancelScript for sky, otherwise undo.
Example code:
Figure BDA00003020048800062
1), in the above-mentioned example code, function PopSure has realized hiding after the click ACK button dialog box and has carried out and has been buffered in the page and puts the right shoe on the right foot this really, and function PopCancel hides dialog box and carries out the cancellation script that is buffered in the page after having realized clicking cancel button.
Specific embodiment 2:
As Figure 10, realize the imitating shell web page dialog box with the inventive method:
A), use javaScript to call imitating shell frame function, and import dialog box parameters u rl into, width, height, ctl, wherein:
Url: the web page address parameter of opening;
Width: dialog box width parameter;
Height: dialog box height parameter;
Ctl: the value of returning transmits control, if this Xiang Buwei sky, indirect assignment can utilize this and text control to cooperate to this control when dialog box is closed, and simulates various effect.
Example code:
Figure BDA00003020048800071
B), forbidding Webpage scroll bar, and the Webpage back gauge is set is 0.
By the setting of this step, just can accomplish really full frame.
Example code:<body style=" margin:0px; Overflow:hidden; "
C), insert the Iframe of (width 100%, height 100%) all over the screen on Webpage (the top page---just embed the homepage of Frameset) top.
The purpose of using Iframe to cover is because the combobox control of some browsers can't be covered by other any elements except Iframe.
Example code:
<iframe?id="frmMessage"frameborder="0"scrolling="no"style="position:abs-olute;z-index:3;width:100%;height:100%;filter:alpha(opacity=0);left:0px;top:0px;"></iframe>
D), insert the div layer of a grey transparency 50% all over the screen on the Webpage top.
The purpose of using this layer is for outstanding covering effect, allows the people understand that at a glance gray area is can not operating area.
<div?id="dvMessageFilter"style="width:100%;height:100%;position:absolut?e;z-index:4;left:0px;top:0px;background-color:#000000;filter:alpha(opacity=50);-mo?z-opacity:0.50;opacity:0.50;"></div>
E), insert a table all over the screen on the Webpage top, be used as the container of placing dialog box.
Attribute placed in the middle with placed in the middle up and down about it is set, and it mainly acts on is to guarantee that source body can be fixed in the centre of forms.
<table?id="tbMessageContainer"style="width:100%;height:100%;position:ab-solute;z-index:5;left:0px;top:0px;"><tr><td?style="vertical-align:middle;text-align:center;">
F), insert a corresponding width according to dialog box width parameter width and dialog box height parameter height.The iframe of height, and its address is pointed to the value of the web page address parameters u rl that opens;
G), when the forms of newly opening are closed, call the function C losePopIframe (retValue that comprises instruction character string and action script of parent form, retScript) make and self close, and pass instruction character string retValue assignment back and transmit control ctl for back value, parent form is carried out action script retScript simultaneously, realized closing and carrying out script again when forms, reached blocking-up script effect.
Example code:
Figure BDA00003020048800081
The contrast original system carries function, when being opened close, calls window.close () event, passes the parameter of a returnValue back and gives parent page.And during close of the present invention, (returnValue retScript), realizes similar return value operation and simulated blocked script to call the function C losePopIframe of parent page.
The above only is embodiments of the invention; be not so limit claim of the present invention; every equivalent structure or equivalent flow process conversion that utilizes instructions of the present invention and accompanying drawing content to do; or directly or indirectly be used in other relevant technical fields, all in like manner be included in the scope of patent protection of the present invention.

Claims (4)

1. simulation browser session frame method based on Frameset, it is characterized in that: it comprises step,
A), use javaScript calls imitating shell frame function, and imports the dialog box parameter into;
B), insert an Iframe all over the screen on the Webpage top;
C), insert the div layer of a grey transparency 50% all over the screen on the Webpage top;
D), insert a table all over the screen on the Webpage top, be used as the container of placing dialog box;
E), in container, put into imitating shell frame function.
2. the simulation browser session frame method based on Frameset as claimed in claim 1 is characterized in that: the dialog box parameter of importing in the described steps A comprise dialog box topic parameter, dialog box message content parameter, dialog box topic front icon parameter, dialog box width parameter, determine script, cancellation script, confirming button text parameter and cancel button text parameter;
Described step D specifically comprises step,
D1), the table that inserts corresponding width according to the dialog box width parameter in container is as the message box main body, at the row of this table insertion as header area, message area, button area;
D2), in the row of header area, insert icon according to the icon parameter of dialog box topic front, insert caption text according to the dialog box topic parameter;
In the row of message area, put into content according to dialog box message content parameter;
Judge the cancellation script that imports into, if sky then shields cancel button, in the row of button area, according to confirming button text parameter and cancel button text parameter confirming button and cancel button are set;
D3), will determine that script deposits global variable in and determines in the script, the cancellation script deposits in the global variable cancellation script, waits for the triggering of confirming button or cancel button;
D4), after confirming button triggers, judge global variable determines whether script is empty, be not that sky is then carried out global variable and determined script, otherwise undo; After cancel button triggers, judge whether global variable cancellation script is empty, then do not carry out global variable cancellation script for sky, otherwise undo.
3. the simulation browser session frame method based on Frameset as claimed in claim 1 is characterized in that: the dialog box parameter of importing in the described steps A comprises that web page address parameter, dialog box width parameter, the dialog box height parameter opened reach back value and transmit control;
Described step D specifically comprises step,
D1), insert a corresponding width according to dialog box width parameter and dialog box height parameter, the iframe of height, and its address is pointed to the value of the web page address parameter of opening;
D2), when the forms of newly opening are closed, the function that comprises instruction character string and action script that calls parent form makes self closes, and passes the instruction character string assignment back and transmit control for back value, parent form is carried out action script simultaneously.
4. as any described simulation browser session frame method based on Frameset of claim 1-3, it is characterized in that: also comprise forbidding Webpage scroll bar before the described step B, and the Webpage back gauge is set is 0 step.
CN2013101186323A 2013-04-08 2013-04-08 Frameset-based browser dialog box simulation method Pending CN103235737A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2013101186323A CN103235737A (en) 2013-04-08 2013-04-08 Frameset-based browser dialog box simulation method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2013101186323A CN103235737A (en) 2013-04-08 2013-04-08 Frameset-based browser dialog box simulation method

Publications (1)

Publication Number Publication Date
CN103235737A true CN103235737A (en) 2013-08-07

Family

ID=48883782

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2013101186323A Pending CN103235737A (en) 2013-04-08 2013-04-08 Frameset-based browser dialog box simulation method

Country Status (1)

Country Link
CN (1) CN103235737A (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106201511A (en) * 2016-07-08 2016-12-07 东软集团股份有限公司 Create the method and device of modal dialog box
CN107506124A (en) * 2017-08-29 2017-12-22 武汉斗鱼网络科技有限公司 Video making friends method and system
CN107908793A (en) * 2017-12-13 2018-04-13 上海携程商务有限公司 The method and system of web page popup window
CN108780376A (en) * 2016-02-24 2018-11-09 微软技术许可有限责任公司 Clear message transmits
CN109117216A (en) * 2018-06-22 2019-01-01 北京明华联盟科技有限公司 Browser pop-up creation method, electronic equipment and storage medium
CN109669696A (en) * 2018-12-24 2019-04-23 成都四方伟业软件股份有限公司 Generation method, display methods and device, the readable storage medium storing program for executing of parallax webpage
CN111597491A (en) * 2020-07-24 2020-08-28 飞天诚信科技股份有限公司 Method and device for realizing browser pop-up frame

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102012820A (en) * 2010-12-07 2011-04-13 福州锐达数码科技有限公司 Method for realizing virtual page in Windows operating system
US20110156137A1 (en) * 2009-12-25 2011-06-30 Fuji Electric Systems Co., Ltd. Trench gate semiconductor device and the method of manufacturing the same
CN102194003A (en) * 2011-05-26 2011-09-21 重庆猪八戒网络有限公司 Web page popup window method and device
CN102830971A (en) * 2012-08-06 2012-12-19 优视科技有限公司 Method and device for rewriting browser pop-up box by external application program

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110156137A1 (en) * 2009-12-25 2011-06-30 Fuji Electric Systems Co., Ltd. Trench gate semiconductor device and the method of manufacturing the same
CN102012820A (en) * 2010-12-07 2011-04-13 福州锐达数码科技有限公司 Method for realizing virtual page in Windows operating system
CN102194003A (en) * 2011-05-26 2011-09-21 重庆猪八戒网络有限公司 Web page popup window method and device
CN102830971A (en) * 2012-08-06 2012-12-19 优视科技有限公司 Method and device for rewriting browser pop-up box by external application program

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
黄方荣: "未来的Web重要交互模式-对话框", 《程序员》, no. 12, 31 December 2006 (2006-12-31) *

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108780376A (en) * 2016-02-24 2018-11-09 微软技术许可有限责任公司 Clear message transmits
CN106201511A (en) * 2016-07-08 2016-12-07 东软集团股份有限公司 Create the method and device of modal dialog box
CN106201511B (en) * 2016-07-08 2019-10-08 东软集团股份有限公司 Create the method and device of modal dialog box
CN107506124A (en) * 2017-08-29 2017-12-22 武汉斗鱼网络科技有限公司 Video making friends method and system
CN107506124B (en) * 2017-08-29 2019-09-10 武汉斗鱼网络科技有限公司 Video making friends method and system
CN107908793A (en) * 2017-12-13 2018-04-13 上海携程商务有限公司 The method and system of web page popup window
CN109117216A (en) * 2018-06-22 2019-01-01 北京明华联盟科技有限公司 Browser pop-up creation method, electronic equipment and storage medium
CN109669696A (en) * 2018-12-24 2019-04-23 成都四方伟业软件股份有限公司 Generation method, display methods and device, the readable storage medium storing program for executing of parallax webpage
CN111597491A (en) * 2020-07-24 2020-08-28 飞天诚信科技股份有限公司 Method and device for realizing browser pop-up frame
CN111597491B (en) * 2020-07-24 2020-10-27 飞天诚信科技股份有限公司 Method and device for realizing browser pop-up frame

Similar Documents

Publication Publication Date Title
CN103235737A (en) Frameset-based browser dialog box simulation method
US8387006B1 (en) System and method for authoring a web page to be run-time editable
US9081463B2 (en) Systems and methods for run-time editing of a web page
CN103383645B (en) Code generating method and system
CN102915328B (en) Method and the RichText Edition device of editor&#39;s rich text
CN103853712A (en) Display method of floating layer window and browser
CN102214098A (en) Dynamic webpage data acquisition method based on WebKit browser engine
CN101446938A (en) Method for generating table and processing device thereof
CN105260170B (en) A kind of accident deducing manoeuver method and system based on case
CN103970750A (en) Method and device for generating HTML (Hypertext Markup Language) web pages
TW201037530A (en) Method for displaying a plugin frame in a web browser, computer readable medium, and computer program product
CN103593414A (en) Showing method and device of webpages in browser
CN106202013B (en) A kind of implementation method of webpage version EXCEL
CN107908793A (en) The method and system of web page popup window
CN103412857A (en) System and method for realizing Chinese-English translation of webpage
CN103942202B (en) Web page text domain height adaptive Zoom method and device
CN104268282A (en) Web banner advertisement displaying method and system
CN111783008A (en) Information display method, device, equipment and medium
CN115982266A (en) Page dynamic rendering method and system based on custom configuration attribute field
CN103064677A (en) Method and device for managing WEB multi-document child window
CN107644034A (en) Dynamic Display based on DOM tree structure clicks on the method, apparatus and system of figure
Mangiatordi et al. Farfalla project: browser-based accessibility solutions
CN109086040A (en) A kind of method and system quickly generating html code
CN105739962B (en) Table cell editing machine control extended method based on HTML and system
CN107239405A (en) A kind of automated testing method based on many browser kernels of Android

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into 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: 20130807