function refreshPIC()
{
	url = '/img.php?rand='+Math.random();
	document.getElementById('commPIC').src = url;	
}

function doSubmit(form)
{
	if (!document.form.name.value){alert('Вы не ввели имя'); return 0;}
	if (!document.form.email.value){alert('Вы не ввели e-mail'); return 0;}
	if (!document.form.message.value){alert('Вы не ввели текст сообщения'); return 0;}	
	
	var am = new SPXMCL();
	am.addParam('name',document.form.name.value);
	am.addParam('email',document.form.email.value);
	am.addParam('message',document.form.message.value);
	am.addParam('code',document.form.code.value);
	am.result_to = 'comment';
	
	document.getElementById('comment').innerHTML = '<img src="/img/loader.gif">';
	
	
	am.doR('','/sendMess.php');
}