This should do the trick:

<DIV CLASS='inputfield' STYLE='height:80px; height:auto; font-weight:bold;'
 >



On Fri, Dec 5, 2008 at 2:42 AM, insomniux <[EMAIL PROTECTED]> wrote:

>
> Thanks Jamie,
>
> This is useful info. In my case however there is a _style_ def in the
> tag, this will overrule the class definition:
>  <DIV CLASS='inputfield' STYLE='height:80px; font-weight:bold;'  >
> Taking this example as starting point. I cannot remove anything from
> this tag, but I can add additional info (any info, on any position).
> Could you think of any _addition_ to this tag which legally resets the
> height definition?
>
> Insomniux
>
> On 5 dec, 06:00, "Jamie C." <[EMAIL PROTECTED]> wrote:
> > insomniux,1. is it allowed to use two inline STYLE definitions in the
> same
> > tag
> >
> > This will cause a conflict in most browsers I think.
>
> OK, I could not find anywhere that it is not valid to apply more than
> 1 inline style per tag.
>
> >
> > 2. is there a way to conditionally apply an inline style (e.g. when
> > I'm a DIV, do not apply height, when I'm a TEXTAREA, do apply the
> > height)
> >
> > textarea.className{height: 80px;}
> > div.className{height: auto;}
> >
> > 3. is there a way (inline) to reset a previously defined style (e.g.
> > through the class)
> >
> > <div class="className1 className2"></div>
> > (className2 will override className1 styles)
> >
> > I think this answers your question.
> >
> > Cheers,
> > Jamie
> >
> > On Wed, Dec 3, 2008 at 3:38 PM, insomniux <[EMAIL PROTECTED]>
> wrote:
> >
> > > Hi, I have a FRAME which can be shown in two ways: editable and non-
> > > editable. My php program builds both representations in (nearly) the
> > > same way. The entire page is based on information from a database
> > > (both layout and content). On my pages I can have a textarea, for
> > > which I set the height property in an inline style:
> >
> > > <TEXTAREA CLASS='inputfield' STYLE='height:80px; font-weight:bold;'
> > > >here my text</TEXTAREA>
> >
> > > When my php mechanism builds the 'non-editable' representation, I
> > > replace the TEXTAREA with a DIV tag:
> >
> > > <DIV CLASS='inputfield' STYLE='height:80px; font-weight:bold;'  >here
> > > my text</DIV>
> >
> > > The information in the STYLE attribute is picked up from a database,
> > > meaning, I do not know in advance which styles are defined. In this
> > > case I want to 'unset' the height property. I've tried to ADD a second
> > > STYLE attribute: STYLE='height:auto':
> >
> > > <DIV CLASS='inputfield' STYLE='height:80px; font-weight:bold;'
> > > STYLE='height:auto;'>here my text</DIV>
> >
> > > This however does either nothing (example above) or also resets the
> > > font-style (when I switch both STYLE definitions).
> >
> > > My questions:
> > > 1. is it allowed to use two inline STYLE definitions in the same tag
> > > 2. is there a way to conditionally apply an inline style (e.g. when
> > > I'm a DIV, do not apply height, when I'm a TEXTAREA, do apply the
> > > height)
> > > 3. is there a way (inline) to reset a previously defined style (e.g.
> > > through the class)
> > > Thanks
> > > Insomniux
> >
>

--~--~---------~--~----~------------~-------~--~----~
--
You received this because you are subscribed to the "Design the Web with CSS" 
at Google groups.
To post: [email protected]
To unsubscribe: [EMAIL PROTECTED]
-~----------~----~----~----~------~----~------~--~---

Reply via email to