★ wanayoo — archive 1999 http://www.php.net/manual/function.fgetss.phpNouvelle recherche | Portail wanayoo

PHP Home Page

Manual Table of Contents
Up to Filesystem
Quick Reference
German version of this pageJapanese version of this pageItalian version of this pageFrench version of this pageHungarian version of this page
Filesystem
* basename
* chgrp
* chmod
* chown
* clearstatcache
* copy
* delete
* dirname
* diskfreespace
* fclose
* feof
* fgetc
* fgetcsv
* fgets
* fgetss
* file
* file_exists
* fileatime
* filectime
* filegroup
* fileinode
* filemtime
* fileowner
* fileperms
* filesize
* filetype
* flock
* fopen
* fpassthru
* fputs
* fread
* fscanf
* fseek
* fstat
* ftell
* ftruncate
* fwrite
* set_file_buffer
* is_dir
* is_executable
* is_file
* is_link
* is_readable
* is_writeable
* link
* linkinfo
* mkdir
* pclose
* popen
* readfile
* readlink
* rename
* rewind
* rmdir
* stat
* lstat
* realpath
* symlink
* tempnam
* touch
* umask
* unlink
Manual: fgetss
View the source code for this pageSearch the site



Previous page
 fgets
 Updated
Sat, 12 Aug 2000
file 
Next page


fgetss

(PHP3 , PHP4 )

fgetss --  Get line from file pointer and strip HTML tags

Description

string fgetss (int fp, int length [, string allowable_tags])

Identical to fgets(), except that fgetss attempts to strip any HTML and PHP tags from the text it reads.

You can use the optional third parameter to specify tags which should not be stripped.

Note: allowable_tags was added in PHP 3.0.13, PHP4B3.

See also fgets(), fopen(), fsockopen(), popen(), and strip_tags().


User Contributed Notes: fgetss


dragonzap1@aol.com
29-Jun-2000 10:32
fgetss() doesn't quite work right on HTML files with tags spanning more than one line. I'm assuming that this is because it only takes the file one line at a time. If you want to strip all HTML tags from a file, use $file_text = strip_tags(join('',file($filename))) instead. (You may also wish to split()/explode() it by "\n" after.)


 About Notes


Previous page
 fgets
 Updated
Sat, 12 Aug 2000
file 
Next page





Who's responsible for this?
Top of this page

Site
Hosting:



Located in
United States
Elements of this website are subject to copyright.
Questions about installing or using PHP should be directed to one of the mailing lists.
Only questions about the website should be directed to webmaster@php.net.