Replacing Radio Buttons With Styles

Hello :)

I am trying to replace radio buttons from radioButtonList with unique images.

The problem I am having is the labels created by radioButtonList are given a generic class of ‘radio’

Unfortunately they are not given individual class or id so I cannot style each label individually.

The reason I am using the label is so users can click the label to target the radio button.

I can add to htmloptions ‘style’=>‘display:none’ which hides the radio button image and I can apply class ‘class’=>‘myclass’ which kind of gets me halfway there.

But I cannot add an individual class to each radio button label so I cannot style each label individually.

How would I go about doing that?

Thanks in advance.

OK well I was hoping to get an answer.

I can probably solve the problem this time using nth child to target the labels but I have different groups of radioButtons next time I’m going to be stuck.

What would be cool if there was a way in radioButtonList to add unique selectors to the labels, it wouldn’t be hard to implement I’m sure and very useful.