简体   繁体   English

ACL编辑帖子页面?

[英]acl for edit post page?

i wonder if i shld use an ACL rule (PHP/ Zend_Acl in my case) for something as small as a edit post page? 我想知道我是否对诸如编辑帖子页面之类的东西使用ACL规则(在我的情况下为PHP / Zend_Acl )? i guess the criteria to allow users to edit a post will be 我想允许用户编辑帖子的标准是

  • owner of post 帖子所有者
  • editors/moderators/admin 编辑/版主/管理员

the question will be if yes (to use acl), how can i define it (i am using Zend_Acl but if u give me some code example, i might be able to translate it). 问题将是,如果是(使用acl),我如何定义它(我正在使用Zend_Acl但是如果您给我一些代码示例,我也许可以翻译它)。

acl's i think will generally be defined at application start/bootstrap. 我认为ACL通常会在应用程序启动/引导时定义。 in this case, its partially dynamic as in i must chk against the logged in user. 在这种情况下,必须像登录用户一样对它进行部分动态调整。

or will a simple if else suffice? 还是简单的就足够了?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM