||header: modified=false tpl_set=cwm_o2 tpl_version=2.7r||
<!---Note this template file is quite complex because in incorporates support for a wyswyg editlive editor. For a simpler version
of the template see sendf2.tpl
-->
<html>
<head>
<title>Create new message </title>
<script language="JavaScript">
<!--- hide script from old browsers



function pasteaddress()
{
        msgWindow2 = open('||action||?cmd=pick_edit&page=pasteadd&utoken=||utoken||','ADDRESSBOOK2','width=600,height=400,toolbar=no,location=no,directories=no,status=no,menubar=no,resizable=yes,scrollbars=no','POPUP');
        if (msgWindow2.opener == null) msgWindow2.opener = self;
        if (msgWindow2.opener.pickform == null) msgWindow2.opener.pickform = document.pickform;
}

function get_date(){
	var now, date;
	var day, monthDay, month, year, hours, minutes, seconds, offset;
	var dayNo, monthNo, offNo, sign;

	now = new Date();

	dayNo = now.getDay();
	if(dayNo == 0){
		day = "Sun";
	}else if(dayNo == 1){
		day = "Mon";
	}else if(dayNo == 2){
		day = "Tue";
	}else if(dayNo == 3){
		day = "Wed";
	}else if(dayNo == 4){
		day = "Thu";
	}else if(dayNo == 5){
		day = "Fri";
	}else if(dayNo == 6){
		day = "Sat";
	}

	monthNo = now.getMonth();
	if(monthNo == 0){
		month = "Jan";
	}else if(monthNo == 1){
		month = "Feb";
	}else if(monthNo == 2){
		month = "Mar";
	}else if(monthNo == 3){
		month = "Apr";
	}else if(monthNo == 4){
		month = "May";
	}else if(monthNo == 5){
		month = "Jun";
	}else if(monthNo == 6){
		month = "Jul";
	}else if(monthNo == 7){
		month = "Aug";
	}else if(monthNo == 8){
		month = "Sep";
	}else if(monthNo == 9){
		month = "Oct";
	}else if(monthNo == 10){
		month = "Nov";
	}else if(monthNo == 11){
		month = "Dec";
	}

	year = now.getYear();
	if(year < 50){
		year += 1900;
	}else if(year < 1000){
		year += 1900;
	}

	if(now.getHours() < 10){
		hours = "0" + now.getHours();
	}else{
		hours = now.getHours();
	}

	if(now.getMinutes() < 10){
		minutes = "0" + now.getMinutes();
	}else{
		minutes = now.getMinutes();
	}

	if(now.getSeconds() < 10){
		seconds = "0" + now.getSeconds();
	}else{
		seconds = now.getSeconds();
	}

	if(now.getDate() < 10){
		monthDay = "0" + now.getDate();
	}else{
		monthDay = now.getDate();
	}

	if(now.getTimezoneOffset() <= 0 ){
		sign = "+";
	}else{
		sign = "-";
	}

	offNo = now.getTimezoneOffset();
	offNo /= 60;
	offNo *= -1;
	||ifinstr||user_agent||msie||
//		offNo -= 1;
	||endif||
	offNo = Math.round(offNo);
	offset = "" + offNo;
	if(sign == "-"){
		offset = offset.substring(1, offset.length + 1);
	}
	if(eval(offset) < 10){
		offset = "0" + offset;
	}

	date = day + ", " + monthDay + " " + month + " " + year + " " + hours +
":" + minutes + ":" + seconds + " " + sign + offset + "00";


	document.sendform.send_date.value = date;
}


function check_attach(){
	if(document.sendform.attach.value != "" || document.sendform.attach2.value != "" || document.sendform.attach3.value != ""){
		alert("You must re-enter attachment fields after doing spell check ");
	}
}


function set_send(){
||ifinstr||user_agent||3.|| ||else||
	if(||ifdef||wysiwyg||1||else||0||endif|| || ||ifdef||temp_wysiwyg||1||else||0||endif||){
		if (EditLive_compatible() && EditLive_installed()) {
			document.sendform.message_html.value = messagebox.getSource();
			document.sendform.message.value = messagebox.getText();
		}
	}
||endif||
}

function editInWysiwyg(){
	document.wysiwygform.sbody.value = document.sendform.message.value;
	document.wysiwygform.submit();
}

