PDA

View Full Version : Datefield change style ?



stormguard
13 Jun 2007, 7:29 AM
I have a simple form, but if i am click on the dateField so that it pops-up
the color of the datenumbers ist white and i can't see them.
How do i change the color to black?



form_2 = new Ext.Form({
id:'NewAccountForm',
labelAlign: 'right',
labelWidth: 120,
buttonAlign: 'center',
mehod: 'POST',
action: pfad
});

form_2.add(
new Ext.form.TextField({
labelSeparator:'',
name: 'new_account',
value:'new_account',
hidden:true,
allowBlank:false
}),
new Ext.form.TextField({
fieldLabel: 'Accountname',
name: 'accountname',
allowBlank:false,
blankText:'Bitte Accountname angeben!'
}),
new Ext.form.TextField({
fieldLabel: 'Vorname',
name: 'vorname',
allowBlank:false,
blankText:'Bitte Vornamen angeben!'
}),
new Ext.form.TextField({
fieldLabel: 'Nachname',
name: 'nachname',
allowBlank:false,
blankText:'Bitte Nachnamen angeben!'
}),
new Ext.form.TextField({
fieldLabel: 'E-Mail',
name: 'e_mail',
allowBlank:false,
vtype:'email',
blankText:'Bitte E-Mailadresse angeben!'
}),
new Ext.form.DateField({
fieldLabel: 'Geburtsdatum',
name: 'geb_datum',
allowBlank:false,
format:'Y-m-d',
blankText:'Bitte geben Sie das Geburtsdatum an.'
}),
new Ext.form.Checkbox({
fieldLabel:'Aktiv',
checked:true,
name:'aktiv'
})
);

Here could see what i mean....
I hope someone gots a solution for me :-?


http://www.stormguard.de/date_field.JPG

tryanDLS
13 Jun 2007, 7:47 AM
That appears to be a problem with your CSS - are you using ext-all.css? Look at the rendered HTML in firebug - in the right tab you'll be able to see the specific classes that are applied to those elements to determine what properties are set and where they're from.

stormguard
13 Jun 2007, 8:05 AM
this is the style which firebug shows in the right tab,
i can't see any color definiton :-/
and yes i am using ext-all.css and ytheme-aero.css



element.style {
display:block;
height:195px;
left:608px;
top:287px;
width:191px;
z-index:14999;
}
.x-shadow {ext-all.css (line 165)
display:none;
left:0pt;
overflow:hidden;
position:absolute;
top:0pt;
}
html, body, div, dl, dt, dd, ul, ol, li, h1, h2, h3, h4, h5, h6, pre, form, fieldset, input, p, blockquote, th, td {ext-all.css (line 9)
margin:0pt;
padding:0pt;
}

stormguard
13 Jun 2007, 8:14 AM
i think i have found the problem...


a:link {stylesheet.css (line 34)
color:#FFFFFF;
font-family:Verdana;
font-size:8pt;
font-weight:bold;
text-decoration:none;
}

i colored the links on my site white.... and the numbers INSIDE the datefield are links to... so my css used.... (see obove)
i think i should change this.. ;)
and thanks for the hint with firebug!



so it works...
i just changed my links

<a href=""></a> to
<a class="menu" href=""></a>
and changed the css


a.menu {
cursor:pointer;
font-family:Verdana;
font-size:8pt;
text-decoration:none;
font-weight:bold;
color:#FFFFFF;
}

a.menu:link {
font-family:Verdana;
font-size:8pt;
text-decoration:none;
font-weight:bold;
color:#FFFFFF;
}

a.menu:visited {
font-family:Verdana;
font-size:8pt;
text-decoration:none;
font-weight:bold;
color:#FFFFFF;
}

a.menu:hover {
font-family:Verdana;
font-size:8pt;
text-decoration:none;
font-weight:bold;
color:#000000;
}

a.menu:active {
font-family:Verdana;
font-size:8pt;
text-decoration:none;
font-weight:bold;
color:#FFFFFF;

}

a.menu:focus {
font-family:Verdana;
font-size:8pt;
text-decoration:none;
font-weight:bold;
color:#FFFFFF;
}


now it works fine... cause there are different classes ;)