<script language="JavaScript" type="text/JavaScript">
<!--
function showRecipient(target) {
    for (i=1; i<=4; i++) {
        rowname = 'recipientRow' + i;
        row = document.getElementById(rowname);
        row.style.display = "none";
    }
    selOpt = target.options[target.selectedIndex].value;
        switch(selOpt) {
            case '1':
                row = document.getElementById('recipientRow1');
                row.style.display = "";
            break;
            case '2':
                row = document.getElementById('recipientRow2');
                row.style.display = "";
            break;
            case '3':
                row = document.getElementById('recipientRow3');
                row.style.display = "";
            break;
            case '4':
                row = document.getElementById('recipientRow4');
                row.style.display = "";
            break;
            default:
            break;
        }
}
-->
</script>
<form name="addannouncement" id="addannouncement" method="post" action="index.php?fuse=admin&amp;action={ANNOUNCEMENTACTION}" >
<table width="535"  border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td>
		<table border="0" cellpadding="4" cellspacing="1" width="100%">
		<tr>
		  <td class="formLabel" align="right" nowrap="nowrap" width="54">[l]Title[/l]:</td>
		  <td class="formField" nowrap="nowrap"><input type="text" name="title" size="65" value="{ANNOUNCEMENTTITLE}"/></td>
		</tr>
		</table>
    </td>
  </tr>
  <tr>
    <td><table border="0" cellpadding="4" cellspacing="1" width="100%">
      <tbody>
        <tr>
          <td class="formLabel" align="right" nowrap="nowrap" width="75">[l]Post Date[/l]:</td>
          <td class="formField" nowrap="nowrap" width="100%">
            <input type="text" size="25" maxlength="25" name="postdate" id="postdate" value='{ANNOUNCEMENTDATE}'/>
            &nbsp;&nbsp;
        </td>
          <td class="formLabel" align="right" nowrap="nowrap" width="70">[l]Publish[/l]:</td>
          <td class="formField" align="left" nowrap="nowrap" width="10">
            <input type="checkbox" name="publish" {CHECK_PUBLISH}/>
          </td>
          <td class="formLabel" align="right" nowrap="nowrap" width="70">[l]E-mail[/l]:</td>
          <td class="formField" align="left" width="10">
            <input type="checkbox" name="email" />
          </td>
          <td class="formLabel" align="right" nowrap="nowrap" width="70">{OVERRIDE}:</td>
          <td class="formField" align="left" width="10">
            <input type="checkbox" name="override" />
          </td>
        </tr>
      </tbody>
    </table></td>
  </tr>
  <tr>
    <td><table border="0" cellpadding="4" cellspacing="1" width="100%">
      <tbody>
        <tr>
          <td class="inner" nowrap="nowrap" width="100%"><b>[l]Excerpt[/l]:</b> [l]Insert an excerpt of your announcement[/l]. (<a href="javascript:void(0);"  onmousedown="oldOpenHelpWindow('11')" >{HELPLINKWORDS}</a>)<br/>
              <textarea name="excerpt" rows="4" cols="105">{ANNOUNCEMENTEXCERPT}</textarea></td>
        </tr>
        <tr>
          <td class="inner"><b>[l]Post[/l]:</b> (<a href="javascript:void(0);"  onmousedown="oldOpenHelpWindow('11')" >{HELPLINKWORDS}</a>)<br/>
              <textarea id="post" name="post" rows="5" cols="105">
				<!-- BEGIN DYNAMIC BLOCK: announcementpost -->{ANNOUNCEMENTPOST}<!-- END DYNAMIC BLOCK: announcementpost -->
			  </textarea>
				  <script type="text/javascript">
					showRichTextEditor("oEdit1", 570, 200,
										[
											"Preview","Search","|",
											"Superscript","Subscript","|","LTR","RTL","|",
											"Table","Guidelines","Absolute","|",
											"Flash","Media","|","Characters","ClearAll","XHTMLFullSource","BRK",
											"Cut","Copy","Paste","PasteWord","PasteText","|",
											"Undo","Redo","|","Hyperlink","Bookmark","Image","|",
											"JustifyLeft","JustifyCenter","JustifyRight","JustifyFull","|",
											"Numbering","Bullets","|","Indent","Outdent","|",
											"Line","RemoveFormat","BRK",
											"StyleAndFormatting","TextFormatting","ListFormatting",
											"BoxFormatting","ParagraphFormatting","CssText","Styles","|",
											"Paragraph","FontName","FontSize","|",
											"Bold","Italic","Underline","Strikethrough","|",
											"ForeColor","BackColor"
										],
										"post");
				  </script>
      
          </td>
        </tr>
      </tbody>
    </table></td>
  </tr>
  <tr>
    <td><table border="0" cellpadding="4" cellspacing="1" width="100%">
      <tbody>
        <tr>
          <td class="formLabel" align="right" nowrap="nowrap" width="75">[l]Recipients[/l]:</td>
          <td class="formField" nowrap="nowrap" width="100%">
            <select name="recipientType" id="recipientType" onchange="showRecipient(this);">
				<!-- BEGIN DYNAMIC BLOCK: recipient -->
                <option value="{RECIPIENTVALUE}" {RECIPIENTSELECTED}>{RECIPIENT}&nbsp;&nbsp;</option>
				<!-- END DYNAMIC BLOCK: recipient -->
            </select>
          </td>
        </tr>
      </tbody>
    </table></td>
  </tr>
  <tr id="recipientRow1" style="display: {DISPLAYROW1}; " class="inner">
    <td>
  <table width="100%"  border="0" align="center" cellpadding="4" cellspacing="4">
    <tr>
      <td width="40%">
            <div align="right">
              <select name="statussource" size="10" multiple="multiple" id="statussource" style="width:140px ">
				<!-- BEGIN DYNAMIC BLOCK: rowstatus -->
                <option value="{STATUSID}">{STATUS}</option>
				<!-- END DYNAMIC BLOCK: rowstatus -->
              </select>
          </div></td><td width="10%"><p align="center">
          <input name="Submit" type="button" class="botones" onclick="move('remove','statussource','statustarget')" value=" &raquo; " />
        </p>
          <p align="center">
            <input name="Submit" type="button" class="botones" onclick="move('add','statussource','statustarget')" value=" &laquo; " />
        </p></td>
          <td width="40%">
            <div align="left">
              <select name="statustarget[]" size="10" multiple="multiple" id="statustarget" style="width:140px ">
                <!-- BEGIN DYNAMIC BLOCK: targetrowstatus -->
                <option value="{TARGETSTATUSID}">{TARGETSTATUS}</option>
                <!-- END DYNAMIC BLOCK: targetrowstatus -->
              </select>
          </div></td></tr>
  </table>
  </td>
  </tr>
  <tr id="recipientRow2" style="display: {DISPLAYROW2}; " class="inner">
    <td>
  <table width="100%"  border="0" align="center" cellpadding="4" cellspacing="4">
    <tr>
      <td width="40%">
            <div align="right">
              <select name="usersource" size="10" multiple="multiple" id="usersource" style="width:200px ">
				<!-- BEGIN DYNAMIC BLOCK: rowcustomer -->
                <option value="{CUSTOMERID}">{CUSTOMERNAME}</option>
				<!-- END DYNAMIC BLOCK: rowcustomer -->
              </select>
          </div></td><td width="10%"><p align="center">
          <input name="Submit" type="button" class="botones" onclick="move('remove','usersource','usertarget')" value=" &raquo; " />
        </p>
          <p align="center">
            <input name="Submit" type="button" class="botones" onclick="move('add','usersource','usertarget')" value=" &laquo; " />
        </p></td>
          <td width="40%">
            <div align="left">
              <select name="usertarget[]" size="10" multiple="multiple" id="usertarget" style="width:200px">
				<!-- BEGIN DYNAMIC BLOCK: targetrowcustomer -->
                <option value="{TARGETCUSTOMERID}">{TARGETCUSTOMERNAME}</option>
				<!-- END DYNAMIC BLOCK: targetrowcustomer -->
              </select>
          </div></td></tr>
  </table>
  </td>
  </tr>
  <tr id="recipientRow3" style="display: {DISPLAYROW3}; " class="inner">
    <td>
  <table width="100%"  border="0" align="center" cellpadding="4" cellspacing="4">
    <tr>
      <td width="40%">
            <div align="right">
              <select name="serversource" size="10" multiple="multiple" id="serversource" style="width:140px ">
				<!-- BEGIN DYNAMIC BLOCK: rowserver -->
                <option value="{SERVERID}">{SERVER}</option>
				<!-- END DYNAMIC BLOCK: rowserver -->
              </select>
          </div></td><td width="10%"><p align="center">
          <input name="Submit" type="button" class="botones" onclick="move('remove','serversource','servertarget')" value=" &raquo; " />
        </p>
          <p align="center">
            <input name="Submit" type="button" class="botones" onclick="move('add','serversource','servertarget')" value=" &laquo; " />
        </p></td>
          <td width="40%">
            <div align="left">
              <select name="servertarget[]" size="10" multiple="multiple" id="servertarget" style="width:140px ">
				<!-- BEGIN DYNAMIC BLOCK: targetrowserver -->
                <option value="{TARGETSERVERID}">{TARGETSERVER}</option>
				<!-- END DYNAMIC BLOCK: targetrowserver -->
              </select>
          </div></td></tr>
  </table>
  </td>
  </tr>
  <tr id="recipientRow4" style="display: {DISPLAYROW4}; " class="inner">
    <td>
  <table width="100%"  border="0" align="center" cellpadding="4" cellspacing="4">
    <tr>
      <td width="40%">
            <div align="right">
              <select name="packagesource" size="10" multiple="multiple" id="packagesource" style="width:140px ">
				<!-- BEGIN DYNAMIC BLOCK: rowpackage -->
                <option value="{PACKAGEID}">{PACKAGE}</option>
				<!-- END DYNAMIC BLOCK: rowpackage -->
              </select>
          </div></td><td width="10%"><p align="center">
          <input name="Submit" type="button" class="botones" onclick="move('remove','packagesource','packagetarget')" value=" &raquo; " />
        </p>
          <p align="center">
            <input name="Submit" type="button" class="botones" onclick="move('add','packagesource','packagetarget')" value=" &laquo; " />
        </p></td>
          <td width="40%">
            <div align="left">
              <select name="packagetarget[]" size="10" multiple="multiple" id="packagetarget" style="width:140px ">
                <!-- BEGIN DYNAMIC BLOCK: targetrowpackage -->
                <option value="{TARGETPACKAGEID}">{TARGETPACKAGE}</option>
                <!-- END DYNAMIC BLOCK: targetrowpackage -->
              </select>
          </div></td></tr>
  </table>
  </td>
  </tr>
  <tr>
    <td><input type="hidden" name="r_postdate" value="Post Date"/>
      <input name="r_title" type="hidden" id="r_title" value="Title"/>
      <input name="r_announcementstatus" type="hidden" id="r_announcementstatus" value="Status"/>
      <input name="r_post" type="hidden" id="r_post" value="Post"/>
      <input name="r_recipientType" type="hidden" id="r_recipientType" value="Recipients"/>
      <input type="submit" class="button_xlarge" value='{ANNOUNCEMENTBUTTON}' onclick="selAll('usertarget');selAll('servertarget');selAll('packagetarget');selAll('statustarget');check(addannouncement,addannouncement.elements.length);return false;" />
      <!-- BEGIN DYNAMIC BLOCK: announcementid -->
      <input name="id" type="hidden" id="id" value="{ANNOUNCEMENTID}"/>
      <!-- END DYNAMIC BLOCK: announcementid -->
      </td>
  </tr>
  <tr>
    <td>&nbsp;</td>
  </tr>
</table>
</form>