function editInPlain(){
	document.ptform.sbody.value = messagebox.getSource();
	document.ptform.submit();
}

// end hiding from old browsers -->
</script>

<title>Create new message </title>

</head>
<body background="||nwimg||/cwback.jpg">
<form name="wysiwygform" method="post" action="||action||">
	<input type="hidden" name="set_wysiwyg" value="true">
	<input type="hidden" name="cmd" value="new">
	<input type="hidden" name="utoken" value="||utoken||">
	<input type="hidden" name="sbody" value="">
        <input type="hidden" name="oldmessage" value="||quote_sbody||">
</form>

<form name="sendform" ENCTYPE="multipart/form-data" method="post" action="||action||" onSubmit="get_date();set_send();">
  <input type="hidden" name="cmd" value="send">
  <input type="hidden" name="send_date" value="">
  <input type="hidden" name="utoken" value="||utoken||">
<table cellspacing="0" cellpadding="0">
	<tr>
		<td>
			<table cellspacing="0" cellpadding="0">
				<tr>
					<td align="right">
						To: 

						<input name="to" size="30"||ifdef||a_reply|| value="||a_reply||" ||else|| value="||a_from||" ||endif|| onFocus="document.sendform.oo[0].checked = true">
						<input TYPE="RADIO" NAME="oo" VALUE="t" CHECKED>
						<br>

						CC:
						<input name="cc" size="30" value="||h_cc||" onFocus="document.sendform.oo[1].checked = true">
						<input TYPE="RADIO" NAME="oo" VALUE="c">
						<br>

						BCC:
						<input name="bcc" size="30" value="||h_bcc||" onFocus="document.sendform.oo[2].checked = true">
						<input TYPE="RADIO" NAME="oo" VALUE="b">
						<br>

						Reply-To:
			  
						||ifdef||pop_name1||
						<script>
						<!--
							var replys = new Array();

							replys[0] = "||reply||";
							replys[1] = "||pop_reply0||";
							replys[2] = "||pop_reply1||";
							replys[3] = "||pop_reply2||";
							replys[4] = "||pop_reply3||";
							replys[5] = "||pop_reply4||";

						//-->
						</script>
						||endif||

						<input name="reply" size="30" value="||reply||" onFocus="document.sendform.oo[3].checked = true">
						<input TYPE="RADIO" NAME="oo" VALUE="r">
						<br>
					</td>
					<td align="left" rowspan="1">
						<table><tr>
						<td><input type="button" onClick="pasteaddress()" value="Address Book"></td>
						<td>Recent <input TYPE="BUTTON" NAME="Del" VALUE="Clear" onClick="dele()"></td></tr>
						
						<tr><td><select name="tolist" size="5" onChange="setto(this);">
							<option>||tolist||</option>
						</select></td>
						<td><select name="topick" size="5" onChange="setto(this);">
							<option>||topick||</option>
						</select></td></tr></table>
					</td>
				</tr>
				<tr>
					<td colspan="2">
						Subject:
						<input name="subject" size="64" value="||h_subject||">
					</td>
				</tr>
						
			</table>
		</td>
	</tr>
    <tr>
		<td>
			Enter your message text below: 
			<!--- input type=submit name="send" value="Send Now" --> 
			||ifdef||wysiwyg|| 
			||else||
				||ifdef||temp_wysiwyg||
					<input type="button" value="Plain Text editor" onclick="document.ptform.submit();">
				||else||
					<input type="submit" name="spell_check" value="Spell Check Message"  onClick="check_attach()">
					<input type="button" value="WYSIWYG editor" onclick="editInWysiwyg();">
				||endif||
			||endif||
			<input type="submit" name="send1" value="Send Message">
		</td>
    </tr>
||ifdef||item||
    <tr>
		<td>
			<input type="checkbox" name="rmove" value="on" ||rmove||> Move original to 
			<input type="hidden" name="item" value="||item||">
			<select name="dstfld" size="1" onChange="document.sendform.rmove.checked=true">
				<option>||rfldlist||</option>
			</select>
		</td>
    </tr>
||endif||
    <tr>
		<td>
			||ifinstr||user_agent||3.||
				<textarea wrap="physical" name="message" cols="64" rows="10" >||quote_body||
