Login   Register  
PHP Classes
elePHPant
Icontem

File: example.php

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Jaroslaw Miazga  >  Html Hidder  >  example.php  >  Download  
File: example.php
Role: Example script
Content type: text/plain
Description: Example of using this class
Class: Html Hidder
Obfuscate HTML using JavaScript
Author: By
Last change:
Date: 2010-08-05 13:51
Size: 521 bytes
 

Contents

Class file image Download
<?php
/* Example of using HtmlHidder by Jaroslaw Miazga */

require 'HtmlHidder.php';

/* Html code */
$htmlSource = <<<S
<div class="a">
     <div class="b">
         <h1>Somethink</h1>
         <br />
         <span>Some text....</span>
         <div class="c">
             <a href="#" title="ssss">Some link</a>
         </div>
     </div>
</div>
S;

$html = new HtmlHidder();
$html->setHtmlCode($htmlSource);

/* We are displaying hidded code in textarea - easy way to furthest copy */
echo '<textarea>'.$html->hide().'</textarea>';

?>