Facebook  Twitter 

SMFHacks.com

+-

SMFHacks.com

+- User Information

Welcome, Guest.
Please login or register.
 
 
 
Forgot your password?

+- Forum Stats

Members
Total Members: 4257
Latest: Alex998.
New This Month: 1
New This Week: 0
New Today: 0
Stats
Total Posts: 43295
Total Topics: 7523
Most Online Today: 149
Most Online Ever: 2482
(April 09, 2011, 07:02:45 pm)
Users Online
Members: 0
Guests: 144
Total: 144

Author Topic: just purchased and uploaded newsletter pro to package manager getting an error  (Read 990 times)

0 Members and 1 Guest are viewing this topic.

Offline geminiman

  • Member
  • *
  • Posts: 3
    • View Profile
hi i just purchased newsletter pro on the basis that it is advertised as smf 2.1 compatible


   
Newsletter Pro

Information:
Upgrades the built in newsletter functions inside SMF. Adds an updated message editor clicker and opener tracking and more!
Requires
Supports SMF 2.1.x (MySQL), SMF 2.0.x (MySQL), SMF 1.1.x

however upon uploading to package manager when i attempted to install (its not installed yet ) i got an error , here it is

    Execute Modification    ./Sources/ManageNews.php    Test failed

can anyone tell me why i got this test failed error ? , is the mod safe to install ? . thanks in advance for any help .


Offline SMFHacks

  • Administrator
  • Hero Member
  • *****
  • Posts: 16452
    • View Profile
Does it say which one it failed? There should be multiple edits to the file
Get your Forum Ranked! at https://www.forumrankings.net - find out how your forum compares with others!

Like What I do? Support me at https://www.patreon.com/vbgamer45/

Offline SMFHacks

  • Administrator
  • Hero Member
  • *****
  • Posts: 16452
    • View Profile
Get your Forum Ranked! at https://www.forumrankings.net - find out how your forum compares with others!

Like What I do? Support me at https://www.patreon.com/vbgamer45/

Offline geminiman

  • Member
  • *
  • Posts: 3
    • View Profile
hi thanks for your reply . yes there were multiple edit options , 10 in total . the test failed on just one .

find

// Don't sent it twice!
unset($context['recipients']['emails'][$k]);

// Dammit - can't PM emails!
if ($context['send_pm'])
continue;

// Non-members can't subscribe or unsubscribe from anything...
$unsubscribe_link = '';

$to_member = array(
$email,
!empty($_POST['send_html']) ? '<a href="mailto:' . $email . '">' . $email . '</a>' : $email,
'??',
$email,
$unsubscribe_link,
);

sendmail($email, str_replace($from_member, $to_member, $_POST['subject']), str_replace($from_member, $to_member, $_POST['message']), null, 'news', !empty($_POST['send_html']),
5);


replace with


// Don't sent it twice!
unset($context['recipients']['emails'][$k]);

// Dammit - can't PM emails!
if ($context['send_pm'])
continue;


// Newsletter Pro
// Send single emails
// Check subject is empty
if (empty($_POST['subject']))
fatal_error("Unable to send subject is empty",false);

// Check if message is empty
if (empty($_POST['message']))
fatal_error("Unable to send message is empty",false);


$emailID = 0;
if (empty($context['send_pm']))
{
$email_query = "INSERT INTO " . $temptable  . " (ID_LETTER,email) VALUES ";

// Replace bad characters

$email = str_replace("'","", $email);

$email_query .= "('" . $context['ID_LETTER'] . "','" . $email . "'),";

$email_query .= "]]";
$email_query = str_replace(",]]","",$email_query);
$smcFunc['db_query']('', $email_query);
$emailID = $smcFunc['db_insert_id']($temptable, 'ID_EMAIL');

$smcFunc['db_query']('', "UPDATE {db_prefix}newspro_newsletters SET sent = sent + 1 WHERE ID_LETTER = "  . $context['ID_LETTER']);
}


$message = str_replace("#ID_EMAIL#",$emailID,$_POST['message']);

global $boardurl;
$message = str_replace("EMAILHASH",sha1($email . $boardurl),$message);

// End Send Singe emails
// End Newsletter Pro

$to_member = array(
$email,
!empty($_POST['send_html']) ? '<a href="mailto:' . $email . '">' . $email . '</a>' : $email,
'??',
$email,
$unsubscribe_link,
);

sendmail($email, str_replace($from_member, $to_member, $_POST['subject']), str_replace($from_member, $to_member, $_POST['message']), null, 'news', !empty($_POST['send_html']), 5);

so do i simply replace the above code and the error is cleared ? .

Offline SMFHacks

  • Administrator
  • Hero Member
  • *****
  • Posts: 16452
    • View Profile
Get your Forum Ranked! at https://www.forumrankings.net - find out how your forum compares with others!

Like What I do? Support me at https://www.patreon.com/vbgamer45/

Offline geminiman

  • Member
  • *
  • Posts: 3
    • View Profile
hi and thanks . i downloaded the above version . is there a guide / tutorial on here in regards using this mod ? .

Offline SMFHacks

  • Administrator
  • Hero Member
  • *****
  • Posts: 16452
    • View Profile
There is not a guide. Basically you can send a newsletter now with an html editor, view/click and unsubscribe tracking.
Also, an option to manually schedule campaigns requires a cron job setup though.
Get your Forum Ranked! at https://www.forumrankings.net - find out how your forum compares with others!

Like What I do? Support me at https://www.patreon.com/vbgamer45/

 

Related Topics

  Subject / Started by Replies Last post
1 Replies
4337 Views
Last post September 15, 2007, 10:33:18 pm
by SMFHacks
2 Replies
5045 Views
Last post January 29, 2008, 06:37:57 pm
by SMFHacks
5 Replies
5162 Views
Last post May 20, 2008, 07:58:37 am
by SMFHacks
8 Replies
11499 Views
Last post May 31, 2009, 07:57:13 pm
by Cowboy Logic
2 Replies
3537 Views
Last post February 13, 2015, 02:49:49 pm
by pd35

+- Recent Topics

Please Help! by SMFHacks
April 17, 2024, 08:04:55 am

Rate own images by fvlog19
April 11, 2024, 10:56:53 am

Tidy Child Boards on 2.1.4 by SMFHacks
April 04, 2024, 03:54:12 pm

Problems SMF 2.0.19 > 2.1.4 SMF Gallery Pro - Recents Images to overall header by Michel68
March 30, 2024, 12:41:08 pm

Can't DROP 'id_member'; check that column/key exists Datei: by SMFHacks
March 30, 2024, 11:58:20 am

No thumbnails on new uploads by Tonyvic
March 29, 2024, 06:26:18 am

Display the Contact Page for guests by SMFHacks
March 27, 2024, 10:55:43 am

is it possible to add support for odysee.com by fvlog19
March 21, 2024, 08:47:51 am

Request for admin notification by davejo
March 10, 2024, 01:31:59 am

I need help with torrent upload by Ineedsmfhelp
March 09, 2024, 10:01:13 pm

Powered by EzPortal