I have this
Code html:
<div class="checkgrp"><div class="chkfirst"><input class="chkbox" type="checkbox" name="check[]" value="Bed / Bath Size" onclick="enable('a')"/>Bed / Bath Size</div>
    <div class="chksecond">
	<input class="checkinput" id="bedbath" type="text" name="a" /></div>

with this javascript

Code javascript:
function enable(elm){
document.forms[0][elm].disabled = false;
}

What I'm trying to do is have the textbox disabled unless the checkbox is checked, then the person can type into it. I know somethings wrong, but I don't know exactly what I'm lookin at since I dont know javascript at all