开发者

UL - LI Bullets as Image an right side next to the text

开发者 https://www.devze.com 2023-02-10 06:19 出处:网络
i have some problems with styling an UL as navigation bar (sorry for this question, but iam a developer, not designer..)

i have some problems with styling an UL as navigation bar (sorry for this question, but iam a developer, not designer..)

The Problem occours in Safari on Mac (FF is working fine) See first picture (FF)

UL - LI Bullets as Image an right side next to the text

UL - LI Bullets as Image an right side next to the text

Css:

.multiPoint {
    list-style-image:url(../images/punkte.jpg); }

.directionRight{
    direction:rtl;
    padding-right:3em;
    margin-right:0.5em;
}

#navigation {
    text-align: left;
}

HTML:

<div id="navigation" class="span-6 directionRight">
    <ul>
    <li class="multiPoint">Sie</li开发者_开发知识库>
    </ul>
</div>


If the bullet image is directional (like in the example above), the rtl approach may have the unintended side-effect that the image is mirrored in some browsers, resulting in an arrow pointing from right to left instead of left to right.

A background image does not show this behavior in IE9 and it maintains the correct orientation.

list-style: none;
background: url(images/bullet.gif) no-repeat center right;  
padding-right: 10px;


Try updating your multiPoint class style as follows:

.multiPoint {
   list-style-image:url(../images/punkte.jpg);
   list-style-position: inside;
}

That will tell the browser to position your bullet images inside the list instead of outside.

0

精彩评论

暂无评论...
验证码 换一张
取 消