[jQuery] Toggle Help
[jQuery] Toggle Help
Im just starting out with jQuery. Im getting stuck though.
Im trying to get jQuery to manipulate my form. Changing the drop down
menus to a given value. It does the first toggle fine, but won't do
the second. Could someone explain why and provide a solution. Ive been
trying for hours.
Heres what Ive got.
<script type="text/javascript">
$(document).ready(function(e){
$('a.typeswitch').click(function(e) {
$('a.typeswitch').toggle(
function () {
$(".typeselect").attr("selected","TV Shows");
},
function () {
$(".typeselect").attr("selected","Movies");
}
);
});
});
</script>
Thanks :)