Αλλαγή χρώματος σε style.ccs στην περιοχή code

Started by anoksidotos, February 23, 2010, 11:27:24 PM

Previous topic - Next topic

anoksidotos

Έχω το παρακάτω style.ccs
Επειδή έχω ψάξει αρκετές ώρες με δοκιμές και δεν κατάφερα τίποτα, μπορείτε να μου πείτε ποια σειρά πρέπει να αλλάξω έτσι ώστε να αλλάξω το χρώμα στο code
όταν κάνω δημοσίευση κάποιου post?
Πχ έχω μαύρο φόντο στο φόρουμ και όταν βάζω κάτι σε κώδικα, εμφανίζεται σε άσπρο φόντο το σημείο του κώδικα, και φαίνεται πολύ χάλια!!

Thanks

/* Normal, standard links. */
a:link
{
color: #00FFFF;
text-decoration: none;
}
a:visited
{
color: #FFFF00;
text-decoration: none;
}
a:hover
{
      color: #F5F5F7;
text-decoration: none;
}

/* Navigation links - for the link tree. */
.nav, .nav:link, .nav:visited
{
color: #A0A0A0;
text-decoration: none;
}
a.nav:hover
{
color: #F5F5F7;
text-decoration: none;
}

/* Tables should show empty cells. */
table
{
empty-cells: show;
}

/* By default (td, body..) use verdana in black. */
body, td, th , tr
{
color: #808080;
font-size: small;
font-family: Trebuchet MS, sans-serif;
}

/* The main body of the entire forum. */
body
{
background-color: #000000;
background-image: url(images/bg.gif);
background-repeat: repeat-x;

margin: 50px;
padding: 0px 0px 0px 0px;
}

/* Input boxes - just a bit smaller than normal so they align well. */
input, textarea, button
{
color: #f5f5f5;
font-family: verdana, sans-serif;
}
input, button
{
border: 1px solid #181818;
background-color: #1e1e1e;
font-size: 90%;
}

textarea

{

color: #f5f5f5;
background-color: #1e1e1e;
font-family: verdana, sans-serif;}

/* All input elements that are checkboxes or radio buttons. */
input.check
{
}

/* Selects are a bit smaller, because it makes them look even better 8). */
select
{
font-size: 90%;
font-weight: normal;
color: #000000;
font-family: verdana, sans-serif;
}

/* Standard horizontal rule.. ([hr], etc.) */
hr, .hrcolor
{
height: 1px;
border: 0;
color: #666666;
background-color: #666666;
}

/* No image should have a border when linked */
a img
{
border: 0;
}
/* A quote, perhaps from another post. */
.quote
{
color: #000000;
background-color: #808080;
border: 1px solid #000000;
margin: 1px;
padding: 1px;
font-size: x-small;
line-height: 1.4em;
}

/* A code block - maybe even PHP ;). */
.code
{
color: #000000;
background-color: #dddddd;
font-family: "courier new", "times new roman", monospace;
font-size: x-small;
line-height: 1.3em;
/* Put a nice border around it. */
border: 1px solid #000000;
margin: 1px auto 1px auto;
padding: 1px;
width: 99%;
/* Don't wrap its contents, and show scrollbars. */
white-space: nowrap;
overflow: auto;
/* Stop after about 24 lines, and just show a scrollbar. */
max-height: 24em;
}

/* The "Quote:" and "Code:" header parts... */
.quoteheader, .codeheader
{
color: #000000;
text-decoration: none;
font-style: normal;
font-weight: bold;
font-size: x-small;
line-height: 1.2em;
}

/* Generally, those [?] icons.  This makes your cursor a help icon. */
.help
{
cursor: help;
}

/* /me uses this a lot. (emote, try typing /me in a post.) */
.meaction
{
color: red;
}

/* The main post box - this makes it as wide as possible. */
.editor
{
width: 96%;
}

/* Highlighted text - such as search results. */
.highlight
{
background-color: yellow;
font-weight: bold;
color: black;
}

/* Alternating backgrounds for posts, and several other sections of the forum. */
.windowbg, #preview_body
{
      padding: 1px;
color: #5B5B5B;
background-color: #000000;
}
.windowbg2
{
      padding: 0px;
color: #5B5B5B;
background-color: #000000;
}
.windowbg3
{
      padding: 0px;
color: #5B5B5B;
background-color: #000000;
}
/* the today container in calendar */
.calendar_today
{
background-color: #FFFFFF;
}

/* These are used primarily for titles, but also for headers (the row that says what everything in the table is.) */
.titlebg, tr.titlebg th, tr.titlebg td, .titlebg2, tr.titlebg2 th, tr.titlebg2 td
{
color: #F5F5F5;
font-style: normal;
background: url(images/titlebg.jpg) #000000 repeat-x;
border-bottom: solid 1px #111111;
border-top: solid 1px #006BC4;
padding-left: 10px;
padding-right: 10px;
}
.titlebg, .titlebg a:link, .titlebg a:visited
{
font-weight: italic;
color: gray;
font-style: normal;
}

.titlebg a:hover
{
color: #FFFFFF;
}
/* same as titlebg, but used where bold text is not needed */
.titlebg2 a:link, .titlebg2 a:visited
{
color: black;
font-style: normal;
text-decoration: underline;
}

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

/* This is used for categories, page indexes, and several other areas in the forum.
.catbg and .catbg2 is for boardindex, while .catbg3 is for messageindex and display headers*/
.catbg , tr.catbg td , .catbg3 , tr.catbg3 td
{
background: url(images/catbg.jpg) #111111 repeat-x;
color: #ffffff;
padding-left: 10px;
padding-right: 10px;
line-height: 18px;
}
.catbg2 , tr.catbg2 td
{
background: url(images/catbg2.jpg) #111111 repeat-x;
color: #ffffff;
padding-left: 10px;
padding-right: 10px;
line-height: 18px;
}
.catbg, .catbg2, .catbg3
{
border-bottom: solid 1px #111111;
}
.catbg, .catbg2
{
font-weight: bold;
}
.catbg3, tr.catbg3 td, .catbg3 a:link, .catbg3 a:visited
{
font-size: 95%;
color: white;
text-decoration: none;
}
.catbg a:link, .catbg a:visited , .catbg2 a:link, .catbg2 a:visited
{
color: #0078DB;
text-decoration: none;
}
.catbg a:hover, .catbg2 a:hover, .catbg3 a:hover
{
color: #F5F5F5;
}
/* This is used for tables that have a grid/border background color (such as the topic listing.) */
.bordercolor
{
background-color: #000000;
padding: 0px;
}

/* This is used on tables that should just have a border around them. */
.tborder
{
padding: 0px;
border: 1px solid #191919;

}

/* Default font sizes: small (8pt), normal (10pt), and large (14pt). */
.smalltext
{
font-size: x-small;
font-family: verdana, sans-serif;
}
.middletext
{
font-size: 90%;
}
.normaltext
{
font-size: small;
}
.largetext
{
font-size: large;
}


/* Posts and personal messages displayed throughout the forum. */
.post, .personalmessage
{
width: 100%;
overflow: auto;
line-height: 1.3em;
}

/* All the signatures used in the forum.  If your forum users use Mozilla, Opera, or Safari, you might add max-height here ;). */
.signature
{
width: 100%;
overflow: auto;
padding-bottom: 3px;
line-height: 1.3em;
}

/* Sometimes there will be an error when you post */
.error
{
color: red;
}


/* definitions for the main tab, active means the tab reflects which page is displayed */
.maintab_first, .maintab_back, .maintab_last, .maintab_active_first, .maintab_active_back, .maintab_active_last
{
color: white;
text-transform: none;
vertical-align: top;
}
.maintab_back, .maintab_active_back
{
color: white;
text-decoration: none;
font-size:  11px;
vertical-align: top;
padding: 7px 7px 7px 7px;
font-family: tahoma, sans-serif;
      font-weight: bold;
}

.maintab_first
{
background: url(images/baslik.gif) left bottom no-repeat;
width: 10px;
}
.maintab_back
{
background: url(images/baslik.gif) left bottom repeat-x;
}
.maintab_last
{
background: url(images/baslik.gif) left bottom no-repeat;
width: 8px;
}
.maintab_active_first
{
background: url(images/baslik.gif) left bottom no-repeat;
width: 6px;
}
.maintab_active_back
{
background: url(images/baslik.gif) left bottom repeat-x;
}
.maintab_active_last
{
background: url(images/baslik.gif) left bottom no-repeat;
width: 8px;
}

/* how links behave in main tab. */
.maintab_back a:link , .maintab_back a:visited, .maintab_active_back a:link , .maintab_active_back a:visited
{
color: #006BC4;
text-decoration: none;
}

.maintab_back a:hover, .maintab_active_back a:hover
{
color: #609AFF;
text-decoration: none;
}
/* definitions for the mirror tab */
.mirrortab_first, .mirrortab_back, .mirrortab_last, .mirrortab_active_first, .mirrortab_active_back, .mirrortab_active_last
{
color: white;
text-transform: none;
vertical-align: top;
}
.mirrortab_back, .mirrortab_active_back
{
color: white;
text-decoration: none;
font-size: 9px;
vertical-align: top;
padding: 7px 7px 7px 7px;
font-family: tahoma, sans-serif;
}

.mirrortab_first
{
background: url(images/baslik.gif) no-repeat;
width: 10px;
}
.mirrortab_back
{
background: url(images/baslik.gif) repeat-x;
}
.mirrortab_last
{
background: url(images/baslik.gif) no-repeat;
width: 6px;
}
.mirrortab_active_first
{
background: url(images/baslik.gif) no-repeat;
width: 6px;
}
.mirrortab_active_back
{
background: url(images/baslik.gif) repeat-x;
}
.mirrortab_active_last
{
background: url(images/baslik.gif) no-repeat;
width: 8px;
}

/* how links behave in mirror tab. */
.mirrortab_back a:link , .mirrortab_back a:visited, .mirrortab_active_back a:link , .mirrortab_active_back a:visited
{
color: white;
text-decoration: none;
}

.mirrortab_back a:hover, .mirrortab_active_back a:hover
{
color: #DDE9FF;
text-decoration: none;
}

/* The AJAX notifier */
#ajax_in_progress
{
background: #32CD32;
color: white;
text-align: center;
font-weight: bold;
font-size: 18pt;
padding: 3px;
width: 100%;
position: fixed;
top: 0;
left: 0;
}

GoofyX

Γραμμή 117:
/* A code block - maybe even PHP ;). */
.code
{
   color: #000000;
   background-color: #dddddd;
   font-family: "courier new", "times new roman", monospace;
   font-size: x-small;
   line-height: 1.3em;
   /* Put a nice border around it. */
   border: 1px solid #000000;
   margin: 1px auto 1px auto;
   padding: 1px;
   width: 99%;
   /* Don't wrap its contents, and show scrollbars. */
   white-space: nowrap;
   overflow: auto;
   /* Stop after about 24 lines, and just show a scrollbar. */
   max-height: 24em;
}

Το αλλάζεις σε
/* A code block - maybe even PHP ;). */
.code
{
   color: #dddddd;
   background-color: #000000;
   font-family: "courier new", "times new roman", monospace;
   font-size: x-small;
   line-height: 1.3em;
   /* Put a nice border around it. */
   border: 1px solid #000000;
   margin: 1px auto 1px auto;
   padding: 1px;
   width: 99%;
   /* Don't wrap its contents, and show scrollbars. */
   white-space: nowrap;
   overflow: auto;
   /* Stop after about 24 lines, and just show a scrollbar. */
   max-height: 24em;
}

Σε ενδιαφέρει το background-color και color για το χρώμα του κειμένου.
... Morpheus: What is "real"? How do you define "real"? If you 're talking about what you can feel, what you can smell, what you can taste and see, then "real" is simply electrical signals interpreted by your brain...

anoksidotos

Σε ευχαριστώ πάρα πολύ GoofyX Δεν θα το έβρισκα!!!

anoksidotos

Και πάλι εδώ!!
Αυτή τη φορά, στο ίδιο style.ccs που πόσταρα παραπάνω, θέλω να προσθέσω οριζόντιες ή κάθετες γραμμές έτσι ώστε να ξεχωρίζονται τα link των θεμάτων όπως στην φώτο

Δεν μπορώ να βρω κάτι, και επίσης δεν ξέρω αν ήδη υπάρχουν γραμμές και επειδή έχουν το ίδιο χρώμα με το φόντο του themes δεν φαίνονται!


Butcher

Θα πρέπει να βρεις πιο είναι το class ή το id που χρησιμοποιεί για την εμφάνιση των θεμάτων και να βάλεις ένα border-bottom: 1px solid #fff;

1px: πάχος γραμμής
Solid: στυλ γραμμής, στη συγκεκριμένη περίπτωση κλασική ευθείς γραμμή Περισσότερα
#fff: το χρήμα που θες να έχει η γραμμή

Χρησιμοποίησε το Web Developer, plugin του Firefox, για να βρεις τα styles που θες.

anoksidotos

Quote from: Butcher on April 17, 2010, 06:44:23 AM
Θα πρέπει να βρεις πιο είναι το class ή το id που χρησιμοποιεί για την εμφάνιση των θεμάτων και να βάλεις ένα border-bottom: 1px solid #fff;

Ερώτηση: Σε αυτό το class δεν υπάρχει κάτι που να δείχνει τις γραμμές?
Αυτό το class χρησιμοποιώ

Butcher

Προφανώς το class που χρησιμοποιείται για να σου εμφανίσει τα μηνύματα  δεν έχει border. Την ερώτησή σου δεν μπορώ να πω πως την κατάλαβα. Αν θες δώσε ένα link του forum σου
να ρίξω μια ματιά...

Advertisement: