How to solve Check Out Green Icon Position Problem on SharePoint 2010

/*

Author: Jiangong SUN

*/


Problem Description:

When I add one document in a list view and check out it. The green icon position is wrong the one page, but it's right in another page which is very strange.

All the css code (coreV4.css) is generated by sharepoint itself.

vs 

The icon's css class is ".ms-vb-icon-overlay". I've searched and searched and searched on internet... But there is no solution for this.

.ms-vb-icon-overlay {
    border: 0 none;
    bottom: -2px;
    left: -7px;
    position: relative;
}

Finally I've asked a collegue who is expert on css. And he pointed the source of problem in 2 minutes while I've spent 1 whole day. 

I've tried to use js code to correct the problem while my js code is always executed before the sharepoint scripts which stop me from correcting it. 

Even though I use "ExecuteOrDelayUntilScriptLoaded" method to try to execute my funtion after all sharepoint scripts execution.

In fact the problem is the  ".ms-vb-icon-overlay" class's parent width is limited to "0.01%" in whatever case. And I just need to modify the parent "width". And my problem is that I've went the wrong direction of the solution before.

And Finally I put the correction css code in my page directly because it won't be executed after sharepoint script if I don't do so.

.ms-vb-icon {padding: 4px 8px 0; vertical-align: top; width: 30px !important;}

I hope this post can do help in your sharepoint development, just in case. Enjoy coding!

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值