Forums / Developer / set a policy to hide a node from anonymouse useres is also hidden from admin

set a policy to hide a node from anonymouse useres is also hidden from admin

Author Message

Romeo Antony

Friday 23 July 2010 7:29:38 am

I have set a user policy in roles for anonymous users to do not see a node(hide ) like this

module: content

function hide

subtree (archive).

Why this user policy also hide node( archive) from administer also .

Y it is not working. Y this is node not visible to administator. can anyone please help me. Romeo

     

Peter Keung

Friday 23 July 2010 7:56:38 am

That policy only controls whether a user can hide or unhide a node.

The ShowHiddenNodes setting in site.ini controls whether any user can see a hidden node for the entire siteaccess (provided that they also have the appropriate content/read permissions):

http://ez.no/doc/ez_publish/technical_manual/4_x/reference/configuration_files/site_ini/siteaccesssettings/showhiddennodes

http://www.mugo.ca
Mugo Web, eZ Partner in Vancouver, Canada

Romeo Antony

Friday 23 July 2010 8:05:23 am

Hi peter, thanks you for your reply. I have read through the topic you given.

I am a new guy to ez. please correct me if I am wrong.I will explain my idea .

I want to hide a node from anonymouse user at the same time it will be visible to an administator or an editor.

For that what I did is all the users can read(by seeting policies) this node (say this node is archive).

But i have set an other policy only for anonymous users to hide this node(archive).

So that this node will not be visible to anonymouse users. I understand hide and unhide property set for entire site access. But can it be in users prospective like what I said. Can u give me any suggestion. I am stuck at this point . Romeo

Peter Keung

Friday 23 July 2010 8:54:19 am

Hide/unhide are typically not applied on a per-user or per-user-group basis. Sounds like sections are more suitable, not hide/unhide. These articles should provide the necessary background:

http://share.ez.no/articles/ez-publish/section-segmentation-and-user-permissions-part-1-of-2

http://share.ez.no/articles/ez-publish/section-segmentation-and-user-permissions-part-2-of-2

http://www.mugo.ca
Mugo Web, eZ Partner in Vancouver, Canada

Romeo Antony

Friday 23 July 2010 9:15:49 am

Thanks a lot Peter.I will try it. Now I am reading through the article that you wrote. http://share.ez.no/articles/ez-publish/node-visibility-hiding-and-revealing-content/%28page%29/4

Romeo Antony

Friday 23 July 2010 5:08:51 pm

Hi Peter, I have read through your artciles about node visibilty,user permission part1 and part2 from ez site.

But now I am stuck to set this user policy. Because I can't find a way to achieve thisthe following .Please help me Peter.

I have a folder called (2010) in topmenu. In this 2010 folder I have put 12 folders(these 12 folders are months )

Also I have 3 frontpage top menus.

site works like this. I am putting articles in folder 2010/month_folders.(suppose this month I will put articles in2010/july)

Then I am adding(referring) articles from this 2010/month_folders to 3frontpages (topmenus).

so all contents only will be in 2010/months folders.

I have put all 3 frontpage topmenus in standard section and 2010 folder in a new section called archive.

I do not want to show the 2010 node(archive section) to anonymouse users , but also need to search on the contents present in the 2010 node(archive section). This 2010 folder(archive section) should be visible to administator also.

I am completly loss at this point where I should grant read access to standard section and archival section for anonymous users for searching. Then how can I completly hide this 2010 folder(archival section) from anonymouse users and visible to administator.

Anyidea will be really helpfull.

I hope you may be able to help me with the information provided Peter.

Romeo.

eZ debug

Timing: Jan 19 2025 00:14:57
Script start
Timing: Jan 19 2025 00:14:57
Module start 'content'
Warning: PHP: E_DEPRECATED Jan 19 2025 00:14:57
trim(): Passing null to parameter #1 ($string) of type string is deprecated in /home/ze/public_html/share.se7enx.com/var/community/cache/template/compiled/table-c0a31fef795ad927ef08940ddf2d392f.php on line 147
Timing: Jan 19 2025 00:14:58
Module end 'content'
Timing: Jan 19 2025 00:14:58
Script end

Main resources:

