freshman2017
Goto Top

WordPress Plugin - Programmierung

Guten Tag liebe Gemeinde,
hat jemand ein Tipp bei der Entwicklung von WordPress Plugins?
Ich habe ein kleines Plugin erstellt, und bei WordPress im Store eingereicht.
Ich bekomme nachfolgende Rückmeldung:

$pw is not escaped:

authenticator.php:116: <textarea id="input" rows="1" cols="65" readonly="readonly"><?php echo ("$pw")</textarea>  

Was kann das heissen? Is Not escaped?

Content-Key: 3280806584

Url: https://administrator.de/contentid/3280806584

Printed on: April 18, 2024 at 20:04 o'clock

Member: colinardo
colinardo Jul 07, 2022 updated at 17:38:37 (UTC)
Goto Top
Servus.
Was kann das heissen? Is Not escaped?
Das du dich nicht an die üblichen HTML Gepflogenheiten gehalten und html special chars innerhalb eine textarea nicht nach Vorschrift escaped hast ...
Escaping for textarea values
https://www.php.net/manual/de/function.htmlspecialchars.php

Des weiteren hast du das PHP End-Tag ?> vergessen.

<textarea id="input" rows="1" cols="65" readonly="readonly"><?php echo esc_textarea($pw); ?></textarea>  
Grüße Uwe