<?php
include_once $_SERVER['DOCUMENT_ROOT'] . '/include/shared-manual.inc';
$TOC = array();
$TOC_DEPRECATED = array();
$PARENTS = array();
include_once dirname(__FILE__) ."/toc/migration74.inc";
$setup = array (
  'home' => 
  array (
    0 => 'index.php',
    1 => 'PHP Manual',
  ),
  'head' => 
  array (
    0 => 'UTF-8',
    1 => 'de',
  ),
  'this' => 
  array (
    0 => 'migration74.deprecated.php',
    1 => 'Veraltete Features',
    2 => 'Veraltete Features',
  ),
  'up' => 
  array (
    0 => 'migration74.php',
    1 => 'Migration von PHP 7.3.x auf PHP 7.4.x',
  ),
  'prev' => 
  array (
    0 => 'migration74.incompatible.php',
    1 => 'Nicht abw&auml;rtskompatible &Auml;nderungen',
  ),
  'next' => 
  array (
    0 => 'migration74.removed-extensions.php',
    1 => 'Entfernte Erweiterungen',
  ),
  'alternatives' => 
  array (
  ),
  'source' => 
  array (
    'lang' => 'de',
    'path' => 'appendices/migration74/deprecated.xml',
  ),
  'history' => 
  array (
  ),
);
$setup["toc"] = $TOC;
$setup["toc_deprecated"] = $TOC_DEPRECATED;
$setup["parents"] = $PARENTS;
manual_setup($setup);

contributors($setup);

?>
<div id="migration74.deprecated" class="sect1">
 <h2 class="title">Veraltete Features</h2>

 <div class="sect2" id="migration74.deprecated.core">
  <h3 class="title">PHP-Kern</h3>

  <div class="sect3" id="migration74.deprecated.core.nested-ternary">
   <h4 class="title">Verschachtelte ternäre Operatoren ohne explizite Klammern</h4>

   <p class="para">
    Verschachtelte ternäre Operationen müssen nun explizit Klammern verwenden,
    um die Reihenfolge der Operationen festzulegen. Wenn in der Vergangenheit
    keine Klammern verwendet wurden, führte die Links-Assoziativität in den
    meisten Fällen nicht zum erwarteten Verhalten.
    <div class="informalexample">
     <div class="example-contents">
<div class="phpcode"><code><span style="color: #000000"><span style="color: #0000BB">&lt;?php<br />1 </span><span style="color: #007700">? </span><span style="color: #0000BB">2 </span><span style="color: #007700">: </span><span style="color: #0000BB">3 </span><span style="color: #007700">? </span><span style="color: #0000BB">4 </span><span style="color: #007700">: </span><span style="color: #0000BB">5</span><span style="color: #007700">;   </span><span style="color: #FF8000">// veraltet<br /></span><span style="color: #007700">(</span><span style="color: #0000BB">1 </span><span style="color: #007700">? </span><span style="color: #0000BB">2 </span><span style="color: #007700">: </span><span style="color: #0000BB">3</span><span style="color: #007700">) ? </span><span style="color: #0000BB">4 </span><span style="color: #007700">: </span><span style="color: #0000BB">5</span><span style="color: #007700">; </span><span style="color: #FF8000">// OK<br /></span><span style="color: #0000BB">1 </span><span style="color: #007700">? </span><span style="color: #0000BB">2 </span><span style="color: #007700">: (</span><span style="color: #0000BB">3 </span><span style="color: #007700">? </span><span style="color: #0000BB">4 </span><span style="color: #007700">: </span><span style="color: #0000BB">5</span><span style="color: #007700">); </span><span style="color: #FF8000">// OK<br /></span><span style="color: #0000BB">?&gt;</span></span></code></div>
     </div>

    </div>
   </p>
   <p class="para">
    Klammern sind <em>nicht</em> erforderlich, wenn der mittlere
    Operand umschlossen wird, da dies immer eindeutig ist und nicht durch die
    Assoziativität beeinflusst wird:
    <div class="informalexample">
     <div class="example-contents">
<div class="phpcode"><code><span style="color: #000000">1 ? 2 ? 3 : 4 : 5 // OK</span></code></div>
     </div>

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

  <div class="sect3" id="migration74.deprecated.core.array-string-access-curly-brace">
   <h4 class="title">Zugriff auf Array- und Zeichenketten-Offset mit geschweiften Klammern</h4>

   <p class="para">
    Die Syntax für den Zugriff auf Array- und String-Offsets mit geschweiften
    Klammern ist veraltet. Statt <code class="literal">$var{$idx}</code> sollte
    <code class="literal">$var[$idx]</code> verwendet werden.
   </p>
  </div>

  <div class="sect3" id="migration74.deprecated.core.real">
   <h4 class="title">Die Typumwandlung (real) und die Funktion <span class="function"><a href="function.is-real.php" class="function">is_real()</a></span></h4>

   <p class="para">
    Die Typumwandlung <code class="literal">(real)</code> ist veraltet, stattdessen
    <code class="literal">(float)</code> verwendet werden.
   </p>
   <p class="para">
    Die Funktion <span class="function"><a href="function.is-real.php" class="function">is_real()</a></span> ist ebenfalls veraltet,
    stattdessen sollte <span class="function"><a href="function.is-float.php" class="function">is_float()</a></span> verwendet werden.
   </p>
  </div>

  <div class="sect3" id="migration74.deprecated.core.unbind-this">
   <h4 class="title">Aufhebung der Bindung von <code class="literal">$this</code>, wenn <code class="literal">$this</code> verwendet wird</h4>

   <p class="para">
    Die Bindung von <code class="literal">$this</code> an eine nicht-statische Closure
    aufzuheben, die <code class="literal">$this</code> verwendet, ist veraltet.
   </p>
  </div>

  <div class="sect3" id="migration74.deprecated.core.parent">
   <h4 class="title">Schlüsselwort <code class="literal">parent</code> ohne übergeordnete Klasse</h4>

   <p class="para">
    Die Verwendung von <code class="literal">parent</code> innerhalb einer Klasse ohne
    Elternklasse ist veraltet und wird in Zukunft einen Fehler bei der
    Kompilierung auslösen. Derzeit wird ein Fehler nur dann erzeugt, wenn zur
    Laufzeit auf die Elternklasse zugegriffen wird.
   </p>
  </div>

  <div class="sect3" id="migration74.deprecated.core.allow-url-include">
   <h4 class="title">INI-Option allow_url_include</h4>

   <p class="para">
    Die INI-Direktive
    <a href="filesystem.configuration.php#ini.allow-url-include" class="link">allow_url_include</a> ist
    veraltet. Wenn sie aktiviert ist, wird beim Start ein entsprechender
    Hinweis erzeugt.
   </p>
  </div>

  <div class="sect3" id="migration74.deprecated.core.invalid-base-characters">
   <h4 class="title">Ungültige Zeichen in Funktionen zur Umwandlung der Basis</h4>

   <p class="para">
    Die Übergabe unzulässiger Zeichen an die Funktionen
    <span class="function"><a href="function.base-convert.php" class="function">base_convert()</a></span>, <span class="function"><a href="function.bindec.php" class="function">bindec()</a></span>,
    <span class="function"><a href="function.octdec.php" class="function">octdec()</a></span> und <span class="function"><a href="function.hexdec.php" class="function">hexdec()</a></span> führt nun zu
    einem Hinweis auf eine veraltete Verwendung. Das Ergebnis wird so
    berechnet, als gäbe es das unzulässige Zeichen nicht. Führende und
    nachfolgende Leerzeichen sowie Präfixe wie 0x (je nach Zahlensystem) sind
    weiterhin zulässig.
   </p>
  </div>

  <div class="sect3" id="migration74.deprecated.core.array-key-exists-objects">
   <h4 class="title">Die Anwendung von <span class="function"><a href="function.array-key-exists.php" class="function">array_key_exists()</a></span> auf Objekte</h4>

   <p class="para">
    Die Anwendung der Funktion <span class="function"><a href="function.array-key-exists.php" class="function">array_key_exists()</a></span> auf
    Objekte ist veraltet. Stattdessen sollte entweder
    <span class="function"><a href="function.isset.php" class="function">isset()</a></span> oder <span class="function"><a href="function.property-exists.php" class="function">property_exists()</a></span>
    verwendet werden.
   </p>
  </div>

  <div class="sect3" id="migration74.deprecated.core.magic-quotes-functions">
   <h4 class="title">Funktionen für &quot;magische Anführungszeichen&quot; (Magic Quotes)</h4>

   <p class="para">
    Die Funktionen <span class="function"><a href="function.get-magic-quotes-gpc.php" class="function">get_magic_quotes_gpc()</a></span> und
    <span class="function"><a href="function.get-magic-quotes-runtime.php" class="function">get_magic_quotes_runtime()</a></span> sind veraltet. Sie geben
    immer <strong><code><a href="reserved.constants.php#constant.false">false</a></code></strong> zurück.
   </p>
  </div>

  <div class="sect3" id="migration74.deprecated.core.hebrevc">
   <h4 class="title">Die Funktion <span class="function"><a href="function.hebrevc.php" class="function">hebrevc()</a></span></h4>

   <p class="para">
    Die Funktion <span class="function"><a href="function.hebrevc.php" class="function">hebrevc()</a></span> ist veraltet. Sie kann durch
    <code class="literal">nl2br(hebrev($str))</code> ersetzt werden oder, besser, indem
    die Unterstützung von Unicode-RTL genutzt wird.
   </p>
  </div>

  <div class="sect3" id="migration74.deprecated.core.convert-cyr-string">
   <h4 class="title">Die Funktion <span class="function"><a href="function.convert-cyr-string.php" class="function">convert_cyr_string()</a></span></h4>

   <p class="para">
    Die Funktion <span class="function"><a href="function.convert-cyr-string.php" class="function">convert_cyr_string()</a></span> ist veraltet. Sie
    kann durch <span class="function"><strong>mb_convert_string()</strong></span>,
    <span class="function"><a href="function.iconv.php" class="function">iconv()</a></span> oder <span class="classname"><a href="class.uconverter.php" class="classname">UConverter</a></span> ersetzt
    werden.
   </p>
  </div>

  <div class="sect3" id="migration74.deprecated.core.money-format">
   <h4 class="title">Die Funktion <span class="function"><a href="function.money-format.php" class="function">money_format()</a></span></h4>

   <p class="para">
    Die Funktion <span class="function"><a href="function.money-format.php" class="function">money_format()</a></span> ist veraltet. Sie kann
    durch die Funktionalität der intl-Klasse
    <span class="classname"><a href="class.numberformatter.php" class="classname">NumberFormatter</a></span> ersetzt werden.
   </p>
  </div>

  <div class="sect3" id="migration74.deprecated.core.ezmlm-hash">
   <h4 class="title">Die Funktion <span class="function"><a href="function.ezmlm-hash.php" class="function">ezmlm_hash()</a></span></h4>

   <p class="para">
    Die Funktion <span class="function"><a href="function.ezmlm-hash.php" class="function">ezmlm_hash()</a></span> ist veraltet.
   </p>
  </div>

  <div class="sect3" id="migration74.deprecated.core.restore-include-path">
   <h4 class="title">Die Funktion <span class="function"><a href="function.restore-include-path.php" class="function">restore_include_path()</a></span></h4>

   <p class="para">
    Die Funktion <span class="function"><a href="function.restore-include-path.php" class="function">restore_include_path()</a></span> ist veraltet. Sie
    kann durch <code class="literal">ini_restore(&#039;include_path&#039;)</code> ersetzt werden.
   </p>
  </div>

  <div class="sect3" id="migration74.deprecated.core.implode-reverse-parameters">
   <h4 class="title">Reihenfolge der Parameter bei <span class="function"><a href="function.implode.php" class="function">implode()</a></span></h4>

   <p class="para">
    Die Übergabe von Parametern an die Funktion <span class="function"><a href="function.implode.php" class="function">implode()</a></span>
    in umgekehrter Reihenfolge ist veraltet, statt
    <code class="literal">implode($parts, $glue)</code> sollte
    <code class="literal">implode($glue, $parts)</code> verwendet werden.
   </p>
  </div>

 </div>

 <div class="sect2" id="migration74.deprecated.com">
  <h3 class="title">COM</h3>

  <p class="para">
   Der Import von Typbibliotheken, bei denen die Groß- und Kleinschreibung von
   Konstanten nicht beachtet wird, ist veraltet.
  </p>
 </div>

 <div class="sect2" id="migration74.deprecated.filter">
  <h3 class="title">Filter</h3>

  <p class="para">
   Der Filter <strong><code><a href="filter.constants.php#constant.filter-sanitize-magic-quotes">FILTER_SANITIZE_MAGIC_QUOTES</a></code></strong> ist veraltet,
   stattdessen sollte <strong><code><a href="filter.constants.php#constant.filter-sanitize-add-slashes">FILTER_SANITIZE_ADD_SLASHES</a></code></strong>
   verwendet werden.
  </p>
 </div>

 <div class="sect2" id="migration74.deprecated.mbstring">
  <h3 class="title">Multibyte-Zeichenketten</h3>

  <p class="para">
   Bei der Funktion <span class="function"><a href="function.mb-ereg-replace.php" class="function">mb_ereg_replace()</a></span> ist die Übergabe
   eines Musters, das keine Zeichenkette ist, veraltet. Gegenwärtig werden
   solche Muster als ASCII-Codepunkte interpretiert. In PHP 8 wird das Muster
   stattdessen als Zeichenkette interpretiert.
  </p>
  <p class="para">
   Bei der Funktion <span class="function"><a href="function.mb-strrpos.php" class="function">mb_strrpos()</a></span> ist die Übergabe der
   Kodierung als 3. Parameter veraltet. Stattdessen sollten ein 0-Offset und
   die Kodierung als 4. Parameter übergeben werden.
  </p>
 </div>

 <div class="sect2" id="migration74.deprecated.ldap">
  <h3 class="title">Lightweight Directory Access Protocol (LDAP)</h3>

  <p class="para">
   Die Funktionen <span class="function"><a href="function.ldap-control-paged-result-response.php" class="function">ldap_control_paged_result_response()</a></span> und
   <span class="function"><a href="function.ldap-control-paged-result.php" class="function">ldap_control_paged_result()</a></span> sind veraltet.
   Steuerelemente für die Seitennavigation können stattdessen zusammen mit
   <span class="function"><a href="function.ldap-search.php" class="function">ldap_search()</a></span> gesendet werden.
  </p>
 </div>

 <div class="sect2" id="migration74.deprecated.reflection">
  <h3 class="title">Reflection</h3>

  <p class="para">
   Der Aufruf von <span class="methodname"><a href="reflectiontype.tostring.php" class="methodname">ReflectionType::__toString()</a></span> erzeugt
   nun einen Hinweis auf eine veraltete Funktion. Diese Methode wird in der
   Dokumentation seit PHP 7.1 als veraltet zugunsten von
   <span class="methodname"><a href="reflectionnamedtype.getname.php" class="methodname">ReflectionNamedType::getName()</a></span> bezeichnet, hat aber
   aus technischen Gründen keinen entsprechenden Hinweis erzeugt.
  </p>
  <p class="para">
   Die <code class="literal">export()</code>-Methoden sind in allen Klassen von
   <span class="classname"><a href="class.reflection.php" class="classname">Reflection</a></span> veraltet. Stattdessen sollte ein
   <span class="classname"><a href="class.reflection.php" class="classname">Reflection</a></span>-Objekt erzeugt werden und dieses in eine
   Zeichenkette umgewandelt werden:
   <div class="informalexample">
     <div class="example-contents">
<div class="phpcode"><code><span style="color: #000000"><span style="color: #0000BB">&lt;?php<br /></span><span style="color: #FF8000">// Anstelle von ReflectionClass::export(Foo::class, false):<br /></span><span style="color: #007700">echo new </span><span style="color: #0000BB">ReflectionClass</span><span style="color: #007700">(</span><span style="color: #0000BB">Foo</span><span style="color: #007700">::class), </span><span style="color: #DD0000">"\n"</span><span style="color: #007700">;<br /><br /></span><span style="color: #FF8000">// Anstelle von $str = ReflectionClass::export(Foo::class, true):<br /></span><span style="color: #0000BB">$str </span><span style="color: #007700">= (string) new </span><span style="color: #0000BB">ReflectionClass</span><span style="color: #007700">(</span><span style="color: #0000BB">Foo</span><span style="color: #007700">::class);<br /></span><span style="color: #0000BB">?&gt;</span></span></code></div>
     </div>

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

 <div class="sect2" id="migration74.deprecated.socket">
  <h3 class="title">Socket</h3>

  <p class="para">
   Bei der Funktion <span class="function"><a href="function.socket-addrinfo-lookup.php" class="function">socket_addrinfo_lookup()</a></span> sind die Flags
   <strong><code>AI_IDN_ALLOW_UNASSIGNED</code></strong> und
   <strong><code>AI_IDN_USE_STD3_ASCII_RULES</code></strong> veraltet und entsprechen
   damit der zugrundeliegenden Glibc.
  </p>
 </div>

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