ACL进行编辑后页面? [英] acl for edit post page?

查看:376
本文介绍了ACL进行编辑后页面?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我不知道是否SHLD使用ACL规则(PHP / Zend_Acl里在我的情况)的小东西作为一个编辑后页面?我猜的标准,以允许用户编辑后会

i wonder if i shld use an ACL rule (PHP/Zend_Acl in my case) for something as small as a edit post page? i guess the criteria to allow users to edit a post will be


  • 后的所有者

  • 编辑/版主/管理员

问题将是,如果是(使用ACL),我怎么能定义它(我使用 Zend_Acl里,但如果你给我一些code例如,我也许能翻译它)。

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的,我认为一般会在应用程序启动/引导来定义。在这种情况下,其部分地动态如在我必须清洁香港针对登录用户。

acl's i think will generally be defined at application start/bootstrap. in this case, its partially dynamic as in i must chk against the logged in user.

或将一个简单的if else足够?

or will a simple if else suffice?

推荐答案

我认为它称为断言

  • Dynamic Assertions in Zend Framework
  • Docs: Assertions

这篇关于ACL进行编辑后页面?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