Ученик. Почему не работает? - вопрос №969317

Не выводит картинку в next()

<html><head><title>bkgr-img</title>

<meta http-equiv=«content-type» type=«text/html CharSet=windows-1251» />

<link href=«bkgr-img.css» rel=«StyleSheet» type=«text/css» />
<style>
body#foto
{
background-image: url(picture\9.jpg);
background-repeat: no-repeat;
background-position: CENTER;
background-color: white;
cursor: hand;
COLOR: blue;
}
span{ background-color: white; }
font{ font-style: italic; }</style>

<script src=«bkgr-img.js» type=«text/JavaScript» language=«JavaScript» charset=«UTF-8»>

var quantity = get_quantity();
var pnt = get_pnt();
var cnt = 0;
var max = get_max();

function get_quantity() { return 12; }
function get_pnt() { return 0; }
function get_max() { max = 3; if ( max >quantity ) {return quantity} else {return max} }

function next()
{
alert(«next»);
pnt += 1; cnt += 1;
if ( pnt < quantity || cnt < max )
 { alert(«if»);document.getElementById(«foto»).style.backgroundImage = «picture/» + pnt + ".jpg" }
else {top.location = «pass.html»}
}
</script></head>

<body id=«foto» scroll=«no» OnLoad=«ini()» OnCLick='next()'>
<div align=«center»><span><font>E-mail: </font><a href="mailto:sigam@mail.md?subject=Portret">sigam@mail.md © </a></span></div>
</body></html>

Лучший ответ по мнению автора

Потому что код сформирован не правильно.

27.02.14
Лучший ответ по мнению автора
Посмотреть всех экспертов из раздела Технологии > JavaScript,Ajax,HTML
Пользуйтесь нашим приложением Доступно на Google Play Загрузите в App Store