Garayed.com  

Go Back   Garayed.com > PHP
FAQ Members List Calendar Search Today's Posts Mark Forums Read


Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 05-04-2006, 05:59 PM
abrtlt@yahoo.com
 
Posts: n/a
Default PHP instances writing to the same file?

I read in Programming PHP (O'Reilly) that flock() "cannot prevent two
PHP scripts running in the same web server process from accessing a
file at the same time".
In my case a single PHP script appends text strings to an existing text
file. Several clients may trigger the same script on the same web page
and thus more than one PHP instance might try to open and append text
to the same file at the same time. I would assume that using flock()
_does_ in fact prevent simultaneous access in this case. Am I correct?
Thanks!

Andrew

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT. The time now is 09:23 AM.




LinkBacks Enabled by vBSEO 3.0.0 © 2007, Crawlability, Inc.