[ Index ]
 

Code source de IMP H3 (4.1.5)

Accédez au Source d'autres logiciels libres

Classes | Fonctions | Variables | Constantes | Tables

title

Body

[fermer]

/templates/compose/ -> redirect.inc (source)

   1  <script type="text/javascript">
   2  <!--
   3  function confirmCancel()
   4  {
   5      if (window.confirm('<?php echo addslashes(_("Cancelling this message will permanently discard its contents.")) . '\n' . addslashes(_("Are you sure you want to do this?")) ?>')) {
   6          <?php echo $cancel_js ?>
   7      }
   8  }
   9  
  10  function redirectSubmit()
  11  {
  12      if (document.redirect.to.value == '') {
  13          alert('<?php echo addslashes(_("You must specify a recipient.")) ?>');
  14          document.redirect.to.focus();
  15          return false;
  16      }
  17  
  18      return true;
  19  }
  20  
  21  function uniqSubmit()
  22  {
  23      now = new Date();
  24      document.redirect.submitBtn.disabled = true;
  25      document.redirect.cancelBtn.disabled = true;
  26      if (document.redirect.style && document.redirect.style.cursor) {
  27          document.redirect.style.cursor = "wait";
  28      }
  29      document.redirect.submit();
  30  }
  31  //-->
  32  </script>
  33  
  34  <form method="post" action="<?php echo Util::addParameter(Horde::url('compose.php'), 'uniq', base_convert(microtime(), 10, 36)) ?>" name="redirect">
  35  <input type="hidden" name="mailbox" value="<?php echo htmlspecialchars($mailbox) ?>" />
  36  <input type="hidden" name="index" value="<?php echo htmlspecialchars($index) ?>" />
  37  <input type="hidden" name="actionID" value="redirect_send" />
  38  
  39  <?php echo IMP::status(); $tabindex = 0; ?>
  40  
  41  <h1 class="header">
  42    <?php echo htmlspecialchars($title) ?>
  43  </h1>
  44  <table width="100%" border="0" cellpadding="0" cellspacing="0">
  45  <?php if ($GLOBALS['registry']->hasMethod('contacts/search')): ?>
  46  <?php $contacts_url = Util::addParameter(Horde::applicationUrl('contacts.php'), array('formname' => 'redirect', 'to_only' => 1)); ?>
  47  <tr>
  48    <td>&nbsp;</td>
  49    <td class="item">
  50      <table cellspacing="0" width="100%">
  51        <tr>
  52          <td align="center"><?php echo Horde::link('#', _("Address Book"), 'widget', null, 'window.open(\'' . $contacts_url . '\', \'contacts\', \'toolbar=no,location=no,status=no,scrollbars=yes,resizable=yes,width=550,height=300,left=100,top=100\'); return false;') . Horde::img('addressbook_browse.png') . '<br />' . _("Address Book") . '</a>' ?></td>
  53          <td align="center"><?php echo Horde::link('#', _("Expand Names"), 'widget', null, "document.redirect.actionID.value='redirect_expand_addr'; uniqSubmit(); return false;") . Horde::img('expand.png') . '<br />' . _("Expand Names") . '</a>' ?></td>
  54        </tr>
  55      </table>
  56    </td>
  57  </tr>
  58  <?php endif; ?>
  59  
  60  <tr>
  61    <td class="light rightAlign" valign="middle"><strong><?php echo Horde::label('to', _("To")) ?>&nbsp;</strong></td>
  62    <td class="item leftAlign">
  63        <table border="0" width="100%" cellpadding="0">
  64  <?php if (is_array($header['to'])): $first_to = true; ?>
  65  <?php foreach ($header['to'] as $to_item): ?>
  66          <tr>
  67  <?php if (count($to_item) > 1): ?>
  68            <td class="leftAlign">
  69              <table border="0" cellspacing="0" cellpadding="0">
  70                <tr>
  71                  <td width="350">
  72                    <select id="to" tabindex="<?php echo $tabindex++ ?>" name="to_list[<?php echo htmlspecialchars($to_item[0]) ?>]" style="width:350px">
  73                      <option value="" selected="selected"><?php echo _("Please select or edit in the box to the right:") ?></option>
  74  <?php for ($i = 1; $i < count($to_item); $i++): ?>
  75                      <option value="<?php echo htmlspecialchars($to_item[$i]) ?>"><?php echo htmlspecialchars($to_item[$i]) ?></option>
  76  <?php endfor; ?>
  77                    </select>
  78                  </td>
  79                  <td width="150">
  80                    <input type="text" size="15" tabindex="<?php echo $tabindex++ ?>" class="fixed" name="to_field[<?php echo htmlspecialchars($to_item[0]) ?>]" value="<?php echo htmlspecialchars($to_item[0]) ?>" style="width:150px" />
  81                  </td>
  82                </tr>
  83              </table>
  84            </td>
  85  <?php else: ?>
  86            <td class="leftAlign"><input type="text" id="to" size="55" tabindex="<?php echo $tabindex++ ?>" class="fixed" name="to_field[]" value="<?php echo htmlspecialchars($to_item) ?>" /></td>
  87  <?php endif; ?>
  88  <?php if ($first_to): $first_to = false; ?>
  89            <td class="rightAlign"><?php echo Help::link('imp', 'compose-to') ?>&nbsp;</td>
  90  <?php else: ?>
  91            <td>&nbsp;</td>
  92  <?php endif; ?>
  93          </tr>
  94  <?php endforeach; ?>
  95          <tr>
  96            <td class="leftAlign"><input type="text" id="to" size="55" tabindex="<?php echo $tabindex++ ?>" class="fixed" name="to_new" /></td>
  97            <td>&nbsp;</td>
  98          </tr>
  99  <?php else: ?>
 100          <tr>
 101            <td class="leftAlign"><input type="text" id="to" size="55" tabindex="<?php echo $tabindex++ ?>" class="fixed" name="to" value="<?php echo htmlspecialchars($header['to']) ?>" <?php echo ($browser->hasFeature('iframes')) ? 'onchange="expandField(this)" /><span id="expandingto" class="inProgress" style="visibility:hidden;">' . _("Expanding") . '&hellip;</span>' : '/>'; ?></td>
 102            <td class="rightAlign"><?php echo Help::link('imp', 'compose-to') ?>&nbsp;</td>
 103          </tr>
 104  <?php endif; ?>
 105        </table>
 106      </td>
 107    </tr><tr>
 108      <td>&nbsp;</td>
 109      <td>
 110        <input name="submitBtn" type="submit" class="button" onclick="return redirectSubmit();" value="<?php echo _("Redirect Message") ?>" />
 111        <input name="cancelBtn" type="button" class="button" onclick="confirmCancel();" value="<?php echo _("Cancel Message") ?>" />
 112      </td>
 113    </tr>
 114  </table>
 115  </form>
 116  
 117  <br />
 118  
 119  <?php if ($browser->hasFeature('javascript')): ?>
 120  <script type="text/javascript">
 121  <!--
 122  
 123  document.redirect.to.focus();
 124  
 125  //-->
 126  </script>
 127  <?php endif; ?>
 128  
 129  <?php if ($GLOBALS['prefs']->getValue('auto_expand')): ?>
 130  <iframe id="autoexpand" name="autoexpand" style="width:0px;height:0px;border-width:0px" src="<?php echo Horde::applicationUrl('expand.php') ?>"></iframe>
 131  <?php endif; ?>


Généré le : Thu Nov 29 12:30:07 2007 par Balluche grâce à PHPXref 0.7
  Clicky Web Analytics