开发者

How do I use multiple entries with Zend_Config_Xml?

I am trying to use multiple entries with Zend_Config_XML, but no luck so far. I have the following structure.

<acl>
<admin>
    <access moudle="module1" controller="controller1" action="action1">
    <access moudle="module2" controller="controller2" action="action2">
    <access moudle="module3" controller="controller3" action="action3">
</admin>
<manager>
    <access moudle="module1" controller="controller1" action="action1">
    <access moudle="module2" controller="controller2" action="action2">
    <开发者_如何学编程access moudle="module3" controller="controller3" action="action3">
</manager>
</acl>

I can't even access to access entries.

Should I use other XML classes to use multiple entries?


I've never used XML configs with ZF but it looks like you have a typo in your XML - the attribute name should be module, not moudle.


The problem is that is not valid XML. You need to close the access tag:

<access moudle="module1" controller="controller1" action="action1" />

And as the other guy who's name I can't remember said, you have a typo in moudle.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