Author Topic: Email Piping  (Read 8564 times)

krashnik

  • Freshman
  • *
  • Posts: 25
    • View Profile
    • HardMagic Publishing
Email Piping
« on: October 28, 2010, 04:21:13 PM »
I am designing an algorithm so users may send an email back to the notifications they receive and it will automatically add their reply into the comment area of the project, milestone, file, or other area. 

This is about 75% complete and has taken me about 5 hours. I'll finish it up within a few days.

Any suggestions or others who have done similar, feel free to post here.
Owner of HardMagic Publishing

krashnik

  • Freshman
  • *
  • Posts: 25
    • View Profile
    • HardMagic Publishing
Re: Email Piping
« Reply #1 on: October 29, 2010, 12:32:05 AM »

Ok.  here's all my hard work:

In Language/en_us open general.php & find:


     
Code: [Select]
'system notification email' => 'This is a system notification, do not reply to this email.',

and below it add this:

     
Code: [Select]
'system notification email change' => 'This is a system notification. You may reply to the message below.',
  'system notification email start' => '###Enter Reply Between These Lines ONLY!!###',
  'system notification email end' => '###END REPLY###',

_____________

In application/views/notifier open task_assigned.php & find:

   
Code: [Select]
<?php echo lang('system notification email'); ?><br>and change to:

   
Code: [Select]
<?php echo lang('system notification email change'); ?><br>
<?php echo lang('system notification email start'); ?><br><br>
<?php echo lang('system notification email end'); ?><br>

Do the same for the general.php file found in that folder, too.

________________________

In application/models/notifier open Notifier.class.php & find

   
Code: [Select]
if (!is_valid_email($senderemail)) {
$senderemail = 'noreply@fengoffice.com';

and change to

   
Code: [Select]
if (!is_valid_email($senderemail)) {
$senderemail = 'piping_address@yourdomain.com';


find

   
Code: [Select]
"from" => self::prepareEmailAddress($senderemail, $sendername),

change to:

   
Code: [Select]
"from" => self::prepareEmailAddress('piping_address@yourdomain.com', $sendername),

This will make all emails come from your piping address so replies will be sent there instead of to the original poster as normal.  This can be altered if you still want the original poster to receive a message, too, but we notify them with further mods, soon - so keep reading!



Then you want to add the attached file to your usr/bin directory - NOT your public_html folder.

CHMOD 755 it so it can be executed.

Change the database details in that file & also change any instance of YOURDOMAIN to your website address or the appropriate text.

Then log into cpanel &  add a piping address into your host - Cpanel offers an easy option to do this though each host has it different.

That's it!  Give it a test drive.

This currently works with tasks only & not file, milestones, etc.  Will be updated soon. 

The Iphone section also doesn't work nor if you send the message in plain text.  I will be modding that soon, too.

























Owner of HardMagic Publishing

cabeza

  • Administrator
  • Hero Member
  • *****
  • Posts: 1004
    • View Profile
    • Feng Office
Re: Email Piping
« Reply #2 on: November 12, 2010, 04:57:50 PM »
This looks very promising. Keep us posted !

krashnik

  • Freshman
  • *
  • Posts: 25
    • View Profile
    • HardMagic Publishing
Re: Email Piping
« Reply #3 on: November 12, 2010, 05:20:52 PM »
All the info I uploaded should make this work 100%. I've had this live on my site for a few weeks now and it works great. Especially to give a quick reply from my iPhone when not at home.
Owner of HardMagic Publishing

Blinkiz

  • Freshman
  • *
  • Posts: 24
    • View Profile
Re: Email Piping
« Reply #4 on: November 18, 2010, 04:38:34 AM »
Nice feature!
Will absolutely monitor this thread more closely.

krashnik

  • Freshman
  • *
  • Posts: 25
    • View Profile
    • HardMagic Publishing
Re: Email Piping
« Reply #5 on: April 13, 2011, 04:17:15 PM »
Ok, I've modified this code.  It now works beautifully - I can add comments from my cell phone, from email, and it automatically updates the project when I reply to note that I've already read the message. 

Such a time saver.  The only issue I currently have is blackberry's encrypt their messages when sent, so people commenting on blackberies don't have the functionality yet.

I've attached the file - if there is some funding for this, I can do some better integrations, but right now it is designed for my server.  If you have the same table structure as the default with feng_ as your table structure & if you look at the words in ALL CAPS in the file, you'll see what you have to change.

I hope this helps & feel free to tweak my code to your liking.  Open Source rules!
Owner of HardMagic Publishing

cabeza

  • Administrator
  • Hero Member
  • *****
  • Posts: 1004
    • View Profile
    • Feng Office
Re: Email Piping
« Reply #6 on: April 14, 2011, 05:59:45 PM »
It looks very interesting krashnik.

What "better integrations" do you have in mind?

krashnik

  • Freshman
  • *
  • Posts: 25
    • View Profile
    • HardMagic Publishing
Re: Email Piping
« Reply #7 on: April 14, 2011, 09:25:28 PM »
Next, I'll add functionality to comment on files, notes, etc through piping.

Then what would be really nice and we have the knowledge to do it is the following:

Then we want to check if the subject was a forward. If so - we will assume it is going to a new subscriber and if the email address forwarded to is an option as a subscriber, we will add him. This goes the same for anyone in the CC.

A table made with simple commands such as %ADDSUB% %REMOVEME% and many others can be made.

Simply replyingto the email sent with these specific commands will execute actions in the program.

I do much of my work from the beach on an iPhone and this allows me to stay out of the office more. The best office is no office!


 
Owner of HardMagic Publishing

timveer

  • Freshman
  • *
  • Posts: 28
    • View Profile
Re: Email Piping
« Reply #8 on: November 03, 2011, 04:38:36 PM »
Hey krashnik,

I love the direction you were going with this mod. Did you ever get further to do this for Notes, Tasks, etc?

I can grasp the concepts but you obviously have a better understanding (at least now you do...) of the internal workings.

This topic may be a little old... but that means you've been able to do some great work with it...  ;)

Cheers,
Tim
« Last Edit: November 03, 2011, 04:45:38 PM by timveer »

krashnik

  • Freshman
  • *
  • Posts: 25
    • View Profile
    • HardMagic Publishing
Re: Email Piping
« Reply #9 on: September 14, 2012, 01:32:32 PM »
Yes, this now works perfectly in version 1.75. 

I have over 1,000 people using iPhones, Blackberries, Androids and all replying via mobile to their tasks. 

I will be upgrading to version 2.x soon and updating this script.  I need funding to write a tutorial for this - still putting the foundation of my business together, so it might take some time.
Owner of HardMagic Publishing

 

anything
anything