Author Topic: Extract message body  (Read 4326 times)

Offline jmarais

  • Newbie
  • *
  • Posts: 4
Extract message body
« on: February 20, 2012, 05:38:06 PM »
I installed roundcube on my website and the main reason is that I want to extract the message bodies of some emails. I am able to do an echo statement in the file rcube_message.php that gives me the details I want. I believe you if you use the following:
$this->app = rcmail::get_instance();
$this->conn->handlePartBody($this->mailbox, $uid, true, NULL, NULL, true);

where $this->mailbox is your INBOX and  $uid is the message id.

The point where I got stuck is that I want to include a link on the body of the email similar to:

""

which is the red icon that opens the message on a new page. I want the
user to click on this newly created link in their email to store the information of the body in the database.

What I want to achieve is to extract some information from certain email bodies to the database.

Anyone that can give me some pointers? Will be highly appreciated!

Offline SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,879
    • SKaero - Custom Roundcube development
Extract message body
« Reply #1 on: February 21, 2012, 01:00:49 PM »
Start by reading the plugin documentation: Doc_Plugins you should be able to do everything you need with the existing plugin hooks: Plugin_Hooks

Offline jmarais

  • Newbie
  • *
  • Posts: 4
Extract message body
« Reply #2 on: February 21, 2012, 06:42:11 PM »
Thank you for the response, I will look at it and believe it will be most helpful.