Hi,

you can set custom styles for individual components via _javascript_ in the onload handler of
the page. But this is more like a workaround, because not all components support markups
and I don't want to create for everey color or style I need a new markup in my own theme.

Example:

<tc:script >
  function initStyles() {
    setStyle('mainPage:text1', 'color', 'red');
    setStyle('mainPage:text1', 'fontWeight', 'bold');
  }
 
  function setStyle(id, style, value) {
    if (value != null && value != "") {
      var element = document.getElementById(id);
      if (element != null) {
        element.style[style] = value;
      } else {
        alert('Element ' + id + ' not found!');
      }
    }
  }
 
Regards
Helmut

 
Hi Bernd,

With out writing any custom themes, can i display a text in Bold/Red in color.

As i am a newbie , i dont think that i would be able to write my own custome theme rt now.

But i need to display the text in bold using Tobago tags.

Please help me over this,

thnx

----- Original Message ----
From: Bernd Bohmann <[EMAIL PROTECTED]>
To: MyFaces Discussion <[email protected]>
Sent: Tuesday, 23 January, 2007 12:50:06 PM
Subject: Re: [Tobago] Sessions with Tobago

Hello,

with an own theme you can define your own markup:

http://myfaces.apache.org/tobago/faq.html#tobago/custommarkup

Regards

Bernd

madan chowdary wrote:
> Hi Bernd,
>
> Thnx for your rely and suggestions.
>
> I will work over with sessions once i reach my office.
>
> But i have one more doubt.
>
> Just for time being, i want to display a <tc:out> value in bold, and other one in red color.
>
>  I used the markup as specified in the docs, but the whole text background is changing the color.
>
> I just need to display the text in Red/Bold.
>
> How to achieve this ?
>
> ----- Original Message ----
> From: Bernd Bohmann <[EMAIL PROTECTED]>
> To: MyFaces Discussion <[email protected]>
> Sent: Tuesday, 23 January, 2007 12:41:22 AM
> Subject: Re: [Tobago] Sessions with Tobago
>
> Hello,
>
> madan chowdary wrote:
>> Hi all,
>>
>> I am new to Tobago and working over that, seeing over the net and this group.
>>
>> My query is how to use sessions with Tobago.
>>
>> I want a userID to be put into HttpSession object. I Tried this with intializing my managed bean with session scope. But i dont need all my values of the bean to set in the session.I just need userID.
>>
> You have several options.
>
> You can add a own managed bean for the userId only
>
> or
>
> you can set it in the session in your managed bean with
>
> FacesContext.getCurrentInstance().getExternalContext().getSessionMap().put("userId",
> userId);
>
>
>
>> can anyone please help me over this...
>>
>> and can anyone please tell me where can i get detailed explaination about the tags and how to change the styles of the components, i want to use my custom Styles.
>>
> http://myfaces.apache.org/tobago/documentation.html
>
> http://myfaces.apache.org/tobago/faq.html#tobago/owntheme
>
> The own theme section should be improved but your help is welcome :-)
>
>> How to get latest build Tobago 1.0.10, i dont see that in download section in Tobago  site.
>
> The 1.0.10 is not release but you can download the nightly build
>
> http://myfaces.apache.org/tobago/download.html
>
> http://people.apache.org/builds/myfaces/nightly/
>> thnx in advance...
>>
>> Regards,
>> Madan
>>
>>
>>
>>
>>        
>> __________________________________________________________
>> Yahoo! India Answers: Share what you know. Learn something new
>> http://in.answers.yahoo.com/
>
>
>
>
>
>
>
>         
> __________________________________________________________
> Yahoo! India Answers: Share what you know. Learn something new
> http://in.answers.yahoo.com/



Here’s a new way to find what you're looking for - Yahoo! Answers

Reply via email to