An advanced Link content type for Plone, with image field and internal link feature
Project description
Introduction
An enhanced version of the base Plone link content type.
After installing this you’ll see that the Plone link will have a new image and caption fields like the News Item content type.
Also the new Link type can handle internal (to Plone contents) and external links. You can use the internal link field to automatically attach the link value to an internal content of the portal (in a similar way used for related contents).
An event-based system will also keep URLs updated even when you move/rename target document.
Handle back-end/front-end URLs
The Smart Link structure is nothing more that a ATLink content, so the way used to store URL in the object or in the site’s catalog is the same as Plone. There is no magic behind.
For this reason, when you are using Smart Link for internal references, the static URL is stored and used.
This will lead to problems when you are using this product for site where you have different back-end/front-end URLs; those problems are the same you have when you don’t use this product!
For this reason you must use the “Configure Smart Link” control panel to handle URL transformation.
You can also use an option that says to Smart Link to store relative URLs, but this will also include the Plone site id in every link (and you must rewrite this from Apache if you don’t like this).
Warning 1
Smart Link shape-change itself to be the Link content type, and hide the basic Plone Link type. Old ATLink already created will continue working normally, but only new created link will behave the Smart Link features.
Warning 2
Pay attention when you update the whole portal_catalog using ZMI from URLs different from back-end or front-end ones (for example: using a SSH tunnel).
If you run the update from (for example) “localhost:8090/site” and this URL is not the public or one of the back-end URLs, all your internal links will be changed to this hostname! Another catalog update (from the right URL) will fix this.
Safe re-install, clean uninstall
You can re-install Smart Link safely for upgrade task or for restore changes, without any problem.
If you uninstall it all data from Smart Link will be removed. This means that if you re-install it after all you internal links will not be linked to target contents.
At uninstall time Smart Link restore the Plone ATLink content. However all created Smart Link are still Smart Link and all of theme need the product code to continue working (even if not installed).
So: the uninstall is not 100% perfect.
Requirements
Smart Link has been tested on Plone 3.3 and 4.0. Is possible that also older Plone 3.x version can be used safely.
TODO
Fix this ugly error: WARNING SecurityInfo Conflicting security declarations for setId
Warn the user if he used a remote URL for an internal content
Show title and description of an internal link
Evaluate a more general approach to icon substitution
Additional documentation
You can find more documentation on the project’s home page
Credits
Developed with the support of:
All of them supports the PloneGov initiative.
Changelog
1.0.0rc2 (2010-11-06)
reStructured text fixes [keul]
uninstall was not working under Plone 4.0 (this close #5) [keul]
URL utility description updated with latests features added in 1.0 version [keul]
fixed duplicated icon when using (or not using anymore) this product on Plone 4 (close #4). To make those additional icon disappear from Plone UI you may need a catalog update. [keul]
configuration icon was not displayed properly on Plone 4 [keul]
added the “Front-end main URL” feature (close #3) [keul]
1.0.0rc1 (2010-09-12)
Plone 4 compatibility [keul]
The explicit use of iw.fss has been removed. The fss.zcml is still there and you can still include it if you like, but you must do this manually [keul]
ISmartLink also extends the IImageContent interface [keul]
A better uninstall procedure, that remove Plone UI stuff and restore original linked object status [keul]
Added the favicon field, that drive the icon’s link [keul]
Added the anchor field, for manage anchor in internal links [keul]
Moved new and old secondary fields to the Advanced fieldset [keul]
The “unlink” event when deleting a referenced object has been removed: keeping an additional index only for this feature was not a soo good idea. Now the internal link will display the latest memoized link [keul]
Aligned the smartlink_view with the latest Plone link_view, so now will also display the message when you are not redirected to the target URL (however this will be untranslated on Plone < 3.3) [keul]
Added tests [keul]
Updated and fixed labels and texts all around and i18n translation too [keul]
Splitted UI error warn when you don’t provide neither internal and external link, from the fact that you provide both of them [keul]
When unlinking an internal content, it’s cleaned from marker interface [keul]
Switched front-end and back-end order in the config panel [keul]
Fixed a bug that force the front-end URLs in config panel to be unique [keul]
0.7.3 (2010-06-03)
fix #2 - error upgrading from 0.4.* to 0.7.* (missing utility) [mauro]
0.7.2
The “smartLink” event was using directlyProvides instead of alsoProvides… this was corrupting some target objects (like: it was impossible to internally link a file that use blobs) [keul]
Removed the Plone 3.3+ dependency because Smart Link is providing the same feature given by Plone 3.3 also on older Plone versions [keul]
0.7.1
Version 0.7 had a stupid, unused dependency [keul]
0.7.0
Added z3c.autoinclude support [keul]
From this version the minimum requirement is Plone 3.3 [keul]
Aligned with changes done to ATLink from Plone 3.3 [keul]
Added a fake link_redirect_view [keul]
0.6.1
Fixed egg format [keul]
README updated [keul]
0.6.0 (Unreleased)
Changed name of tool [fdelia]
Added icon for tool [fdelia]
0.5.1
Fix for the corrupted version 0.5.0 [fdelia]
0.5.0
Added configuration panel to transform back-end links in front-end links [fdelia]
Added configuration panel to have internal links relative and not absolute [fdelia]
0.4.0
Keep relations of internal link even if the target content is renamed/moved [keul]
Added a marker interface for internally linked contents [keul]
When target object is deleted, the internal relation became a normal absolute URL info [keul]
0.3.1
Restored the original remoteUrl StringField , due to continuous bad integration with 3rd party products (like p4a and collective.flowplayer) [keul]
0.3.0
Fixed syntax error on relation name (“internal_page” was “interal_page”) [keul]
Disabled the backup of basic Plone ATLink [keul]
Fixed some integration problem in content/link.py related to p4a (remoteUrl) [lucabel]
Fixed major bug in post_validate (validation was useless) [fdelia]
Internalization with i18ndude [fdelia]
Created italian translation [micecchi]
Clean uninstall (restoring the original ATLink in portal_types) [keul]
0.2.0
Added a lot of ATLink methods not migrated to the SmartLink class.
Fixed a bug that lead all reordering actions in folders with SmartLink inside to failure (or to chaotic results). After migrating to this version from the 0.1.0 you can also launch the fix_meta_data external method or your folder will remains broken.
0.1.0
Initial release
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
File details
Details for the file redturtle.smartlink-1.0.0rc2.tar.gz
.
File metadata
- Download URL: redturtle.smartlink-1.0.0rc2.tar.gz
- Upload date:
- Size: 49.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6a88bbd11b00e274f951deb50cf58e1abaeb56a18099e34d14d30b0f55127f10 |
|
MD5 | 542d0cb554d88ff317cc76647cd76876 |
|
BLAKE2b-256 | e88a66f35935605e8d4cb67bc5b6fead2eb306df7fc887e3f13150f549bf5a32 |
File details
Details for the file redturtle.smartlink-1.0.0rc2-py2.6.egg
.
File metadata
- Download URL: redturtle.smartlink-1.0.0rc2-py2.6.egg
- Upload date:
- Size: 74.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | cbe04debd4de40ca3c51e2a3f1845cfb4cada05f30698fdc075c6933e7aa20af |
|
MD5 | 9e66458a5d904d2d6238d99d37a7aabd |
|
BLAKE2b-256 | 665538df9836662bdfb762af7badbd4a99b08caeee756de40db2573cebd04c28 |
File details
Details for the file redturtle.smartlink-1.0.0rc2-py2.4.egg
.
File metadata
- Download URL: redturtle.smartlink-1.0.0rc2-py2.4.egg
- Upload date:
- Size: 75.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4109770e3d9b319ce8459d4ac294d1ab6a9b5c1ce0c6991ca283d6de71e0250e |
|
MD5 | b5ae1fd22f059a7eaab45f8784eb07c0 |
|
BLAKE2b-256 | 293e24a36d31594801d828ff42b1eb6233c28b44530783814e831b2ca7f9468e |