0 Пользователей и 1 Гость просматривают эту тему.
  • 10 Ответов
  • 3465 Просмотров
*

baga_128

  • Захожу иногда
  • 53
  • 0 / 0
доброго времении суоток. Помогите разобраться, мне нужно настроить цвет ссылки при входе в раздел (active). Сам разобраться не могу.
Вот ксс:
Код
.dir {direction:ltr;}
body {direction:ltr;}
td, tr, p, div {
  font-family      : tahoma;
  font-size        : 11px;
  color            : #333333;
}

hr {
  background       : #CCCCCC;
  height           : 1px;
  width            : 100%;
}
.boxes {
        border: solid;
        border: dotted;
        border-width: 1px;
        border-bottom-color: #B0C4DE;
        border-top-color: #B0C4DE;
        border-left-color: #B0C4DE;
        border-left-color: #B0C4DE;
}
a {
font-weight:bold;
color:#666666;
}
.title {
font-family: tahoma;
font-size: 11px;
font-weight: bold;
color   : #4490B4;
}
.title-red {
font-family: tahoma;
background-image:url(../images/alert.png);
background-position:left;
background-repeat:no-repeat;
height:26px;
font-size: 11px;
font-weight: bold;
color:#FF0000;
padding-top:7px;
padding-left:25px;
}
.heading {
font-family: Tahoma;
font-size: 11px;
font-weight: bold;
color            : #4490B4;
background-color:#EAEAFF;
}
.name {
font-family: Tahoma;
font-size: 11px;
font-weight: bold;
color            : #4490B4;
background-color:#EAEAFF;
}
.pathway {
  font-family: tahoma;
  font-size: 11px;
  color: #666666;
}

a.pathway:link, a.pathway:visited {
  color            : #ffffff;
  font-weight      : normal;
}

a.pathway:hover {
  color            : #ffffff;
  font-weight      : normal;
  text-decoration  : underline;
}

/* --Default Class Settings-- */

a.mainlevel:link, a.mainlevel:visited {
        color: #ffffff;
display:block;
        text-align: left;
        font-weight: bold;
background-image:url(../images/key.png);
        background-position: right;
background-repeat:no-repeat;
height:39px;
padding-top:14px;
padding-left:44px;
margin-right:-px;
width:169px;
 }




/* Start Sub Level For Menu*/
#menu1_img img {
display:block;
position:absolute;
margin-left:40px;
}

a.sublevel1:link, a.sublevel1:visited {
        color: #333333;
        background-position: left;
        text-align: left;
        font-weight: bold;
background-image:url(../images/sub1.png);
background-repeat:no-repeat;
height:33px;
padding-top:8px;
padding-left:28px;
width:160px;

 }

a.sublevel1:hover {
        color: #4490B4;
        background-position: left;
background-image:url(../images/sub1.png);
        text-align: left;
        }
a.sublevel2:link, a.sublevel2:visited {
        color: #333333;
        background-position: left;
        text-align: left;
        font-weight: bold;
background-image:url(../images/sub2.png);
background-repeat:no-repeat;
height:33px;
padding-top:8px;
padding-left:42px;
width:160px;

 }

a.sublevel2:hover {
        color: #4490B4;
        background-position: left;
background-image:url(../images/sub2.png);
        text-align: left;
        }
a.sublevel3:link, a.sublevel3:visited {
        color: #333333;
        background-position: left;
        text-align: left;
        font-weight: bold;
background-image:url(../images/sub3.png);
background-repeat:no-repeat;
height:33px;
padding-top:8px;
padding-left:58px;
width:160px;

 }

a.sublevel3:hover {
        color: #4490B4;
        background-position: left;
background-image:url(../images/sub3.png);
        text-align: left;
        }
a.sublevel4:link, a.sublevel4:visited {
        color: #333333;
        background-position: left;
        text-align: left;
        font-weight: bold;
background-image:url(../images/sub4.png);
background-repeat:no-repeat;
height:33px;
padding-top:8px;
padding-left:68px;
width:160px;

 }

