Metadata-Version: 2.1
Name: collective.redirectacquired
Version: 2.0a1
Summary: Redirect when traversing to acquired content outside the current path.
Home-page: https://github.com/collective/collective.redirectacquired
Author: Godefroid Chapelle
Author-email: gotcha@bubblenet.be
License: GPL
Keywords: traversal acquisition
Classifier: Framework :: Plone
Classifier: Framework :: Plone :: 6.0
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: License :: OSI Approved :: GNU General Public License v2 (GPLv2)
Classifier: Operating System :: OS Independent
Requires-Python: >=3.7
Requires-Dist: setuptools
Requires-Dist: Products.CMFCore
Requires-Dist: Products.CMFPlone
Requires-Dist: Zope2
Requires-Dist: zExceptions
Requires-Dist: zope.component
Requires-Dist: zope.interface
Requires-Dist: plone.app.caching
Provides-Extra: test
Requires-Dist: Products.CMFPlone[test]; extra == "test"

collective.redirectacquired
===========================

This Plone addon aims to solve the very common issue of having a lot of different URLs that publish the same content item via acquisition.

It supports Plone 6. See 1.x branch for Plone 4 support.

Zope implicit acquisition leads to many use case where URLs that are valid for the publisher are produced but are not the URLs meant by the users of the system.

This addon modifies the publication process to ensure that instead of allowing traversal from a content item to another content item
via  acquisition, we redirect to the URL of the traversed content item.

In the previous paragraph, an item is considered a content item if and only if it provides ``Products.CMFCore.IContentish``.

This should avoid false positive redirects for URL path item that are acquired but are actually parts of the software rather than content items.

If you need to enable publication of content items via acquisition, mark them with
``collective.redirectacquired.interfaces.IPublishableThroughAcquisition``.

Changelog
=========


2.0a1 (2024-02-08)
------------------

- Plone 6 support (Plone 4 support dropped)
  [gotcha]

- NotFound when acquiring site only raised when redirect is activated in zope.conf
  [gotcha]


1.0a12 (2018-03-20)
-------------------

- less noisy logging
  [gotcha]

- NotFound when acquiring a site
  [gotcha]


1.0a11 (2018-03-12)
-------------------

- Be defensive against circular redirects caused by broken Link objects or broken plone.folders
  [gotcha]


1.0a10 (2018-02-26)
-------------------

- Get rid of code made useless by refactoring.
  More tests
  [gotcha]


1.0a9 (2018-02-20)
------------------

- Refactor for more complex acquisition
  https://github.com/collective/collective.redirectacquired/issues/3
  [gotcha]

- Do not break redirector
  https://github.com/collective/collective.redirectacquired/issues/2
  [gotcha]

- Do not allow to cache permanent redirection
  https://github.com/collective/collective.redirectacquired/issues/1
  [gotcha]


1.0a8 (2018-01-25)
------------------

- Redirect permanently (301)
  [gotcha]


1.0a7 (2018-01-24)
------------------

- Take care of QUERY_STRING.
  [gotcha]

- Do not redirect if REQUEST_METHOD is not GET.
  [gotcha]

1.0a6 (2018-01-24)
------------------

- Fix and test when logging only.
  [gotcha]


1.0a5 (2018-01-24)
------------------

- Fix rushed code.
  [gotcha]


1.0a4 (2018-01-24)
------------------

- Logging is back.
  [gotcha]


1.0a3 (2018-01-24)
------------------

- More tests and refactoring
  [gotcha]


1.0a2 (2018-01-22)
------------------

- More tests
  [gotcha]

- Much simpler implementation
  [gotcha]


1.0a1 (2018-01-17)
------------------

- Remove useless inclusion of CMFPlone in configure.zcml
  [gotcha]


1.0a0 (2018-01-17)
------------------

- Initial release
  [gotcha]
