Delphi For PHP Forums       


Go Back   Delphi-PHP Forums > Delphi4PHP NNTP Newsgroups > embarcadero.public.delphiphp.vclforphp.components.using
Forum Jump Register FAQ Members List Downloads Search Today's Posts Mark Forums Read

embarcadero.public.delphiphp.vclforphp.components.using This group is for all discussion about the use of VCL for PHP components.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 7th October 2008, 10:34
Erol YILDIZ
Guest
 
Posts: n/a
Default ZAcl component problem

I have a page with a ZAcl, Combobox and a DBRepeator components. I added an OnChange function to the Combobox component but when I run it and change the selected item of the combobox I have this error: *Application raised an exception class Zend_Acl_Exception with message 'Resource 'ComboBox::ComboBox1' not found'
Click for detailed information*

The code of the page is below. Is there something I am missing?

Thanks
--
Erol

<?php
require_once("vcl/vcl.inc.php");
//Includes
require_once("dmAuth.php");
use_unit("dbctrls.inc.php");
use_unit("Zend/zacl.inc.php");
use_unit("Zend/zauth.inc.php");
use_unit("forms.inc.php");
use_unit("extctrls.inc.php");
use_unit("stdctrls.inc.php");

global $dmAuth;
$dmAuth->ZAuth->Execute();

$aclmanager->Role=$dmAuth->ZAuth->UserRealm;

//Class definition
class ZAuthSample extends Page
{
public $ComboBox1 = null;
public $DBRepeater1 = null;
public $logout = null;
public $ZACL1 = null;
function ComboBox1Change($sender, $params)
{
//

}


}

global $application;

global $ZAuthSample;

//Creates the form
$ZAuthSample = new ZAuthSample($application);

//Read from resource file
$ZAuthSample->loadResource(__FILE__);

//Shows the form
$ZAuthSample->show();

?>

Edited by: Erol YILDIZ on Oct 7, 2008 2:33 AM
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 12th October 2008, 11:10
Erol YILDIZ
Guest
 
Posts: n/a
Default Re: ZAcl component problem

I found out that this problem happens if the page is submitted by any component and if you only use 'Custom:*:*' rule in the ZAcl rules. Combobox onChange submits the page too so I get this error. If you individualy add components to the ZAcl rules it doesn't give this error. For example when I add Control:ComboBox:ComboBox1:Show:Allow it doesn't give any error. So I guess 'Custom:*:*' rule have a problem.

--
Erol

> {quote:title=Erol YILDIZ wrote:}{quote}
> I have a page with a ZAcl, Combobox and a DBRepeator components. I added an OnChange function to the Combobox component but when I run it and change the selected item of the combobox I have this error: *Application raised an exception class Zend_Acl_Exception with message 'Resource 'ComboBox::ComboBox1' not found'
> Click for detailed information*
>
> The code of the page is below. Is there something I am missing?
>
> Thanks
> --
> Erol
>
> <?php
> require_once("vcl/vcl.inc.php");
> //Includes
> require_once("dmAuth.php");
> use_unit("dbctrls.inc.php");
> use_unit("Zend/zacl.inc.php");
> use_unit("Zend/zauth.inc.php");
> use_unit("forms.inc.php");
> use_unit("extctrls.inc.php");
> use_unit("stdctrls.inc.php");
>
> global $dmAuth;
> $dmAuth->ZAuth->Execute();
>
> $aclmanager->Role=$dmAuth->ZAuth->UserRealm;
>
> //Class definition
> class ZAuthSample extends Page
> {
> public $ComboBox1 = null;
> public $DBRepeater1 = null;
> public $logout = null;
> public $ZACL1 = null;
> function ComboBox1Change($sender, $params)
> {
> //
>
> }
>
>
> }
>
> global $application;
>
> global $ZAuthSample;
>
> //Creates the form
> $ZAuthSample = new ZAuthSample($application);
>
> //Read from resource file
> $ZAuthSample->loadResource(__FILE__);
>
> //Shows the form
> $ZAuthSample->show();
>
> ?>
>
> Edited by: Erol YILDIZ on Oct 7, 2008 2:33 AM


Edited by: Erol YILDIZ on Oct 12, 2008 3:08 AM

Edited by: Erol YILDIZ on Oct 12, 2008 3:09 AM
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
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

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


All times are GMT +1. The time now is 16:29.




Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0 ©2009, Crawlability, Inc.
Copyright © 2004 - 2009, G&J Solutions Ltd. All Rights Reserved. terms of use