Skip to main content

The personal bar is hidden for anonymous users

This package was created for the usecase that we have a Plone site where is no user interaction. So we don’t need a login possibility for all users, provided with the personal bar. But if someone is logged in it’s very usefull to have the personal bar. So the personal bar is hidden to anonymous users, but show to authenticated ones.

Tested with Plone 4.0.4.

>>> from os.path import dirname, join
>>> from plone.app.testing import (
...     TEST_USER_NAME,
...     TEST_USER_PASSWORD,
... )
>>> from plone.testing.z2 import Browser
>>> browser = Browser(layer['app'])
>>> browser.handleErrors = False
>>> portal = layer['portal']

As an anonymous user we can’t see the personal bar:

>>> browser.open(portal.absolute_url())
>>> '<a href="http://nohost/plone/@@personal-preferences">' in browser.contents
False
>>> '<a href="http://nohost/plone/dashboard">' in browser.contents
False

But after a login, it’s there:

>>> browser.addHeader('Authorization', 'Basic %s:%s' % (TEST_USER_NAME, TEST_USER_PASSWORD,))
>>> browser.open(portal.absolute_url())
>>> '<a href="http://nohost/plone/@@personal-preferences">' in browser.contents
True
>>> '<a href="http://nohost/plone/dashboard">' in browser.contents
True

Changelog

0.1.1 (2011-04-07)

  • fix repo url [j23d]

  • add tested Plone version to README.txt [j23d]

0.1 (2011-04-07)

  • Initial release [j23d]

Release files for collective.layout.authpersonalbar 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for collective.layout.authpersonalbar 0.1.1
File Interpreter ABI Platform
collective.layout.authpersonalbar-0.1.1-py2.6.egg Legacy Egg format - - Details

Release files / collective.layout.authpersonalbar-0.1.1-py2.6.egg

Download URL collective.layout.authpersonalbar-0.1.1-py2.6.egg
Size 12.7 kB
Tags Egg
SHA-256 checksum
How to use checksums
1229b602392233ace3b5a6b150758a70036a4d50b45d93272d2a3687fcae6882
BLAKE2b-256 checksum
How to use checksums
7fa4852a4c747109854461197602fc2080141a4b64a54b98692d2129aee80305
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

0.1.1 This release

1 release file

0.1

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page