<?php
include_once $_SERVER['DOCUMENT_ROOT'] . '/include/shared-manual.inc';
$TOC = array();
$TOC_DEPRECATED = array();
$PARENTS = array();
include_once dirname(__FILE__) ."/toc/ref.imap.inc";
$setup = array (
  'home' => 
  array (
    0 => 'index.php',
    1 => 'PHP Manual',
  ),
  'head' => 
  array (
    0 => 'UTF-8',
    1 => 'de',
  ),
  'this' => 
  array (
    0 => 'function.imap-setflag-full.php',
    1 => 'imap_setflag_full',
    2 => 'Setzt Nachrichtenflags',
  ),
  'up' => 
  array (
    0 => 'ref.imap.php',
    1 => 'IMAP Funktionen',
  ),
  'prev' => 
  array (
    0 => 'function.imap-setacl.php',
    1 => 'imap_setacl',
  ),
  'next' => 
  array (
    0 => 'function.imap-sort.php',
    1 => 'imap_sort',
  ),
  'alternatives' => 
  array (
  ),
  'source' => 
  array (
    'lang' => 'de',
    'path' => 'reference/imap/functions/imap-setflag-full.xml',
  ),
  'history' => 
  array (
  ),
);
$setup["toc"] = $TOC;
$setup["toc_deprecated"] = $TOC_DEPRECATED;
$setup["parents"] = $PARENTS;
manual_setup($setup);

contributors($setup);

?>
<div id="function.imap-setflag-full" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">imap_setflag_full</h1>
  <p class="verinfo">(PHP 4, PHP 5, PHP 7, PHP 8)</p><p class="refpurpose"><span class="refname">imap_setflag_full</span> &mdash; <span class="dc-title">Setzt Nachrichtenflags</span></p>

 </div>

 <div class="refsect1 description" id="refsect1-function.imap-setflag-full-description">
  <h3 class="title">Beschreibung</h3>
  <div class="methodsynopsis dc-description">
   <span class="methodname"><strong>imap_setflag_full</strong></span>(<br>&nbsp;&nbsp;&nbsp;&nbsp;<span class="methodparam"><span class="type"><a href="class.imap-connection.php" class="type IMAP\Connection">IMAP\Connection</a></span> <code class="parameter">$imap</code></span>,<br>&nbsp;&nbsp;&nbsp;&nbsp;<span class="methodparam"><span class="type"><a href="language.types.string.php" class="type string">string</a></span> <code class="parameter">$sequence</code></span>,<br>&nbsp;&nbsp;&nbsp;&nbsp;<span class="methodparam"><span class="type"><a href="language.types.string.php" class="type string">string</a></span> <code class="parameter">$flag</code></span>,<br>&nbsp;&nbsp;&nbsp;&nbsp;<span class="methodparam"><span class="type"><a href="language.types.integer.php" class="type int">int</a></span> <code class="parameter">$options</code><span class="initializer"> = 0</span></span><br>): <span class="type"><a href="language.types.singleton.php" class="type true">true</a></span></div>

  <p class="para rdfs-comment">
   Setzt die mit <code class="parameter">flag</code> angegebenen Flags bei allen
   Nachrichten aus der Liste <code class="parameter">sequence</code>.
  </p>
 </div>


 <div class="refsect1 parameters" id="refsect1-function.imap-setflag-full-parameters">
  <h3 class="title">Parameter-Liste</h3>
  <p class="para">
   <dl>
    <dt>
