Selected values with commas and pipes

Selected values with commas and pipes

hi there

i'm writing some code that will display or hide divs based on the selected option in a dropdown list fo a form, but the form values i have been given to work with contain commas and pipes which prevent this working as per code snippet below:

<script type="text/javascript">
$(document).ready(function(){
$('#32,care|fish').hide();
$('#13,care|cake').hide();
$('#19,fish|cakes').hide();
$("#type").change(function(){
$("#" + this.value).show().siblings().hide();
});

$("#type").change();
});
</script>
<body>
<select id="type">
<option value="32,care|fish">Div 1</option>
<option value="13,care|cake">Div 2</option>
<option value="19,fish|cakes">Div 3</option>
</select>


Is there any workaround for this?

many thanks

Gar