X-Git-Url: https://jasonwoof.com/gitweb/?p=ckeditor.git;a=blobdiff_plain;f=samples%2Fassets%2Fposteddata.php;h=dcef922786ada01d1bf6b9c0ac67c8759998d977;hp=8ec398bd4291241f808cffc655f955bae28dea29;hb=3ae1f974ffdf269f96455a39d8d6947e4d590b1b;hpb=860af3c4bde9866c53d5123c57e3dc6166e0fe1e diff --git a/samples/assets/posteddata.php b/samples/assets/posteddata.php index 8ec398b..dcef922 100644 --- a/samples/assets/posteddata.php +++ b/samples/assets/posteddata.php @@ -25,24 +25,24 @@ For licensing, see LICENSE.html or http://ckeditor.com/license $value ) +if (!empty($_POST)) { - if ( get_magic_quotes_gpc() ) - $postedValue = htmlspecialchars( stripslashes( $value ) ) ; - else - $postedValue = htmlspecialchars( $value ) ; + foreach ( $_POST as $key => $value ) + { + if ( ( !is_string($value) && !is_numeric($value) ) || !is_string($key) ) + continue; + if ( get_magic_quotes_gpc() ) + $value = htmlspecialchars( stripslashes((string)$value) ); + else + $value = htmlspecialchars( (string)$value ); ?> - -
+ +