Results 1 to 2 of 2

Thread: [Release vb2.0] Receive copy of e-mail you send via the BB

Threaded View

  1. #1
    Senior Member bira is on a distinguished road bira's Avatar
    Join Date
    May 2000
    Location
    2nd turn left
    Age
    42
    Posts
    1,501

    [Release vb2.0] Receive copy of e-mail you send via the BB

    Hi All,

    This is a very small hack, but one that my users requested:

    When you send a fellow member an e-mail via the BB mailform, you can select to also receive a copy of this e-mail to your address.

    The "installation" (for lack of better word) includes inserting a small piece of code into member.php, adding a small piece of HTML into one template, and creating a simple text-only new template.

    Enjoy!

    Installation Instructions:

    1. Open member.php. Almost completely at the end of the script, find:

    PHP Code:
    mail($destuserinfo[email],$subject,$sendmessage,"From: \"$bbuserinfo[username]\" <$bbuserinfo[email]>"); 
    BELOW it add:

    PHP Code:
      if ($getcopy) {
        
    $subject "FW: ".$subject;
        eval(
    "\$sendmessage = \"".gettemplate("email_copymessage",1,0)."\";");
        
    mail($bbuserinfo[email],$subject,$sendmessage,"From: \"$bbtitle Mailer\" <$webmasteremail>");
      } 
    Save file and upload.

    2. Edit template mailform.

    Find, almost at the bottom:

    Code:
    <input type="hidden" name="action" value="emailmessage">
    	<input type="hidden" name="userid" value="$userid">
    	<input type="submit" class="bginput" name="submit" value="Send email">
    	<input type="reset" class="bginput" name="reset" value="Clear Fields">
    And ABOVE it add:

    Code:
    	<input type="checkbox" name="getcopy" value="1"> <smallfont><b>Check this box if you want to receive a copy of this message to your e-mail</b></smallfont>
    	<br><br>
    3. Create new template, called email_copymessage with the following content:

    This is a copy of an e-mail message you sent to $destuserinfo[username] at $bbtitle ( $bburl/index.php ):
    --------------------------------------------------------------------------

    $message
    (change the text to whatever you like really)


    THAT'S IT!

    The mailform will now look like this:



    If you check this box, a copy of the e-mail you just sent will also be sent to you.

    Cheers,

    Bira
     

  2. #2
    Member bokhalifa is on a distinguished road bokhalifa's Avatar
    Join Date
    Feb 2001
    Location
    u a e dubai
    Age
    33
    Posts
    99
    good work

    bira

    workin good


    thank


    I waet for you now hack
    In Dubai every thing is different
     

Similar Threads

  1. How do I receive by mail a copy of posts into a forum ?
    By gedescamps in forum vBulletin 2 'How Do I' and Troubleshooting
    Replies: 2
    Last Post: Mon 27th Aug '01, 4:45pm
  2. [RELEASE vB2.0RC1] Copy Templateset
    By Hotte in forum Releases: Version 2.x
    Replies: 11
    Last Post: Mon 13th Aug '01, 8:22pm
  3. Replies: 42
    Last Post: Sun 1st Jul '01, 9:18pm
  4. Suggestion: receive copy of e-mail you send via BB
    By bira in forum vBulletin 2 Suggestions and Feedback
    Replies: 0
    Last Post: Thu 22nd Mar '01, 11:34pm

Bookmarks

Posting Permissions

Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts