Personal tools
You are here: Home Documentation Tutorials mailtoplone: Integrate emails with plone Example: Create a blog
Support

Get Help

Join our chat rooms or support forums if you have more specific questions.

Plone Training
Learn how to design, build, and deploy a website in Plone through one of the numerous Plone training sessions around the world.
Find Plone training…
 
Document Actions

Example: Create a blog

A simple example is to create a blog, enabling to create blog entries with emails. In the example we want to create News items inside a Folder called `webblog`. The global InBox of the portal(named `globalinbox`) receives the mails. The mails are then checked if their header `Subject` contains `blog`.

Hans-Peter Locher

Mailtoplone's main purpose is to create plone content from emails. The emails are delivered to plone as plaintext containing the entire email including the envelope. Mailtoplone makes heavy use of the zope 3 component architecture and plone's content rules. The tutorial explains the approach and shows an example usecase.
Page 4 of 5.

 

1. Create the structure

 

  • Create the InBox `globalinbox`
  • Create the Folder `webblog`
  • Mark `webblog` with `IBlogMailDropBoxMarker` (using @@manage_interfaces)
marker
  • Reindex `webblog`

 

2. Create the content rule

 

  • Event trigger: Object added to this container
  • Condition: Email Header
    Specify `Subject` as header to check, and `blog` as value. emailheader

 

  • Action: Deliver

    Specify `webblog` as key.

deliver

 

 

  • Action: Delete Object



3. Assign the created rule to the `globalinbox`

 

blogmail

 

 

4. That's all


This would be sufficient to create the News items. Of course, you're free
to specify content rules for the `webblog` too. For example
to publish news items after they have been added, so anonymous visitors would see them,
or anything you can imagine.

 

 
by Hans-Peter Locher last modified February 6, 2008 - 11:08 All content is copyright Plone Foundation and the individual contributors.

For any issues with the web site functionality, please file a ticket.

Please consult the policy on plone.org content if you want your content published on this site.

Servers and hosting by