Zum Inhalt springen

Menü transparenz....

Erstellt am 21. Juli 2003 · 6 Antworten · letzte Antwort am 28. Juli 2003

Tags: Frage

Marcus ·

Hallo,

habe 2 Menüs, die auf einem Hintergrundbild liegen.
Nun kann ich die Hintergrundfarbe der Menüs einstellen, sie sollen aber transparent sein, so dass die Bilder dahinter sichbar sind.
Kann mir da jemand helfen?? Hier mal der Code:

# Menü Level 1 
############# 

  marks.INHALT = TEXT 
  marks.INHALT < styles.content.get 
  marks.MENUE_TOP = HMENU 
  marks.MENUE_TOP.minItems = 0 
  marks.MENUE_TOP.maxItems = 8 
  marks.MENUE_TOP.1 = GMENU 
  marks.MENUE_TOP.1 { 
    NO { 
      backColor = #000000   
      XY = [10.w]+30,20 
      10 = TEXT 
      10.text.field = title 
      10.fontFile = fileadmin/trebuc.ttf 
      10.fontColor = #EEF6FF   
      10.fontSize = 8 
      10.offset = 15,15 
      10.niceText = 1 
      } 

    RO < .NO 
    RO = 1 
    RO.10.fontColor = #accbee   

    ACT < .NO 
    ACT = 1 
    ACT.backColor = #000000 
    ACT.10.fontColor = #accbee position in Top-Menu

  }
Marc ·

füg mal nach deinem
backColor = #000000

folgendes ein:
transparentColor= #000000

wenn du keine pixelschrift nimmst und niceText und antiAlias nicht
abstellst, wird das aber bescheiden aussehen...

Marc 😉

Marc ·

hmmm

ein codeschnipsel

NO {
    XY = 75, 15
    backColor=blue
    transparentColor=blue

    5 = IMAGE
    5.file = fileadmin/template/menu/menu_level2_backno.gif


    10 = TEXT
    10.text.field = title
    10.text.case = upper
    10.offset = 4,7
    10.niceText = 0
    10.antiAlias=0
    10.fontFile = fileadmin/template/fonts/stan0753.ttf
    10.fontSize = 8
    10.fontColor=black
}

poste auf jedenfall deine lösung (wenn du sie findest #giggle# )
interessiert mich brennend... zur vorbeugung

Marc

Marcus ·

Ich habe keine Ahnung, es funzt einfach nicht :-(

poste auf jedenfall deine lösung (wenn du sie findest )

sehr lustig!!

typoworxx ·

Hi,
lege um das ganze menü ein <DIV> mit einer eigenen ID (siehe Dein ertweitertes TS weiter unten). Für diese ID erstellst Du den entsprechenden Stylesheet der folgerndermaßen aussehen könnte:

#transparentes-menue{
background-color: #009000;
border-color: black;
border: 1px solid;
padding-left: 5px;
padding-bottom: 3px;
float:left;
width:150px;
filter: Alpha(opacity=100, finishopacity=70, style=1);
}

Den Stylesheet kannst (solltest) Du in einer externen Datei legern und importieren. Entscheidend ist die letzte Zeile im Style. So funktioniert es aber nur im IE. Ich habe gehört, für den Mozilla... und Opera gibt es auch ein Möglichkeit DIV's transparent zu machen, habe ich aber noch nicht ausprobiert.
Ein Beispiel findest Du unter:

www.testixx.de
user:demo
pass:demo

Gruß Jörg

# Menü Level 1
#############

marks.INHALT = TEXT
marks.INHALT < styles.content.get
marks.MENUE_TOP = HMENU
marks.MENUE_TOP.minItems = 0
marks.MENUE_TOP.maxItems = 8
marks.MENUE_TOP.1 = GMENU
marks.MENUE_TOP.1 {
wrap=<DIV ID="transparentes-menue">|</DIV>
NO {
backColor = #000000
XY = [10.w]+30,20
10 = TEXT
10.text.field = title
10.fontFile = fileadmin/trebuc.ttf
10.fontColor = #EEF6FF
10.fontSize = 8
10.offset = 15,15
10.niceText = 1
}

RO < .NO
RO = 1
RO.10.fontColor = #accbee

ACT < .NO
ACT = 1
ACT.backColor = #000000
ACT.10.fontColor = #accbee position in Top-Menu

}