Toggle CCK field visibility with CCK radio buttons I have a content type with three cck fields

1 radio button, 1 text field, and 1 integer field.

What I am trying to do is by default have the text field and integer field hidden, and only show them dependent on the state of the radio button.

Example:

Two radio buttons, one which says text and one which says integer.  When the text radio box is checked, then the text box shows and the integer box is hidden and vice versa.
There is a contrib module written for just this: Conditional Fields. Here is a quote about it (from the module's project page):

... allows you to manage sets of dependencies between fields. When a field is “dependent”, it will only be available for editing and displayed if the state of the “dependee” field matches the right condition.
When editing a node (or any other entity type that supports fields, like users and categories), the dependent fields are dynamically modified with the States API.
You can, for example, define a custom “Article teaser&quot; field that is shown only if a &quot;Has teaser&quot; checkbox is checked.