a.sublevel4:hover {
        color: #4490B4;
        background-position: left;
background-image:url(../images/sub4.png);
        text-align: left;
        }
a.sublevel5:link, a.sublevel5:visited {
        color: #333333;
        background-position: left;
        text-align: left;
        font-weight: bold;
background-image:url(../images/sub5.png);
background-repeat:no-repeat;
height:33px;
padding-top:8px;
padding-left:78px;
width:160px;

 }

a.sublevel5:hover {
        color: #4490B4;
        background-position: left;
background-image:url(../images/sub5.png);
        text-align: left;
        }
/* End Sub Level For Menu*/
a.mainmenu:hover, {
        color: #4490B4; text-decoration: underline;

        }
a.mainmenu:link, a.mainmenu:visited {
        color: #ffffff; font-family: tahoma;
        font-weight: bold;

        }

a.sublevel:hover {
        text-decoration: underline;
        }

a.sublevel:link, a.sublevel:visited {
        display:block;
        color: #ffffff;
        padding-left:53px;
        padding-right:5px;
background-image:url(../images/2.png);
        font-family: tahoma;
        font-weight: normal;
        margin-left:-4px;

}
a.sublevel:active {
        color: #ffffff;
}



table.moduletable {
        width: 169px;

background-image:url(../images/bot_mod.png);
background-repeat:no-repeat;
background-position:bottom;
padding-bottom:20px;
padding-left:8px;
padding-right:0px;


        }

table.moduletable th {
  width: 169px;
  height:13px;
  font-size        : 11px;
  display :block;
  font-weight      : bold;
  color            : #FFFFFF;
  text-align       : center;
  background-image:url(../images/top_mod.png);
  background-repeat:no-repeat;
  background-position:top;


}

table.moduletable_mainmenu {
        width: 169px;
        height:48px;
background-image:url(../images/bot_mod2.png);
background-repeat:no-repeat;
background-position:left;
padding-bottom:0px;
padding-left:-5px;
padding-right:3px;
        margin-right:-3px;

        }

table.moduletable_mainmenu th {
  width: 169px;
  font-size        : 1px;
  display :block;
  font-weight      : bold;
  color            : #375589;
  text-align       : center;
  background-image:url(../images/top_main.png);
  background-repeat:no-repeat;
  background-position:left;
  height:2px;
}

td.moduletable {
        font-weight: normal;
background-color:#00FF00;
        }
table.moduletable td {
        font-size: 11px;
        font-weight: normal;
        }

.poll {
  font-family      : tahoma;
  font-size        : 11px;
  color            : #666666;
  text-align       : center;
  line-height      : 12px;

}


.sectiontableheader {

  color            : #4490B4;
  background-color:#F4F4F4;
  font-weight      : bold;
}

.sectiontablefooter {

  color            : #4490B4;
  background-color:#F4F4F4;
}
.sectiontableentry1 {
background-color:#F9F9FF;
}

.sectiontableentry2 {
background-color:#ECECFF;

}


.small {
  font-family      : tahoma;
  font-size        : 11px;
  color            : #3366C0;
  text-decoration  : none;
  font-weight      : medium;
}

.smalldark {
  font-family      : tahoma;
  font-size        : 11px;
  color            : #666666;
  text-decoration  : none;
  font-weight      : normal;
}


.contentpane {
font-weight: normal;


}

.contentpaneopen {
font-weight: normal;
font-size:11px;
margin-top:4px;
}

.contentheading {
  font-family      : tahoma;
  font-size        : 11px;
  font-weight      : bold;
  color            : #4490B4;
  text-align       : left;
  padding-bottom:5px;
  margin-top:10px;

}
.componentheading {
  font-family      : tahoma;
  font-size        : 11px;
  font-weight      : bold;
  color            : #4490B4;
  text-align       : left;
  padding-bottom:5px;
  margin-top:10px;
}
.createdate {
  font-family      : tahoma;
  font-size        : 11px;
  color            : #999999;
  text-align       : left;
}