<code class="parameter">imap</code></dt><dd><p class="para">Eine <span class="classname"><a href="class.imap-connection.php" class="classname">IMAP\Connection</a></span>-Instanz.</p></dd>
    
     <dt><code class="parameter">sequence</code></dt>
     <dd>
      <p class="para">
       Eine Liste von Nachrichtennummern. Sie können die gewünschten
       Nachrichten mit Komma getrennt aufzählen (<code class="literal">X,Y</code>) oder
       alle Nachrichten in einem bestimmten Intervall mit
       <code class="literal">X:Y</code> auswählen.
      </p>
     </dd>
    
    
     <dt><code class="parameter">flag</code></dt>
     <dd>
      <p class="para">
       Die möglichen Flags, die gesetzt werden können, sind
       <code class="literal">\Seen</code>, <code class="literal">\Answered</code>,
       <code class="literal">\Flagged</code>, <code class="literal">\Deleted</code> und
       <code class="literal">\Draft</code>, wie in
       <a href="https://datatracker.ietf.org/doc/html/rfc2060" class="link external">&raquo;&nbsp;RFC2060</a> definiert.
      </p>
     </dd>
    
    
     <dt><code class="parameter">options</code></dt>
     <dd>
      <p class="para">
       Eine Bitmaske mit Optionen, die zurzeit wird nur eine Option
       unterstützt:
       <ul class="itemizedlist">
        <li class="listitem">
         <span class="simpara">
          <strong><code><a href="imap.constants.php#constant.st-uid">ST_UID</a></code></strong> - Die Nachrichtenliste
          <code class="parameter">sequence</code> enthält UIDs anstelle von
          Nachrichtennummern.
         </span>
        </li>
       </ul>
      </p>
     </dd>
    
   </dl>
  </p>
 </div>


 <div class="refsect1 returnvalues" id="refsect1-function.imap-setflag-full-returnvalues">
  <h3 class="title">Rückgabewerte</h3>
  <p class="para">
   Gibt immer <strong><code><a href="reserved.constants.php#constant.true">true</a></code></strong> zurück.
  </p>
 </div>


 <div class="refsect1 errors" id="refsect1-function.imap-setflag-full-errors">
  <h3 class="title">Fehler/Exceptions</h3>
  <p class="para">
   Wenn <code class="parameter">options</code> ungültig ist, wird ein
   <span class="classname"><a href="class.valueerror.php" class="classname">ValueError</a></span> geworfen.
  </p>
 </div>


 <div class="refsect1 changelog" id="refsect1-function.imap-setflag-full-changelog">
  <h3 class="title">Changelog</h3>
  <table class="doctable informaltable">
   
    <thead>
     <tr>
      <th>Version</th>
      <th>Beschreibung</th>
     </tr>

    </thead>

    <tbody class="tbody">
     <tr>
 <td>8.1.0</td>
 <td>
  Der Parameter <code class="parameter">imap</code> erwartet nun eine
  <span class="classname"><a href="class.imap-connection.php" class="classname">IMAP\Connection</a></span>-Instanz; vorher wurde eine gültige
  <code class="literal">imap</code>-<a href="language.types.resource.php" class="link">Ressource</a> erwartet.
 </td>
</tr>

     <tr>
      <td>8.0.0</td>
      <td>
       Bei ungültigen Parameterwerten von <code class="parameter">options</code> wird
       nun ein <span class="classname"><a href="class.valueerror.php" class="classname">ValueError</a></span> geworfen; zuvor wurde eine
       Warnung ausgegeben und die Funktion gab <strong><code><a href="reserved.constants.php#constant.false">false</a></code></strong> zurück.
      </td>
     </tr>

    </tbody>
   
  </table>

 </div>


 <div class="refsect1 examples" id="refsect1-function.imap-setflag-full-examples">
  <h3 class="title">Beispiele</h3>
  <p class="para">
   <div class="example" id="example-1">
    <p><strong>Beispiel #1 <span class="function"><strong>imap_setflag_full()</strong></span>-Beispiel</strong></p>
    <div class="example-contents">
<div class="phpcode"><code><span style="color: #000000"><span style="color: #0000BB">&lt;?php<br />$mbox </span><span style="color: #007700">= </span><span style="color: #0000BB">imap_open</span><span style="color: #007700">(</span><span style="color: #DD0000">"{imap.example.org:143}"</span><span style="color: #007700">, </span><span style="color: #DD0000">"username"</span><span style="color: #007700">, </span><span style="color: #DD0000">"password"</span><span style="color: #007700">)<br />     or die(</span><span style="color: #DD0000">"Kann keine Verbindung aufbauen: " </span><span style="color: #007700">. </span><span style="color: #0000BB">imap_last_error</span><span style="color: #007700">());<br /><br /></span><span style="color: #0000BB">$status </span><span style="color: #007700">= </span><span style="color: #0000BB">imap_setflag_full</span><span style="color: #007700">(</span><span style="color: #0000BB">$mbox</span><span style="color: #007700">, </span><span style="color: #DD0000">"2,5"</span><span style="color: #007700">, </span><span style="color: #DD0000">"\\Seen \\Flagged"</span><span style="color: #007700">);<br /><br />echo </span><span style="color: #0000BB">gettype</span><span style="color: #007700">(</span><span style="color: #0000BB">$status</span><span style="color: #007700">) . </span><span style="color: #DD0000">"\n"</span><span style="color: #007700">;<br />echo </span><span style="color: #0000BB">$status </span><span style="color: #007700">. </span><span style="color: #DD0000">"\n"</span><span style="color: #007700">;<br /><br /></span><span style="color: #0000BB">imap_close</span><span style="color: #007700">(</span><span style="color: #0000BB">$mbox</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">?&gt;</span></span></code></div>
    </div>

   </div>
  </p>
 </div>


 <div class="refsect1 seealso" id="refsect1-function.imap-setflag-full-seealso">
  <h3 class="title">Siehe auch</h3>
  <p class="para">
   <ul class="simplelist">
    <li><span class="function"><a href="function.imap-clearflag-full.php" class="function" rel="rdfs-seeAlso">imap_clearflag_full()</a> - L&ouml;scht die Flags einer Nachricht</span></li>
   </ul>
  </p>
 </div>


</div><?php manual_footer($setup); ?>