Get parent element colors

Discussion in 'Javascript' started by Simon, Apr 26, 2006.

  1. Simon

    Simon Guest

    Hi,

    I have a table that the user can specify their own colors, (using CSS or
    HTML).
    How can I retrieve the font-color and background-color of the element?

    So I would have something like

    <table>
    <tr>
    <td>
    <!--
    // echo a text to give the background color using the font text.
    //-->
    </td>
    </tr>
    </table>

    How could I do that?

    Simon
     
    Simon, Apr 26, 2006
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. MSNews
    Replies:
    1
    Views:
    2,755
    Alvin Bruney [MVP]
    Apr 22, 2004
  2. Replies:
    4
    Views:
    2,580
  3. Ian Wilson
    Replies:
    2
    Views:
    565
    Ian Wilson
    Jul 26, 2007
  4. AAaron123

    TreeNode colors come from anchor colors

    AAaron123, Aug 7, 2008, in forum: ASP .Net
    Replies:
    1
    Views:
    554
    darrel
    Aug 7, 2008
  5. ZelluX
    Replies:
    3
    Views:
    1,922
    Peter Otten
    Dec 1, 2008
Loading...

Share This Page