
26.04.2007, 10:36
|
|
Новичок
Регистрация: 27.02.2007
Сообщений: 8
Провел на форуме: 33084
Репутация:
0
|
|
Спасибо за советы! Только вот как мне теперь сделать что бы функции увеличения\уменьшения изображения заработали?
Код:
<script type="text/javascript">
var Timer;
function ScrollLeft()
{
Timer = setInterval("document.getElementById('PANORAMA').scrollLeft -= 2", 10);
}
function ScrollRight()
{
Timer = setInterval("document.getElementById('PANORAMA').scrollLeft += 2", 10);
}
function ScrollUp()
{
Timer = setInterval("document.getElementById('PANORAMA').scrollTop += 2", 10);
}
function ScrollDown()
{
Timer = setInterval("document.getElementById('PANORAMA').scrollTop -= 2", 10);
}
function Resize()
{
Timer = setInterval("document.getElementById('karta').style.width=parseInt(document.getElementById('karta').style.width)-10+'px'", 30);
}
function Resizee()
{
Timer = setInterval("document.getElementById('karta').style.width=parseInt(document.getElementById('karta').style.width)+10+'px'", 30);
}
</script>
<div id="PANORAMA" style="width:450px; height:340px; border: 1px solid;
overflow:hidden">
<img src="1.gif" usemap="#karta1" id="karta">
<map name="karta1">
<area href="123.html" shape="rect" coords="25,36,114,98">
</map>
</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)">
<input type="button" value="+" title="+" style="width:25px"
onmousedown="Resizee()"
onmouseup="clearInterval(Timer)">
</div>
|
|
|