.button {
  font-family      : tahoma;
  font-style       : normal;
  font-size        : 11px;
  font-weight      : bold;
  background-color : #ffffff;
  color            : #666666;
  border           : 1px solid #CCCCCC;
  margin-top:3px;
  width:90px;
}
.button2 {
  font-family      : tahoma;
  font-style       : normal;
  font-size        : 11px;
  font-weight      : bold;
  background-color : #ffffff;
  color            : #666666;
  width:85px;
  height:25px;
  border           : 1px solid #CCCCCC;
}

.inputbox {
BORDER-RIGHT: 1px solid #CCCCCC;
BORDER-TOP: 1px solid #CCCCCC;
FONT-SIZE: 8pt;
BORDER-LEFT: 1px solid #CCCCCC;
BORDER-BOTTOM: 1px solid #CCCCCC;
FONT-FAMILY: Tahoma;
}
.inputbox2 {
BORDER-RIGHT: 1px solid #CCCCCC;
BORDER-TOP: 1px solid #CCCCCC;
FONT-SIZE: 8pt;
BORDER-LEFT: 1px solid #CCCCCC;
BORDER-BOTTOM: 1px solid #CCCCCC;
FONT-FAMILY: Tahoma;
width:135px;
}

.inputbox-nav {
BORDER-RIGHT: 1px solid #CCCCCC;
BORDER-TOP: 1px solid #CCCCCC;
FONT-SIZE: 10pt;
BORDER-LEFT: 1px solid #CCCCCC;
BORDER-BOTTOM: 1px solid #CCCCCC;
FONT-FAMILY: Tahoma;
width:180px;

}

a:link, a:visited {
  font-size        : 11px;
  color            : #666666;
  text-decoration  : none;
  font-family      : tahoma;
}

a:hover {
  color            : #4490B4;
  text-decoration  : none;
}

/* For content item titles that are hyperlink instead of Read On */
a.contentpagetitle:link, a.contentpagetitle:visited {
font-family: Tahoma;
font-size: 11px;
font-weight: bold;
  color: #666666;
padding-left:9px;
background-image:url(../images/arrow.png);
background-repeat:no-repeat;
background-position:left;
line-height:140%;
}

a.contentpagetitle:hover {
font-family: Tahoma;
font-size: 11px;
font-weight: bold;
text-align:left;
color: #4490B4;
text-decoration:blink;
font-weight: bold;
padding-left:7px;

}

a.category:link, a.category:visited {
  color            : #333333;
  font-weight      : bold;
  width:100%;
  background-color:#E3FECB;
}

a.category:hover {
  color            : #4490B4;
}

/* Styles for dhtml tabbed-pages */
.ontab {
background-color: #ffae00;
border-left: outset 2px #ff9900;
border-left: outset 2px #808080;
border-top: outset 2px #ff9900;
border-bottom: solid 1px #d5d5d5;
text-align: center;
cursor: hand;
font-weight: bold;
color: #FFFFFF;
}
.offtab {
background-color : #e5e5e5;
border-left: outset 2px #E0E0E0;
border-left: outset 2px #E0E0E0;
border-top: outset 2px #E0E0E0;
border-bottom: solid 1px #d5d5d5;
text-align: center;
cursor: hand;
font-weight: normal;
}
.tabpadding {
}

.tabheading {
background-color: #ffae00;
text-align: left;
}

.pagetext {
visibility: hidden;
display: none;
position: relative;
top: 0;
}

/* for modifying {zancode} output.  Don't set the colour! */
.zancode {
background-color: #f0f0f0;
}

