Home >Web Front-end >JS Tutorial >jquery paging plug-in jpaginate is incompatible with IE_jquery

jquery paging plug-in jpaginate is incompatible with IE_jquery

WBOY
WBOYOriginal
2016-05-16 16:51:321293browse

I downloaded a paging plug-in to use. The demo downloaded from the Internet is a little different in each IE version, but it can still be used.

But it cannot be displayed normally on my page. It may be caused by too many nested divs or positioning.

I changed the source code and it can display normally in ie7, ie8, and ie9. The following is part of the source code. I find it difficult to solve problems when using other people's things. The key is that ie.

Copy code The code is as follows:

var bVer = navigator.appVersion;
var ver ;
if(bVer.indexOf('MSIE 7.0') > 0){
ver = "ie7";
}

if(ver == 'ie7'){
_ulwrapdiv.css('width',outsidewidth 72 'px');
_divwrapright.css('left',outsidewidth_tmp 6 72 'px');
}
else{
_ulwrapdiv. css('width',outsidewidth 'px');
_divwrapright.css('left',outsidewidth_tmp 6 'px');
}


Modified code :
Copy code The code is as follows:

if(ver == 'ie7' || ver =='ie8' || ver=='ie9'){
_ulwrapdiv.css('width',outsidewidth 72 'px');
_ulwrapdiv.css('float','left');/ /This is the added code
_divwrapright.css('left',outsidewidth_tmp 6 72 'px');
}


Picture 1: Normal

Picture 2: In my environment

Picture 3: After adding if(ver == 'ie8'){} (my environment is ie8)

Figure 4: After adding _ulwrapdiv.css('float','left'); //After testing, it works in ie7, ie8, and ie9, but it is a little asymmetrical.
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn