Hello Friends,
I'm very new to RoundCUBE. I must quickly hack some code together that will enable users to select individual emails (one at a time), permitting them to store the email into a database in its component parts.
They will have the ability to link the email with individual clients.
I've put together the very very basic shell for the plugin with a button on the toolbar.
Would someone please provide and/or direct me to the relevant code which reads the email (header, body etc etc)
Many thanks in advance.
$MESSAGE = new rcube_message($uid, $folder);
Thank you Alec, :D
Great and quick response.
I've been playing with the code below ...
$uid = '*';
$uid = "2728";
$folder = 'inbox';
$MESSAGE = new rcube_message($uid, $folder);
//echo $MESSAGE->headers->messageID;
//echo $MESSAGE->headers->uid;
//echo '<br>Subject '.$MESSAGE->headers->subject;
//echo '<br>Size '.$MESSAGE->headers->size;
//echo '<br>Folder '.$MESSAGE->headers->folder;
//echo '<br>From '.$MESSAGE->headers->from;
//echo '<br>To '.$MESSAGE->headers->to;
//echo '<br>Date '.$MESSAGE->headers->date;
//echo '<br>TEXT<br> '.$MESSAGE->first_text_part();
//echo '<br>HTML<br> '.$MESSAGE->first_html_part();
I'm finding the appropriate methods etc.
How do I get the $uid when clicking on the email?
Manual entry obviously needs to be dynamic eg $uid = '*'; or $uid = "2728";
My goal is to allow right click or click on email and select from toolbar menu to complete the operation.
Many thanks.
regards
Mark