/* Text passed with zanmsg url parameter */
.message {
font-family : tahoma;
font-weight: bold;
font-size : 11px;
color : #ff6600;
text-align: center;
}
.latestnews-nav {
width:100%;
padding-left:5px;
color:#6693A1;
background-image:url(../images/arrow.png);
background-repeat:no-repeat;
background-position:left;
padding-left:10px;
line-height:190%;
}
ul#mainlevel-nav {
list-style : none;
padding : 0;
margin : 0;
text-align:center;
}

ul#mainlevel-nav li
{
float : left;
white-space : nowrap;
}
ul#mainlevel-nav li a:hover
{
color: #FFFFFF;
}

a.mainlevel-nav:link, a.mainlevel-nav:visited {
list-style : none;
color:#00FF00;
font-size:11px;
font-weight:bold;
padding-left:15px;
padding-right:25px;
height:100%;
line-height:29px!important;
}
table.moduletable-nav { width:100%;}
#active_menu{
color:#FF0000;
}
.highlight {
background-color:#FFCC00;
font-weight:bold;
}
.level_0 { padding-left:25px;
list-style-image:url(../images/arrow.png);
line-height:180%;
}
.level_1 { padding-left:35px;
}
.level_2 { padding-left:45px;
}
.level_3 { padding-left:55px;
}
.register{
width:137px;
background-image:url(../images/register.png);
background-repeat:no-repeat;
background-position:left;
height:29px;
text-align:center;
font-weight:bold;
padding-top:7px;
}
.forget{
width:137px;
background-image:url(../images/forget.png);
background-repeat:no-repeat;
background-position:left;
height:29px;
text-align:center;
font-weight:bold;
padding-top:7px;
}
.gallery-menu{
width:94px;
height:24px;
background-image:url(../images/gtitle.png);
text-align:center;
padding-top:4px;
}
table.directory {
   color: #000033;
   background-color: #F4F4F4;
}

.grayb {
   background-color: #f8f8f8;
}

table.directory td {
   font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
   font-size: 8pt;
   font-weight: normal;
}

table.directory th {
   font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
   font-size: 8pt;

   background-color: #F4F4F4;
color: #666666;
   font-weight:bold;
}
.directorypath {
   font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
   font-size: 8pt;
   font-weight: bold;

color: gray;
   background-color:#f2f2f2 ;

}
.smallgm {
   font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
   font-size: 7pt;
color: red;
}
.smallgsm {
   font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
   font-size: 7pt;
color: green;
}
a.subcat {font-weight:bold;
}
a.next {
width:94px;
height:24px;
background-image:url(../images/next.png);
text-align:center;
padding-top:4px;
}
a.last {
width:94px;
height:24px;
background-image:url(../images/last.png);
text-align:center;
padding-top:4px;
}
li {

line-height:180%;
}
ul {
padding-left:15px;
margin: 0 0 0 0;
}
.pagenav {
  text-align: center;
  font-size: 11px;
  font-weight: bold;
  border: 1px double #cccccc;
  width: auto;
  background: #ffffff;
  color: #666666;
  padding: 0px 10px;
  line-height: 2px;
  margin: 1px;


}
th.pagenav_prev,th.pagenav_next {
  text-align: center;
  font-size: 11px;
  font-weight: bold;
  border: 3px double #cccccc;
  width: auto;
  color: #666666;
  padding: 0px 10px;
  line-height: 20px;
  margin: 1px;
}
.pagenavbar {
margin-right: 10px;
float: right;
}
a.readon{
  text-align: center;
  font-size: 11px;
  font-weight: bold;
  border: 3px double #cccccc;
  width: auto;
  background: url(../images/button_bg.png) repeat-x;
  padding: 0px 10px;
  line-height: 20px;
  margin: 1px;
}
div.back_button{
  text-align: center;
  font-size: 11px;
  font-weight: bold;
  border: 3px double #cccccc;
  width: 110;
  background: url(../images/button_bg.png) repeat-x;
  padding: 0px 10px;
  line-height: 20px;
  margin: 1px;
}
form {
margin: 5 10 5 5!important;
margin: 0 0 0 0;
}
a.blogsection{
background-image:url(../images/arrow.png);
background-position:left;
background-repeat:no-repeat;
padding-left:10px;
}
div.blog_more{
background-color:#F7F7F7;
}
div.mosimage {
  border           : 1px solid #CCCCCC;
}
div.mosimage_caption {
  border-top: 1px solid #CCCCCC;
  background-color:#EAEAEA;
}
   a img
{
border: 0px;
}
« Последнее редактирование: 09.06.2009, 13:26:33 от poizon »
*

