Skip to main content

developerWorks >  Lotus  >  Forums  >  Lotus Web Content Management  >  developerWorks

Send email for publishing content    Point your RSS reader here for a feed of the latest messages in this thread


     

 
 

My developerWorks
 Welcome, Guest
Sign in or register
Permlink Replies: 5 - Pages: 1 - Last Post: Nov 6, 2009 8:32 AM Last Post By: cmknight Threads: [ Previous | Next ]
JCCPortal

Posts: 84
Registered: Sep 28, 2007 03:03:50 PM
Send email for publishing content
Posted: Jun 23, 2008 02:03:03 PM
Click to report abuse...   Click to reply to this thread Reply
Hi,

I have a requirement to send an email to all users when a new annoucement published on the portal. Is it possible to send a customized email throught WCM?

Thank you in advance.
mfromin

Posts: 42
Registered: Jan 31, 2005 06:43:31 PM
Re: Send email for publishing content
Posted: Jun 23, 2008 10:40:35 PM   in response to: JCCPortal in response to: JCCPortal's post
Click to report abuse...   Click to reply to this thread Reply
WCM contains email actions - so yes. Look at the InfoCenter for details on the email action.

Michael Fromin
Ephox
http://www.ephox.com/ibm

JCCPortal

Posts: 84
Registered: Sep 28, 2007 03:03:50 PM
Re: Send email for publishing content
Posted: Jun 24, 2008 10:03:50 AM   in response to: mfromin in response to: mfromin's post
Click to report abuse...   Click to reply to this thread Reply
Hi

Thank you for the reply. When using the email action the email text can't be customized to be user friendly.

Do you know if there is another way to send a customized email to the users when a new announcement is published.

Thanks a lot
mfromin

Posts: 42
Registered: Jan 31, 2005 06:43:31 PM
Re: Send email for publishing content
Posted: Jun 24, 2008 10:45:33 PM   in response to: JCCPortal in response to: JCCPortal's post
Click to report abuse...   Click to reply to this thread Reply
If that does not work you can use the API. There is an API call on the Workspace that gets all content changes since a given point in time:


findContentModifiedSince

public com.ibm.workplace.wcm.api.DocumentIdIterator findContentModifiedSince(java.util.Date modifiedDate)

Returns an iterator of IDs of all Content that have been modified since the specified date. The IDs returned will include those for Content that have been modified on the given date. If no content has been modified since this date, or the user has access to no documents in this set, then the iterator will not return any elements. null will never be returned.
Parameters:
modifiedDate - the date with which to compare Content last modified date
Returns:
an iterator over objects modified since the given date that are visibile to the current user

...or if you have 6.0.1.3 there is some new API stuff that you can tie to workflow. There is a nice article on developerWorks on that concept.


Michael Fromin
Ephox
http://www.ephox.com/ibm

email action en...

Posts: 3
Registered: Oct 10, 2009 03:57:24 AM
Re: Send email for publishing content
Posted: Oct 23, 2009 07:48:17 AM   in response to: mfromin in response to: mfromin's post
Click to report abuse...   Click to reply to this thread Reply
Hi,

I am also having requirement to customize the mail content. But i am not getting idea how to use api for this. Where i will be associating these api with workflow.
where to write the code...

thanks..

cmknight

Posts: 448
Registered: Aug 21, 2005 08:51:58 PM
Re: Send email for publishing content
Posted: Nov 06, 2009 08:32:40 AM   in response to: email action enabling in response to: email action enabling's post
Click to report abuse...   Click to reply to this thread Reply
For emails, the out of the box WCM workflow email is not customizable. There are many possible options, here are 3:
1) Use custom workflow action (If you're on 6.1). When the custom workflow action is triggered, use java mail API to send email
2) Use PZN Email rule. They allow customizable email messages, and can be used with the portal user collection to retrieve user email addresses
3) Use java mail API outside of custom workflow. Once you determine which content you want to mail about (perhaps using Michaels logic) then you have the content you want to mail about.

I will be posting a wiki topic shortly on how to allow users to subscribe to content changes. It combines #2 and #3, in that it runs a background task every x minutes to find content thats been changed since the last run. Then it checks to see who is subscribed to that content, and then uses a PZN rule to send an email to that user.

Christopher Knight

Point your RSS reader here for a feed of the latest messages in all forums