Home >Backend Development >PHP Tutorial > flock() 参数的有关问题

flock() 参数的有关问题

WBOY
WBOYOriginal
2016-06-13 13:08:341173browse

flock() 参数的问题
flock 的三个参数的区别到底是什么??
  1.LOCK_SH
  2.LOCK_EX
  3.LOCK_UN

------解决方案--------------------
看这里:http://www.w3school.com.cn/php/func_filesystem_flock.asp
------解决方案--------------------
锁定是对于其他程序而言的,并不影响当前程序的操作

1.LOCK_SH 可读不可写
2.LOCK_EX 不可读不可写
3.LOCK_UN 可读可写(就是取消了锁定)

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn