<!-- BEGIN bb_panel -->
<script>
var  id ='text';
function bbcode(Tag) {
	var Open='['+Tag+']';
	var Close='[/'+Tag+']';
	var object = document.getElementById(id);
	object.focus();
	if (Open=='[url]'){
		var Open='['+Tag+'=http://]';
	}
	if (window.attachEvent && navigator.userAgent.indexOf('Opera') === -1) {                                        
		var s = object.sel;
		if(s){                                  
			var l = s.text.length;
			s.text = Open + s.text + Close;
			s.moveEnd("character", -Close.length);
			s.moveStart("character", -l);                                           
			s.select();                
		}
	} else {                                              
		var ss = object.scrollTop;
		sel1 = object.value.substr(0, object.selectionStart);
		sel2 = object.value.substr(object.selectionEnd);
		sel = object.value.substr(object.selectionStart, object.selectionEnd - object.selectionStart);                                              
		object.value = sel1 + Open + sel + Close + sel2;
		object.selectionStart = sel1.length + Open.length;
		object.selectionEnd = object.selectionStart + sel.length;
		object.scrollTop = ss;                                             
	}
	return false;
}
</script>
<!-- END bb_panel -->

<form action="{S_POST_ACTION}" method="post" {S_FORM_ENCTYPE}>
<div class="catSides"><img src="/themes/profmas/icrz.png" alt="*"> 
{L_POST_A}
</div>
{VID}{VID2}
<!-- BEGIN switch_username_select -->
<div class="row1">
{L_USERNAME}:<br/>
<input type="text" name="username" />
</div>
<!-- END switch_username_select -->
<!-- BEGIN switch_privmsg -->
<div class="row1">
{L_USERNAME}:<br/>
<input type="text" name="username" value="{USERNAME}" />
</div>
<!-- END switch_privmsg -->
<!-- BEGIN switch_allow_subject_on -->
<div class="row1">
{L_SUBJECT}:<br/>
<input type="text" name="subject" value="{SUBJECT}" style="width: 235px;"/>
</div>
<!-- END switch_allow_subject_on -->
<!-- BEGIN switch_privmsg -->
<div class="row_hard">
{L_SUBJECT}:<br/>
<input type="text" name="subject" value="{SUBJECT}" style="width: 235px;"/>
</div>
<!-- END switch_privmsg -->
<div class="row_hard">
Сообщение:<br/>
<!-- BEGIN bb_panel -->
<a href="javascript:void(0);" onclick="bbcode('b');">[b]</a> <a href="javascript:void(0);" onclick="bbcode('url');">[url]</a> <a href="javascript:void(0);" onclick="bbcode('code');">[code]</a> <a href="javascript:void(0);" onclick="bbcode('i');">[i]</a> <a href="javascript:void(0);" onclick="bbcode('u');">[u]</a><br/>
<!-- END bb_panel -->
<textarea id="text" name="message" rows="5" cols="15" style="width: 235px;">{MESSAGE}</textarea>
</div>
<!-- BEGIN switch_confirm -->
<div class="row_hard">
Код подтверждения:<br/>
{CONFIRM_IMG}<br/>
<input type="text" name="confirm_code" value="" />
</div>
<!-- END switch_confirm -->
{POLLBOX}
<!-- BEGIN switch_type_toggle -->
<div class="row_hard">{S_TYPE_TOGGLE}</div>
<!-- END switch_type_toggle -->
<div class="row_hard">

<!-- BEGIN switch_notify_checkbox -->
<input type="checkbox" name="notify" {S_NOTIFY_CHECKED} /> {L_NOTIFY_ON_REPLY}<br/>
<!-- END switch_notify_checkbox -->
<!-- BEGIN switch_delete_checkbox -->
<input type="checkbox" name="delete" /> Удалить сообщение<br/>
<!-- END switch_delete_checkbox -->
{S_HIDDEN_FORM_FIELDS}
<input class="subbutton" type="submit" name="post" value="{L_SUBMIT}" />
</div>
{ATTACHBOX}
</form>
<div class="panelhead">
<table style="width:100%" cellspacing="0" cellpadding="0"><tr>
<td style="border-right: 1px solid #0a5472;padding: 12px;"><a href="/rules.php?mode=faq&act=bbcode"><center><span class = "cvet">Bb Коды</span></center></a></td>
<td style="border-left: 1px solid #72bcd9;padding: 12px;"><a href="/smiles.php"><center><span class = "cvet">Смайлы</span></center></a></td>
<td style="border-left: 1px solid #72bcd9;padding: 12px;"><a href="/memberlist.php?admin"><center><span class = "cvet">Модераторы</span></center></a></td>

</center></a></td></tr></table></div>
