Permissions for a new module

Author Message

Vincent Basset

Thursday 19 February 2004 1:57:50 am

Hi all,

I can't manage to write access permissions to my module.
For now, I need to be logged into eZpublish to access the url, otherwise eZ asks me to log in.

Here is my extension/php/modules/catapub/module.php file :

<?php
$Module = array( "name" => "catapub" );
$ViewList = array();
$ViewList["recherche"] = array(
"script" => "catapub_recherche.php",
"functions" => array( 'read' ),
'params' => array() );
$FunctionList['read'] = array( );
?>

I didn't find documentation on how the 'read' permission should be written ????
I'd like to let anyone (anonymous user) access this module (this is a search module)

Thanks for help
Vince

Bård Farstad

Thursday 19 February 2004 2:04:25 am

In your example you've already defined read permission for your module. You will need to add this policy for the anonymous user. This is done in the role edit interface in admin. It will be available under yourmodule/read automatically after you've defined it in $FunctionList['read'] = array( );

--bård

Documentation: http://ez.no/doc

Vincent Basset

Thursday 19 February 2004 3:03:50 am

thanks a lot, I didn't realized that my module appeared in the admin interface...

It works, It's alive !!! :D

ps : is there any documentation on $ViewList ? (the different parameters, the values, etc..)

pps : idem for the $FunctionList ???

thx
Vince :)

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 31 2025 06:02:20
Script start
Timing: Jan 31 2025 06:02:20
Module start 'layout'
Timing: Jan 31 2025 06:02:20
Module start 'content'
Timing: Jan 31 2025 06:02:20
Module end 'content'
Timing: Jan 31 2025 06:02:20
Script end

Main resources:

Total runtime0.0226 sec
Peak memory usage2,048.0000 KB
Database Queries3

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0066 588.1328151.2109
Module start 'layout' 0.00660.0028 739.343836.6484
Module start 'content' 0.00940.0115 775.992290.1406
Module end 'content' 0.02090.0017 866.132833.9922
Script end 0.0226  900.1250 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.002812.5070140.0002
Check MTime0.00135.7875140.0001
Mysql Total
Database connection0.00062.636810.0006
Mysqli_queries0.003314.583630.0011
Looping result0.00000.088510.0000
Template Total0.00135.810.0013
Template load0.00104.456510.0010
Template processing0.00031.280510.0003
Override
Cache load0.00083.339210.0008
General
dbfile0.003716.270580.0005
String conversion0.00000.044240.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0004 secs