function ShowDelForm(o, c, i, id) {
	// o - reply link
	// c - in reply
	// i - item name
	// id - item id
	dv = o.parentNode;
	//
	while (dv.childNodes[0]) {
		dv.removeChild(dv.childNodes[0]);
	}
	//
	DelForm = document.createElement('form');
	DelForm.action = '/moderate/';
	DelForm.method = 'post';
	dv.appendChild(DelForm);
	//
	DelFormCaptionTitleSpan = document.createElement('span');
	DelFormCaptionTitleSpan.className = 'ReplyCaption';
	DelForm.appendChild(DelFormCaptionTitleSpan);
	DelFormCaptionTitle = document.createTextNode('Удалить камент');
	DelFormCaptionTitleSpan.appendChild(DelFormCaptionTitle);
	//
	DelFormAction = document.createElement('input');
	DelFormAction.type = 'hidden';
	DelFormAction.name = 'action';
	DelFormAction.value = 'delete';
	DelForm.appendChild(DelFormAction);
	//
	DelFormBack = document.createElement('input');
	DelFormBack.type = 'hidden';
	DelFormBack.name = 'back_url';
	DelFormBack.value = document.location;
	DelForm.appendChild(DelFormBack);
	//
	DelFormItem = document.createElement('input');
	DelFormItem.type = 'hidden';
	DelFormItem.name = 'item';
	DelFormItem.value = i;
	DelForm.appendChild(DelFormItem);
	//
	DelFormNewsId = document.createElement('input');
	DelFormNewsId.type = 'hidden';
	DelFormNewsId.name = 'itemid';
	DelFormNewsId.value = id;
	DelForm.appendChild(DelFormNewsId);
	//
	DelFormCommentId = document.createElement('input');
	DelFormCommentId.type = 'hidden';
	DelFormCommentId.name = 'commentid';
	DelFormCommentId.value = c;
	DelForm.appendChild(DelFormCommentId);
	//
	DelFormBan = document.createElement('select');
	DelFormBan.name = 'ban_option';
	DelForm.appendChild(DelFormBan);
	//
	DelOptions = Array('Просто удалить', 'Удалить и бан на неделю', 'Удалить и бан на месяц', 'Удалить и бан навсегда');
	DelOptionsVal = Array('', 'week', 'month', 'ban');
	for (j = 0; j < DelOptions.length; j++) {
		newOpt = new Option(DelOptions[j], DelOptionsVal[j]);
		DelFormBan.options[j] = newOpt;
	}
	//
	DelFormBody = document.createElement('textarea');
	DelFormBody.name = 'comment';
	DelFormBody.cols = 45;
	DelFormBody.id = 'Warning' + c;
	DelFormBody.className = 'ReplyFormBody';
	DelFormBody.rows = 8;
	DelFormBody.value = 'Неоднократное или злостное нарушение правил форума.';
	DelForm.appendChild(DelFormBody);
	//
	DelFormSubmit = document.createElement('input');
	DelFormSubmit.type = 'submit';
	DelFormSubmit.value = 'Удалить';
	DelFormSubmit.className = 'ReplyFormButton';
	DelForm.appendChild(DelFormSubmit);
	return false;
}
function ShowWarningForm(o, c, i, id) {
	// o - reply link
	// c - in reply
	// i - item name
	// id - item id
	dv = o.parentNode;
	//
	while (dv.childNodes[0]) {
		dv.removeChild(dv.childNodes[0]);
	}
	//
	WarningForm = document.createElement('form');
	WarningForm.action = '/moderate/';
	WarningForm.method = 'post';
	dv.appendChild(WarningForm);
	//
	WarningFormCaptionTitleSpan = document.createElement('span');
	WarningFormCaptionTitleSpan.className = 'ReplyCaption';
	WarningForm.appendChild(WarningFormCaptionTitleSpan);
	WarningFormCaptionTitle = document.createTextNode('Предупредить пользователя');
	WarningFormCaptionTitleSpan.appendChild(WarningFormCaptionTitle);
	//
	WarningFormAction = document.createElement('input');
	WarningFormAction.type = 'hidden';
	WarningFormAction.name = 'action';
	WarningFormAction.value = 'warning';
	WarningForm.appendChild(WarningFormAction);
	//
	WarningFormBack = document.createElement('input');
	WarningFormBack.type = 'hidden';
	WarningFormBack.name = 'back_url';
	WarningFormBack.value = document.location;
	WarningForm.appendChild(WarningFormBack);
	//
	WarningFormItem = document.createElement('input');
	WarningFormItem.type = 'hidden';
	WarningFormItem.name = 'item';
	WarningFormItem.value = i;
	WarningForm.appendChild(WarningFormItem);
	//
	WarningFormNewsId = document.createElement('input');
	WarningFormNewsId.type = 'hidden';
	WarningFormNewsId.name = 'itemid';
	WarningFormNewsId.value = id;
	WarningForm.appendChild(WarningFormNewsId);
	//
	WarningFormCommentId = document.createElement('input');
	WarningFormCommentId.type = 'hidden';
	WarningFormCommentId.name = 'commentid';
	WarningFormCommentId.value = c;
	WarningForm.appendChild(WarningFormCommentId);
	//
	WarningFormBody = document.createElement('textarea');
	WarningFormBody.name = 'comment';
	WarningFormBody.cols = 45;
	WarningFormBody.id = 'Warning' + c;
	WarningFormBody.className = 'ReplyFormBody';
	WarningFormBody.rows = 8;
	WarningFormBody.value = 'Нарушение правил форума.';
	WarningForm.appendChild(WarningFormBody);
	//
	WarningFormSubmit = document.createElement('input');
	WarningFormSubmit.type = 'submit';
	WarningFormSubmit.value = 'Предупредить';
	WarningFormSubmit.className = 'ReplyFormButton';
	WarningForm.appendChild(WarningFormSubmit);
	return false;
}
