PHP Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming LanguagesPHP Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old February 6th, 2000, 07:52 AM
Kai Kai is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2000
Posts: 3 Kai User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Hi itīs me again with a better decription:
the following script checks the size of a file, adds something to the file and then checks the filesize again.
The Problem: itīs both the same size, but this actualli canīt be. How do I get the real size after the adding?
See the error also at: http://www.seeagency.de/t.php3

$file = "test.txt";

$size=filesize($file);
echo $size."n<br>n";

$addtext="This text will be addes to the file!!n";

$open=fopen($file, "a");
fputs($open, $addtext);
fclose($open);

$size=filesize($file);
echo $size;

thanks a 1000 times,
Kai Seefeldt

Reply With Quote
  #2  
Old February 6th, 2000, 10:46 AM
Kai Kai is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2000
Posts: 3 Kai User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
I found the solution:
clearstatcache();
Thanks!

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesPHP Development > filesize() Problem: better description:


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 6 hosted by Hostway
Stay green...Green IT