Jump to content
php.lv forumi

show/hide


priedzha

Recommended Posts

function toggle(id) {

var elem = document.getElementById(id);

if (elem.style.display == '') {
	elem.style.display = 'none';
} else {
	elem.style.display = '';
}
}

 

un uzliec onclick="toggle('kaukaads_id')" jebkuram elementam

Link to comment
Share on other sites

<style type="text/css">
#f1 {
display: none;
}
</style>

<script>
function toggle(id) {

var elem = document.getElementById(id);
display: 'none';


if (elem.style.display == '') {
	elem.style.display = 'none';
} else {
	elem.style.display = '';
}
}


</script>

 

Paslēpa, bet nezkapē vairs nedabojas tas javascript? ;D

Link to comment
Share on other sites

×
×
  • Create New...