PHPmotion Wiki : EmailOnComment

HomePage :: Contents :: PageIndex :: Login/Register

Revision [876]

Last edited on 2009-09-23 05:02:20 by InMotion
Additions:
__Find the section with the following code__
__Replace the above code with the following code__
Deletions:
Find the section with the following code
---------------------------------------
Replace the above code with the following code
----------------------------------------------


Revision [875]

Edited on 2009-09-23 05:01:52 by InMotion

No differences.

Revision [874]

Edited on 2009-09-23 05:01:09 by InMotion

No differences.

Revision [873]

Edited on 2009-09-23 05:00:57 by InMotion
Additions:
===__STEP 1__===
===__STEP 2__===
===__STEP 3__===
----
Deletions:
===STEP 1===
===STEP 2===
===STEP 3===


Revision [872]

Edited on 2009-09-23 05:00:27 by InMotion
Additions:
===STEP 3===
Upload all the files you edited back into their respective places in your FTP.
Thats its, now every time a comment is posted, the owner of the video will now get an email notification


Revision [871]

Edited on 2009-09-23 04:58:42 by InMotion
Additions:
Replace the above code with the following code
----------------------------------------------
($user_id, '$user_name', $vid, '$comments', NOW())";
//--------------------------V3 Tweek - Send email notification on comments--------------------------------
$sql1 = "SELECT * FROM videos WHERE indexer = $vid";
$result1 = mysql_query($sql1);
$results = mysql_fetch_array($result1);
$owner = $results['user_id'];
$sql = "SELECT email_address FROM member_profile WHERE user_id = $owner";
$result = @mysql_query($sql);
$results = mysql_fetch_array($result);
$owners_email = $results['email_address'];
$comment = strip_tags(html_entity_decode($postedValue[0]));
$video_url = $config["site_base_url"].'/videos/'.$vid.'/';
$from = $config["from_system_name"];
$from_email = $config["notifications_from_email"];
//Email details [you can change these 2 items]
$subject = 'You have a new video comment';
$message = "$video_url\n\n\n--------------------------------------------------------\n\n$comment";
@mail($owners_email,$subject,$message,"From: $from <$from_email>");
//----------------------------------------------------------------------------------------------------------


Revision [870]

Edited on 2009-09-23 04:57:47 by InMotion
Additions:
($user_id, '$user_name', $vid, '$comments', NOW())";
Deletions:
($user_id, '$user_name', $vid, '$comments', NOW())";


Revision [869]

Edited on 2009-09-23 04:57:30 by InMotion
Additions:
===STEP 1===
Download the following files from your FTP and save them anywhere on your computer
- **/comments.php**
===STEP 2===
Edit **comments.php**
%%
Find the section with the following code
---------------------------------------
$sql = "INSERT into videocomments (by_id, by_username, video_id, comments, todays_date) VALUES
($user_id, '$user_name', $vid, '$comments', NOW())";
mysql_query($sql);
%%


Revision [868]

Edited on 2009-09-23 03:07:29 by InMotion
Additions:
[[http://phpmotion.com/forum/index.php/topic,14406.0.html Original Forum Post]]


Revision [867]

Edited on 2009-09-23 03:05:04 by InMotion
Additions:
=== {{color text="Solution" c="blue"}} ===
Deletions:
=== Answer ===


Revision [866]

Edited on 2009-09-23 03:04:44 by InMotion
Additions:
=== {{color text="Question Asked" c="blue"}} ===
Deletions:
=== Question Asked===


Revision [865]

Edited on 2009-09-23 03:04:20 by InMotion
Additions:
[[http://wiki.phpmotion.com/V3Tweaks Back to V3Tweaks]]
Deletions:
[[http://wiki.phpmotion.com/HowTo Back to Tips & Tricks (HOW TO)]]


Revision [864]

Edited on 2009-09-23 03:03:36 by InMotion
Deletions:
=====Captcha Images=====


Revision [863]

The oldest known version of this page was created on 2009-09-23 03:03:26 by InMotion
Valid XHTML 1.0 Transitional :: Valid CSS :: Powered by WikkaWiki
Page was generated in 0.0564 seconds