I was able to find the function that sends an email every time a new item is created. Unfortunately I lost my notes and I can not find this feature more. Remember, that you entered the menu zope them and outlined a function to the occurrence of an event ..... can you help? Sorry for the bad English,
thanks.
You simply need to use a Plone native feature: content rules.
Go the the "content rule" section of your Plone control panel (http://yoursite/##rules-controlpanel) then configure a rule with a "mailer" action. The trigger action could be a workflow transition change.
Related
I would like to know how to 'construct' tokens. I have read many examples, but somehow I don't understand them. I am new to Drupal and at the moment I am testing how it works. I'm trying to hide the title of a content type I've created and automatically replace it with the content of another field. As far as I know, I have installed and enabled all the relevant modules including CCK and Automatic Entity Label. The only thing I don't know is what token I should use to make it happen. The field I would like to use as the source for the title field is called event (or possibly field_event) and is of type text. I'm visually impaired and either I'm doing something wrong, or the token browser is not too screen reader friendly. Either way, I can't access the list of all tokens to select the token, so I have to enter it manually. If I'm not mistaken, the token should include '[node:body]', right? But is it like '[node:event:body]' or '[field:event:body]' or something else?
Many thanks!
One Idea might be the devel module https://drupal.org/project/devel . Install it, activate it and visit some page of the node type you want to use the token on, and click on the devel tab and then on the token tab. et voila. or you navigate directly to e.g. yoursite.com/node/29/devel/token .
Hope it helps.
I have a Plone site configured with PloneFormGen. I'm using a save-data-to-content adapter to create a page for each submission, with a unique number for title/id. I have content rules set up so that various roles will be notified when a submitted form transitions along the workflow.
Is there any way to include the content of the submitted in these emails? I know PloneFormGen can send the content of the form in an initial email at submit time, but I need to send this same information later. I'm pretty good at figuring things out, but I'm no Plone expert so any help would be appreciated.
Additional info:
I'm using the uwosh.pfg.d2c adapter to perform the PFG -> Contenttype conversion, which works well. The content type is set to 'page' in the settings for the uwosh.pfg.d2c plugin. Content rules then will send emails to various groups or roles based on a state transition of the resulting content, which works in the normal way - when a transition occurs, the rule executes.
Effectively, what we have is pages that are being generated by the form when the user clicks submit. This is done through a plugin in PloneFormGen. This may provide some extra info: http://pythonhosted.org/uwosh.pfg.d2c/ - I'm not, admittedly, much of a developer.
Ideally, reviewers would get body-text of the created page when the form is submitted: this is done through a content rule that when a page is added to a folder, it sends the email. The page is added to the folder when the plugin in PloneFormGen creates the page.
When we have these pages, other users can come in and review and change the state of them - just as you can with any other page in Plone. PloneFormGen should have no further use once it's been converted to a page. Hope that helps.
The bad news is that this will require programming; the good news is that it won't take much. There are two reasonable approaches to solving the problem:
Have your content rule action run a script that handles the mailing itself. You can use the site's mailhost to send scripted mail; or,
In a Python package (no way to do this in a through-the-web script), provide a named adapter implementing plone.stringinterp.interfaces.IStringSubstitution for your context's text attribute. That will give you a $ substitution for the body. This would probably require less than 10 lines of total code.
You might want to have a look a collective.contentrules.mailtogroup, the newest version is capable to send the body-text as mail (use the '${text}'-variable), triggered on one of the convenient content-rules-events, in your case 'Object added'.
You can assign your roles to a group and use it for your case.
I have an online magazine with news articles and i want to make an open graph action that everytime a user reads an article a story to post in his timeline.
I have all the nececery open graph tags in my urls and a login button with publish_actions scope.
I'm one step away from submitting the action for approval but i still cant figure out one thing.
The facebook's documentation says that i need to give users an option to stop auto publishing or remove the app etc. something like the image in the middle of this page http://developers.facebook.com/docs/opengraph/actions/builtin/#read .
I saw it also on yahoo and its exacly the same.
How can i make something like this in my site? The code is ready somewhere or i have to write it myself?
Thanks in advance!
The permission remove, or just a switch to stop publish of action and the delete article functions will have to be developed by you.
I am working on the same things for my app.
creating user CP control panel containing, revoke perms buttons.
a user CP to swich publishing on and off, via true/false in mysql
an array of app activities with delete buttons.
I'd like to customize the text sent from the default Comment action of Plone, especially the link sent when someone comments on a file. Current behavior is that the link launches the file itself. The behavior I'd like to see is to take the reader to be able to see the comment entered.
I've been trying to find the template script for the message via both ZMI and the Zope file system but couldn't locate the message template.
.... Example of Default Message ....
Someone added a comment on your File:
Test.
If you are the author of this item, we recommend that you read the comment,
and update the documentation accordingly if required - then remove the comment.
If further clarification is needed, reply to the comment, and the person who
made the comment will get a notification like this, and will likely give you
more details.
To view the new comment, visit:
http://bestkey.middlewaygroup.com/products/Test.ppt
--
Site Administrator
You might want to have a look at plone.app.discussion which is the new commenting system for Plone 4.1 and also available as an add-on product for Plone 3.3.
With p.a.discussion you can register a custom event subscriber that is fired when a new comment is added:
<subscriber
for="plone.app.discussion.interfaces.IComment
zope.app.container.interfaces.IObjectAddedEvent"
handler=".mycustomsubscriber.notify_user"
/>
You have to put a "notify_user" function inside a "mycustomsubscriber.py" file which can contain arbitrary Python code that sends a custom email.
See http://svn.plone.org/svn/plone/plone.app.discussion/trunk/plone/app/discussion/notifications.zcml and http://svn.plone.org/svn/plone/plone.app.discussion/trunk/plone/app/discussion/comment.py for examples.
If the old Plone commenting system comments provide an interface like IComment it should work similarly. Though, I think it does not provide such an interface, but I'm not 100% sure.
The module you are looking for is:
Products.PloneHelpCenter.skins.plone_help_center.discussion_notify_template.pt
which you can override with z3c.jbot. Or in the ZMI, customize:
portal_skins/plone_help_center/discussion_notify_template.pt
(And, you must have at least one add-on installed, Products.PloneHelpCenter because this message is from that add-on).
I would like to create a button with the name "Participate" that works like the "like" button on facebook.
I have an contenttype called Event, which should show the participate button, that logged in users can click, and add themselves to the event.
When looking at the content for Event I would also like to display a list of the users which have clicked the Participate button.
Is there someone who can help me with how it can be solved or what i should look into?
take a look at this module with some php knowledge you can make it , it's not what you really want but this guys pushed the hard part
The Activity module keeps track of the
things people do on your site and
provides mini-feeds of these
activities in blocks, in a specialized
table, and via RSS. The module is
extensible so that any other module
can integrate with it. The messages
that are produced are customizable via
the admin interface and are context
sensitive. Some theoretical example
messages include:
You wrote a comment in response to "example comment title"
Jim wants to be your friend. Approve this friendship here
Nancy is Phil's latest fan
http://drupal.org/project/activity