MyBB.de Forum
Erstellen eines Offtopic Button - Druckversion

+- MyBB.de Forum (https://www.mybb.de/forum)
+-- Forum: Anpassungen (https://www.mybb.de/forum/forum-47.html)
+--- Forum: Theme-Diskussionen (https://www.mybb.de/forum/forum-84.html)
+--- Thema: Erstellen eines Offtopic Button (/thread-10223.html)



Erstellen eines Offtopic Button - Laello - 06.08.2008

Ich würde gerne ein O.T. Button erstellen,
das dient in den Threads zur besseren Übersicht.
Zwar sollen keine o.t. Gespräche geführt werden,
aber es passiert doch hin und wieder.

Ich hab es auch schon mal in einem anderem Forum gesehen.
Das Funktioniert so ähnlich wie die Zitate funktion,
nur das anstatt Zitet O.T stehet.

Wäre sowas möglich, so das man sich das auch im CSS anpassen kann,
und von den Zitaten her abgrenzen kann, also optisch?


RE: Erstellen eines Offtopic Button - Michael - 06.08.2008

Im Grund kannst du einen eigenen MyCode im Admin-CP definieren und die Ausgabe dann per CSS formatieren. Wie du einen eigenen MyCode erstellen kannst, steht in der Doku.


RE: Erstellen eines Offtopic Button - Laello - 06.08.2008

Ok, das hab ich gemacht .

Zitat:Einen eigenen mycode erstellt:

MyCode-Titel = Offtopic

MyCode-Beschreibung = Offtopic

Regulärer Ausdruck = \[offtopic\](.*?)\[/offtopic\]

Ersetzung = ?(feld leer gelassen)

MyCode aktivieren?= Ja


Unter CSS dann
das hier

Zitat:.offtopic_header {
width: 600px;
margin-left: 10px;
margin-right: 50px;
padding: 4px 4px 4px 4px;
border-top: 2px solid #8686fe;
border-left: 2px solid #8686fe;
border-right: 2px solid #8686fe;
border-bottom: 2px solid #8686fe;
color: #fff;
background: #8686fe;
font-size: 10px;
}

.offtopic_body {
width: 600px;
margin-left: 10px;
margin-right: 50px;
padding: 8px 4px 4px 4px;
border-bottom: 2px solid #8686fe;
border-left: 2px solid #8686fe;
border-right: 2px solid #8686fe;
color: #000000;
background-color: #9999ff;
font-style: italic;
}

Aber es hat nicht geklapptt?


RE: Erstellen eines Offtopic Button - StefanT - 06.08.2008

Probiere:
Zitat:Einen eigenen mycode erstellt:

MyCode-Titel = Offtopic

MyCode-Beschreibung = Offtopic

Regulärer Ausdruck = \[offtopic\](.*?)\[/offtopic\]

Ersetzung = <div class="offtopic">$1</div>

MyCode aktivieren?= Ja


Unter CSS dann
das hier

Zitat:.offtopic {
width: 600px;
margin-left: 10px;
margin-right: 50px;
padding: 8px 4px 4px 4px;
border-bottom: 2px solid #8686fe;
border-left: 2px solid #8686fe;
border-right: 2px solid #8686fe;
color: #000000;
background-color: #9999ff;
font-style: italic;
}



RE: Erstellen eines Offtopic Button - Laello - 06.08.2008

Super, es hat geklappt,
nur das ich ein noch header haben möchte, wie bei der quote funktion,
das man weiß das ist kein Zitat sondern OT.

Geb ich das auch in der CSS ein?


RE: Erstellen eines Offtopic Button - Michael - 06.08.2008

Du musst die Ersetzung entsprechend ändern, z.B.
Code:
<div class="offtopic"><strong>Offtopic:</strong><br />$1</div>



RE: Erstellen eines Offtopic Button - Laello - 07.08.2008

Dankeschön hat geklappt