-track-color:color; Set or retrieve the drag area color of a scroll barNote:color code you want to set, can be 16 binary, such as #ff0000, can be expressed in RGB, for example, RGB (255,0,255), when you set the scroll bar style, you do not have to use all the properties to take effect.(4) page element positioning in JavaScriptClientX, ClientY is the current posit
In the work you need to adjust the column width of the jqgrid, but do not want to have a horizontal scroll bar, because it is a fixed column width, when the display area is reduced, the data will appear vertical scroll barAt this point, you need to determine whether the vertical scroll bar has a column width adjustment.Self-investigation, found that the
I wrote a lot of plug-ins, but are directly embedded in the project, never took out a separate package into a file, this is the first time, hope is a good start.A plugin that has long text and can scroll left and right1 DOCTYPE HTML>2 HTMLLang= "en">3 Head>4 MetaCharSet= "UTF-8">5 title>Documenttitle>6 Head>7 style>8 Div{9 width:200px;Ten Overflow:Hidden; One } A span{ - Display:Inline-block; -
DOCTYPE HTML>HTML> Head> MetaCharSet= "UTF-8"> title>title> Head> Body> Ponclick=getelementrect (This)>How are you doingP> Ponclick=getelementrect (This)>How are you doingP> Ponclick=getelementrect (This)>How are you doingP> TableBorder= "1"cellspacing=""cellpadding=""> TR>thonclick=getelementrect (This)>Headerth>TR> TR>TD>DataTD>TR>
1, small icon (. ico)/jb51.ico" type= "Image/x-icon"/>Note: The red part is the relative path of the picture2. Inserting music"Images/joy%20gruttmann%20-%20schnappi.mp3 " controls= "Controls"width=300 height=80 type=audio/mpeg loop= "-1" hidden= "Ture" autostart= "false" volume= "0"/> Note: The red part is the relative path of the music, whether the loop is AutoPlay, and whether hidden is hidden 3. Insert Video (written in in the following format: http://player.youku.com/player.php/sid/xmj
When the html page content exceeds the limit, the horizontal scroll bar is displayed.-lin Qiqi has encountered this problem several times and is skilled in solving it.
This problem usually occurs when the width of an internal element in html or page exceeds the upper limit.
Below are some situations I have encountered:
1. The width of an internal element
of the range, and then use the content area height divided by this percentage, the scroll bar for each move 1px content area relative scrolling distance.
Content area Scrolling distance = content Area Height/(scroll bar scrolling area/1)
Demo complete code is as follows:
Note: Because of the use of Seajs written, so a little attention to the loading of the
1. When you open a new page, you need to disable the mouse wheel, prevent page swipe;When you call the display layer, add this JS code: Document.documentElement.style.overflow = "hidden"; The time to close the layer don't forget to add this sentence: Document.documentElement.style.overflow = "";2. Set the original position of the scroll wheelvar top_temp = $ (document). ScrollTop () | |Document.documentElem
, it's simpler:
The code is as follows
Copy Code
This code has been tested in IE8, fully usable, and Firefox and Chrome are in effect, pretty good.
The following code defines the style of the scroll bar:
The
set to
When dragging a scroll bar, how much does the content area need to be moved for every 1px scroll bar to be moved?
The crowdsourced security testing shows that the distance of each 1PX area is a few percent of the mobile range of the scroll bar. Then, the percentage of the content area height divided by the obtained percentage is used to determine the re
configuration page
Next we will create a page configuration page, create a directory such as alljoke under the page Directory, create a allJoke. json under this directory, and copy the following code to this file:
{"NavigationBarTitleText": "Joke collection", "enablePullDownRefresh": true}
We need to use the onPullDownRefresh method provided by the applet for pull-down refresh, so enablePullDownRefresh must be enabled in the configuration item. Anoth
This article mainly introduces JavaScript code for simulating the simple scroll bar effect, which can simulate the scroll bar drag display effect. It involves JavaScript mouse event response and page element operation related skills, the demo source code is provided for readers to download. If you need it, you can refe
Collection",
"Enablepulldownrefresh": True
}
Because we're going to do a drop down refresh, we need to use the Onpulldownrefresh method provided by the applet, so you must open the Enablepulldownrefresh in the configuration item. Another option is the top of the page.
Wxml View Page
Good turn to view page, the same in the Alljoke directory to create a new Alljoke.wxml page. Wxml is a small program that creates a view page document type that is written like
I found a lot of questions on the internet and found that the answers were messy. In fact, in Asp.net, the page object has a property that enables the page to submit or update data, and then return to the original page location, including the scroll bar location, which can be saved.Copy the code as follows:Inherits = "Default. Default" %>Set the MaintainScrollPositionOnPostback attribute to true o
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.