Total runtime0.8869 sec
Peak memory usage4,096.0000 KB
Database Queries203

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0084 589.2266180.7813
Module start 'content' 0.00840.7402 770.0078592.3281
Module end 'content' 0.74860.1382 1,362.3359341.5469
Script end 0.8868  1,703.8828 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00420.4786210.0002
Check MTime0.00150.1691210.0001
Mysql Total
Database connection0.00090.097410.0009
Mysqli_queries0.786388.66442030.0039
Looping result0.00230.25792010.0000
Template Total0.857496.720.4287
Template load0.00220.246120.0011
Template processing0.855296.428020.4276
Template load and register function0.00010.012610.0001
states
state_id_array0.00120.131710.0012
state_identifier_array0.00110.119220.0005
Override
Cache load0.00190.2197520.0000
Sytem overhead
Fetch class attribute can translate value0.00110.127030.0004
Fetch class attribute name0.00100.116680.0001
XML
Image XML parsing0.00300.342530.0010
class_abstraction
Instantiating content class attribute0.00000.0042120.0000
General
dbfile0.00670.7516340.0002
String conversion0.00000.000830.0000
Note: percentages do not add up to 100% because some accumulators overlap

CSS/JS files loaded with "ezjscPacker" during request:

CacheTypePacklevelSourceFiles
CSS0extension/community/design/community/stylesheets/ext/jquery.autocomplete.css
extension/community_design/design/suncana/stylesheets/scrollbars.css
extension/community_design/design/suncana/stylesheets/tabs.css
extension/community_design/design/suncana/stylesheets/roadmap.css
extension/community_design/design/suncana/stylesheets/content.css
extension/community_design/design/suncana/stylesheets/star-rating.css
extension/community_design/design/suncana/stylesheets/syntax_and_custom_tags.css
extension/community_design/design/suncana/stylesheets/buttons.css
extension/community_design/design/suncana/stylesheets/tweetbox.css
extension/community_design/design/suncana/stylesheets/jquery.fancybox-1.3.4.css
extension/bcsmoothgallery/design/standard/stylesheets/magnific-popup.css
extension/sevenx/design/simple/stylesheets/star_rating.css
extension/sevenx/design/simple/stylesheets/libs/fontawesome/css/all.min.css
extension/sevenx/design/simple/stylesheets/main.v02.css
extension/sevenx/design/simple/stylesheets/main.v02.res.css
JS0extension/ezjscore/design/standard/lib/yui/3.17.2/build/yui/yui-min.js
extension/ezjscore/design/standard/javascript/jquery-3.7.0.min.js
extension/community_design/design/suncana/javascript/jquery.ui.core.min.js
extension/community_design/design/suncana/javascript/jquery.ui.widget.min.js
extension/community_design/design/suncana/javascript/jquery.easing.1.3.js
extension/community_design/design/suncana/javascript/jquery.ui.tabs.js
extension/community_design/design/suncana/javascript/jquery.hoverIntent.min.js
extension/community_design/design/suncana/javascript/jquery.popmenu.js
extension/community_design/design/suncana/javascript/jScrollPane.js
extension/community_design/design/suncana/javascript/jquery.mousewheel.js
extension/community_design/design/suncana/javascript/jquery.cycle.all.js
extension/sevenx/design/simple/javascript/jquery.scrollTo.js
extension/community_design/design/suncana/javascript/jquery.cookie.js
extension/community_design/design/suncana/javascript/ezstarrating_jquery.js
extension/community_design/design/suncana/javascript/jquery.initboxes.js
extension/community_design/design/suncana/javascript/app.js
extension/community_design/design/suncana/javascript/twitterwidget.js
extension/community_design/design/suncana/javascript/community.js
extension/community_design/design/suncana/javascript/roadmap.js
extension/community_design/design/suncana/javascript/ez.js
extension/community_design/design/suncana/javascript/ezshareevents.js
extension/sevenx/design/simple/javascript/main.js

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
6content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
6content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
1content/datatype/view/ezxmltags/sub.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/sub.tplEdit templateOverride template
6content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
1content/datatype/view/ezxmltags/td.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/td.tplEdit templateOverride template
1content/datatype/view/ezxmltags/tr.tpl<No override>extension/community/design/community/templates/content/datatype/view/ezxmltags/tr.tplEdit templateOverride template
1content/datatype/view/ezxmltags/table.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/table.tplEdit templateOverride template
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 24
 Number of unique templates used: 9

Time used to render debug report: 0.0002 secs