PHP Classes

File: ex4.php

Recommend this page to a friend!
  Classes of Marcos Bezerra   Web Open Patch   ex4.php   Download  
File: ex4.php
Role: Example script
Content type: text/plain
Description: Example #4: Anti-XSS Injection
Class: Web Open Patch
Filter values to prevent security exploits
Author: By
Last change:
Date: 14 years ago
Size: 301 bytes
 

Contents

Class file image Download
<?php

include_once("WebOpenPatch.php");

$wop = new WebOpenPatch();

$wop->wopAntiXssInjection('nome', $_POST['nome']);
$wop->wopAntiXssInjection('comentario', $_POST['comentario']);

$saida = $wop->getOutput();

echo
"Nome: {$saida['nome']}<br />Comentário: {$saida['comentario']}";

?>