Показать сообщение отдельно

  #15  
Старый 25.04.2007, 16:27
SiNaC0m
Новичок
Регистрация: 27.02.2007
Сообщений: 8
С нами: 10105652

Репутация: 0
По умолчанию

Цитата:
<html>
<script type="text/javascript">
var Timer;
function ScrollLeft()
{
Timer = setInterval("document.getElementById('PANORAMA').s crollLeft -= 2", 10);
}
function ScrollRight()
{
Timer = setInterval("document.getElementById('PANORAMA').s crollLeft += 2", 10);
}
function ScrollUp()
{
Timer = setInterval("document.getElementById('PANORAMA').s crollTop += 2", 10);
}
function ScrollDown()
{
Timer = setInterval("document.getElementById('PANORAMA').s crollTop -= 2", 10);
}
function Resize()
{
Timer = setInterval("document.getElementById('picture').st yle.width=parseInt(document.getElementById('pictur e').style.width)-10+'px'", 30);
T = setInterval("document.getElementById('p1').style.w idth=parseInt(document.getElementById('p1').style. width)-10+'px'", 30);
}
function Resizee()
{
Timer = setInterval("document.getElementById('picture').st yle.width=parseInt(document.getElementById('pictur e').style.width)+10+'px'", 30);
T = setInterval("document.getElementById('p1').style.w idth=parseInt(document.getElementById('p1').style. width)+10+'px'", 30);
}
</script>
<div id="PANORAMA" style="width:700px; height:550px; border: 1px solid;overflow:hidden">
<img id='p1' src='1.gif' style="position:absolute;left:123px;top:343px">
<img id="picture" src="2.gif" style="width:700px"/>
</div>
<div style="width:700px; text-align:center">
<input type="button" value="<" title="Scroll left" style="width:25px"
onmousedown="ScrollLeft()"
onmouseup="clearInterval(Timer)">
<input type="button" value=">" title="Scroll right" style="width:25px"
onmousedown="ScrollRight()"
onmouseup="clearInterval(Timer)">
<input type="button" value="\/" title="Scroll down" style="width:25px"
onmousedown="ScrollUp()"
onmouseup="clearInterval(Timer)">
<input type="button" value="/\" title="Scroll up" style="width:25px"
onmousedown="ScrollDown()"
onmouseup="clearInterval(Timer)">
<input type="button" value="-" title="-" style="width:25px"
onmousedown="Resize()"
onmouseup="clearInterval(Timer,T)">
<input type="button" value="+" title="+" style="width:25px"
onmousedown="Resizee()"
onmouseup="clearInterval(Timer,T)">
</div>
</html>
Кто-нибудь, объясните мне пожалуйсто, почему у меня объявленные функции действуют только на id="picture", а на id='p1' не деуствуют!? Где ошибка?
 
Ответить с цитированием