poizon

  • Захожу иногда
  • 495
  • 187 / 1
  • Buu
откройте исходный код и посмотрите какой класс присвается активному разделу
*

baga_128

  • Захожу иногда
  • 53
  • 0 / 0
а где конкретно?
*

Kostelano

  • Давно я тут
  • 525
  • 51 / 1
Дай ссылку на сайт
*

baga_128

  • Захожу иногда
  • 53
  • 0 / 0
*

poizon

  • Захожу иногда
  • 495
  • 187 / 1
  • Buu
Код
<a href="http://olmar.ru/index.php?option=com_frontpage&amp;Itemid=1" class="mainlevel" id="active_menu">ГЛАВНАЯ</a>

PS верстка кривая до ужаса.
*

Kostelano

  • Давно я тут
  • 525
  • 51 / 1
Та да, такого пока не видел -) Ну вот тебе исходный код, отыщи соответствующие классы в таблице стилей твоего шаблона, код которого ты привел в своем первом посте, сделай отступы...

Код
<tr><td>

<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr align="left"><td><a href="http://olmar.ru/index.php?option=com_frontpage&amp;Itemid=1" class="mainlevel" id="active_menu">ГЛАВНАЯ</a></td></tr>
<tr align="left"><td><a href="http://olmar.ru/index.php?option=com_content&amp;task=section&amp;id=4&amp;Itemid=30" class="mainlevel" >О КОМПАНИИ</a></td></tr>
<tr align="left"><td><a href="http://olmar.ru/index.php?option=com_content&amp;task=section&amp;id=5&amp;Itemid=36" class="mainlevel" >УСЛУГИ И РЕШЕНИЯ</a></td></tr>
<tr align="left"><td><a href="http://olmar.ru/index.php?option=com_content&amp;task=section&amp;id=8&amp;Itemid=53" class="mainlevel" >ПРАЙС</a></td></tr>
<tr align="left"><td><a href="http://olmar.ru/index.php?option=com_content&amp;task=section&amp;id=9&amp;Itemid=57" class="mainlevel" >КЛИЕНТАМ</a></td></tr>
<tr align="left"><td><a href="http://olmar.ru/index.php?option=com_contact&amp;Itemid=3" class="mainlevel" >КОНТАКТЫ</a>

</td></tr>

А воообще увет не очень. Кстати, пользуйся внешними расширениями, та же обратная связь или контакты - компонент QContacts 1.0.5a, он повеселей будет и т.д...

[вложение удалено Администратором]
*

baga_128

  • Захожу иногда
  • 53
  • 0 / 0
Что то я ни чено не понял :(
*

baga_128

  • Захожу иногда
  • 53
  • 0 / 0
аааа т.е мне нужно смотреть класс mainlevel?
*

poizon

  • Захожу иногда
  • 495
  • 187 / 1
  • Buu
вроде id переводится как "активное меню" (active_menu), чего непонятного то?
*

baga_128

  • Захожу иногда
  • 53
  • 0 / 0
Re: Цвет ссылки при входе в раздел (active).
« Ответ #10 : 09.06.2009, 15:18:11 »
Спасибо огромноею, разобрался.
Чтобы оставить сообщение,
Вам необходимо Войти или Зарегистрироваться