fgetss Gets line from file pointer and strip HTML tags : HTML File : HTML PHP Source Code


PHP Source Code » HTML » HTML File »

 

fgetss Gets line from file pointer and strip HTML tags



<?php

   $tags = "<h2><h3><p><b><a><img>";

   $fh = fopen("demo.htm""rt");
   while (!feof($fh)) {
      $article .= fgetss($fh, 1024, $tags);
   }
   fclose($fh);

   /* Open the file up in write mode and write $article contents. */
   $fh = fopen("demo.html""wt");
   fwrite($fh, $article);
   fclose($fh);
   
   echo $article;
?>


<!--
<html>

<body>
body

<p>paragraph</p>

</body>

</html>
-->

           
       



HTML code for linking to this page:

Follow Navioo On Twitter

PHP Source Code

 Navioo HTML
» HTML File