ajax help

Hi,

I have one checkbox( by default checked), if user un-checked then will display ajax window with four radio button. Can you help me how to do this? small example will me a lot.

<tr>

&lt;td&gt;&lt;?php echo CHtml::activeLabel(&#036;form,'phone'); ?&gt;&lt;/td&gt;


&lt;td&gt;&lt;?php echo CHtml::activeCheckBox(&#036;form,'phone'); ?&gt;&lt;/td&gt;

</tr>

THanks

Nemo

give it an id , like


<?php echo CHtml::activeCheckBox($form,'phone',array('id'=>'phone_check')); ?>

and the rest is pure js, something like :


$('#phone_check').change(function(){

$my_radios=$('#my_radio_buttons');

if($my_radios.html()==='')//theres no content in it, there are better ways to check this

	$my_radios.addClass('my_load_class')

                      	.load('/my/ajax/content',function(){

                     			$(this).removeClass('my_load_class');

               			});

$my_radios.toggle();//toggle its visibility

});