![]() ![]() |
Oct 21 2006, 12:37 PM
Post
#1
|
|
|
New Member ![]() Group: Members Posts: 9 Joined: 3-September 06 Member No.: 4,083 ![]() |
It's possible integrated a information when i put e new image send an info all user are registred.
For example a news letter ? |
|
|
|
Oct 25 2006, 04:46 PM
Post
#2
|
|
![]() Boss, my code's compiling (xkcd) Group: Admins Posts: 10,440 Joined: 19-September 01 Member No.: 1 ![]() |
Sure, look in functions/f_lib.php for (at the very end)
CODE ?> and above that insert CODE //-------------------------------------------- // zenithMailer(), new in v0.9.2 DEV // Used for batch emailing (uncomment add.php:192 and comment add.php:191 to enable) // Final version will use something like swift mailer to make the batch sending more efficient //-------------------------------------------- function zenithMailer($config, $to, $subject, $body, $headers) { $recipients = array(); //Container for recipients $statement = "SELECT username, email FROM {$config['table_prefix']}users"; $result = mysql_query($statement); while ($row = mysql_fetch_array($result)) $recipients[] = array($row['username'], $row['email']); //get all our emails foreach($recipients as $value) { if(!@mail($value[1], $subject, $body, $headers)) return 0; //if something wrong happened, quit } return 1; } In add.php for CODE require_once('functions/f_db.php'); and below that insert CODE require_once('functions/f_lib.php'); Then look for CODE if(!@mail($config['admin_email'],"{$config['title']} New Picture submitted",$body,$headers)) and replace it with CODE //if(!@mail($config['admin_email'],"{$config['title']} New Picture submitted",$body,$headers)) if(!zenithMailer($config, $config['admin_email'],"{$config['title']} New Picture submitted",$body,$headers)) Save both files and upload. Can't promise anything efficiency-wise. Let me know if you have any problems. -------------------- ![]() ![]() Things that I don't suck at: Photography (flickr, JPG Mag), "Don't bail; the best gold is at the bottom of barrels of crap!" -Randy Pausch I have people-skills goddamnit! What is wrong with you people!!! | www.skyrill.com |
|
|
|
Dec 5 2006, 05:40 AM
Post
#3
|
|
|
Full Member Group: +Zenith User Posts: 92 Joined: 6-February 06 From: Mendoza, Argentina Member No.: 3,240 ![]() |
It is possible that each user selects from his account of user if wishes to receive newsletter and not that arrives at all the registered in the gallery?
Greetings LUIS |
|
|
|
Jan 21 2007, 08:11 AM
Post
#4
|
|
|
New Member ![]() Group: Members Posts: 21 Joined: 4-July 06 Member No.: 3,776 ![]() |
hey Urs.
I did try this one out but did not work! I got 2 users, I posted some pics with the Admin user and I did NOT get any notification or email of new posted images in the gallery! hmmm |
|
|
|
Jan 23 2007, 10:24 PM
Post
#5
|
|
![]() Boss, my code's compiling (xkcd) Group: Admins Posts: 10,440 Joined: 19-September 01 Member No.: 1 ![]() |
hmm..Not too sure why it wouldn't work if you made the correct modifications. If you want, you can PM me temporary ftp login details and your gallery's URL and I can took a look at it for you
-------------------- ![]() ![]() Things that I don't suck at: Photography (flickr, JPG Mag), "Don't bail; the best gold is at the bottom of barrels of crap!" -Randy Pausch I have people-skills goddamnit! What is wrong with you people!!! | www.skyrill.com |
|
|
|
![]() ![]() |
|
Lo-Fi Version | Time is now: 21st May 2013 - 12:17 AM |