</textarea>
			||else||
				||ifdef||wysiwyg||
					||include||editlive.tpl||
				||else||
					||ifdef||temp_wysiwyg||
						||include||editlive.tpl||
					||else||
						<textarea wrap="physical" name="message" cols="64" rows="10" >||quote_body||
</textarea>
					||endif||
				||endif||
			||endif||
		</td>
    </tr>
</table>

  <table cellspacing="0" cellpadding="0">
    <tr>
      <td><input type="image" border="0" src="||nwimg||/s_send.jpg" name="Send" alt="Send Message"></td>
      <td align="right">Attach 1: </td>
      <td align="left"><input type="file" name="attach" value="||prev_attach||" size="24"> <script
      language="JavaScript">
<!--- hide script from old browsers
if (navigator.appVersion.indexOf('MSIE 3.',0) == "") document.writeln("<br>Unfortunately IE3 does not support attachments");
else if (navigator.appVersion.indexOf('MSIE 3.',0) >=0) document.writeln("<br>Unfortunately IE3 does not support attachments");
// end hiding from old browsers -->
</script> </td>
    </tr>
    <tr>
      <td><input type="checkbox" name="addsig" value="on" ||addsig||> Add Sig file </td>
      <td align="right">Attach 2: </td>
      <td align="left"><input type="file" name="attach2" value="||prev_attach2||" size="24"> </td>
    </tr>
    <tr>
      <td><input type="checkbox" name="send_autocc" value="on" ||send_autocc||> Send CC to self</td>
      <td align="right">Attach 3: </td>
      <td align="left"><input type="file" name="attach3" value="||prev_attach3||" size="24"> </td>
    </tr>
    <tr>
      <td><input type="checkbox" name="copyself" value="on" ||copyself||> Save a copy to self </td>
      <td align="right">&nbsp; Content-type: </td>
      <td><select name="content_type" size="1">
        <option selected></option>
        <option>text/html</option>
        <option>text/plain; charset=&quot;iso-8859-1&quot;</option>
        <option>text/plain; charset=&quot;iso-2022-jp&quot;</option>
        <option>text/html; charset=&quot;iso-2022-jp&quot;</option>
      </select>
	  ||endif||
	   </td>
    </tr>
  </table>
</form>


<form name="ptform" method="post" action="||action||">
	<input type="hidden" name="cmd" value="new">
	<input type="hidden" name="utoken" value="||utoken||">
	<input type="hidden" name="sbody" value="">
</form>

<p>||copyright|| </p>
</body>
</html>
<script language="JavaScript">
<!--- hide script from old browsers
function dele(){
  var i = 0, j;
  
   for (j=0; j<4; j++)
     if (document.sendform.oo[j].checked == true) i = j;  

  if (i==0)
       document.sendform.to.value = "";
  if (i==1)
       document.sendform.cc.value = "";
  if (i==2)
       document.sendform.bcc.value = "";
  if (i==3)
       document.sendform.reply.value = "";
  document.sendform.tolist.options[0].selected = true;
}
function setto(sel) {
  var option;
  var i;
 for (i=0; i<sel.options.length; i++) {
   if (sel.options[i].selected==true) {
     if (document.sendform.oo[0].checked == true){
       if (document.sendform.to.value != "")
        document.sendform.to.value = ", " + document.sendform.to.value;
       document.sendform.to.value = sel.options[i].value + document.sendform.to.value;
     }
     if (document.sendform.oo[1].checked == true){
       if (document.sendform.cc.value != "")
        document.sendform.cc.value = ", " + document.sendform.cc.value;
       document.sendform.cc.value = sel.options[i].value + document.sendform.cc.value;
     }
     if (document.sendform.oo[2].checked == true){
       if (document.sendform.bcc.value != "")
        document.sendform.bcc.value = ", " + document.sendform.bcc.value;
       document.sendform.bcc.value = sel.options[i].value + document.sendform.bcc.value;
     }
     if (document.sendform.oo[3].checked == true){
       document.sendform.reply.value = sel.options[i].value;
     }
   }
 }   
   if (sel.options[0].selected==true){
     dele();
   }
}
// end hiding from old browsers -->
</script>

























































||checksum=2087982||
