Changed the js code for the files admin section to jQuery
This commit is contained in:
parent
47993fe29a
commit
76aceb9970
|
@ -1,11 +1,11 @@
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
function switchPublicFolder()
|
function switchPublicFolder()
|
||||||
{
|
{
|
||||||
var publicEnable = document.forms['filesForm'].elements['publicEnable'].checked;
|
var publicEnable = $('#publicEnable').is(':checked');
|
||||||
var sharingaimGroup = document.forms['filesForm'].elements['sharingaim'];
|
var sharingaimGroup = $('input:radio[name=sharingaim]');
|
||||||
for(i=0;i<sharingaimGroup.length;i++) {
|
$.each(sharingaimGroup, function(index, sharingaimItem) {
|
||||||
sharingaimGroup[i].disabled = !publicEnable;
|
sharingaimItem.disabled = !publicEnable;
|
||||||
}
|
});
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<form name="filesForm" action='#' method='post'>
|
<form name="filesForm" action='#' method='post'>
|
||||||
|
|
Loading…
Reference in New Issue