Recently I made a simple touch screen program. I wanted to open the window directly with IE on the client, and I didn't want to develop anything on the client any more. I tried to block all the excess ie stuff. The Code is as follows:
<Script language =/"javascript/">
Window. Opener = NULL; window. Close ();
Self. Close ();
Newwin = Window. open ('"+ URL +"', '"+ target +"', 'top =-5, toolbar = 0, location = 0, directories = 0, menubar = 0, scrollbars = 0, resizable = 0, status = 0, copyhistory = 0, fullscreen = 1 ');
Newwin. moveTo (-6,-30); // move the block ie bar
Newwin. resizeTo (screen. availwidth, screen. availheight); // move to full screen
Newwin. outerwidth = screen. availwidth; newwin. outerheight = screen. availheight;
</SCRIPT>
On the touch screen, it is best to completely block the scrollbar:
Add: Style = "OVERFLOW-Y: hidden; OVERFLOW-X: hidden; cursor: Hand" to the body.
For IFRAME, frameborder = "0" scrolling = "no"
Check IFRAME in the page, change SRC, and display different pages. The effect is very good. All scrollbars are blocked. What should I do with the rollback frequency?
The following code can solve the problem.
VaR currentpos, timer;
VaR direct, move;
Function initialize (Dir, m)
{Direct = dir; move = m; timer = setinterval ('scrollwindow () ', 100 );}
Function SC ()
{Clearinterval (timer );}
Function scrollwindow ()
{Currentpos=iframe.doc ument. Body. scrolltop;
If (direct = "up ")
{Iframe.document.body.scrolltop=iframe.doc ument. Body. scrolltop-move ;}
Else
{Iframe.document.body.scrolltop=iframe.doc ument. Body. scrolltop + move ;}
}
The above code passes the test on IE 6