Unsubscribe from NMS or newsletter alternative

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Post Reply
caramello
Forum Members
Forum Members
Posts: 19
Joined: Sun May 27, 2007 5:46 pm

Unsubscribe from NMS or newsletter alternative

Post by caramello »

Hi,

  I've tried to use NMS module (v 1.0.1) and it works for the subscription, but I've some problem with the unsubscribe function.

The portal report:
Error!
One or more required parameters are missing from the request. This action cannot proceed

This is the code insert into the page:

{cms_module module="NMS" mode="unsubscribe"}

Is there an alternative to NMS?

Thanks a lot

 
Last edited by caramello on Fri Jun 01, 2007 7:57 am, edited 1 time in total.
ikatt

Re: Unsubscribe from NMS or newsletter alternative

Post by ikatt »

I also seem to have the same problem when using the unsubscribe form. Direct link in e-mails work fine (after adding a fix that changes & into &'s).

It seems like the problem with the unsubscribe form is also related to the & / & issue...
Last edited by ikatt on Mon Jun 04, 2007 1:06 pm, edited 1 time in total.
Splynx
Forum Members
Forum Members
Posts: 20
Joined: Tue Jun 26, 2007 2:41 pm

Re: Unsubscribe from NMS or newsletter alternative

Post by Splynx »

Have the same problem and Im very insterested in a solution for this!

(aka - bump!!!)
alby

Re: Unsubscribe from NMS or newsletter alternative

Post by alby »

Splynx wrote: Have the same problem and Im very insterested in a solution for this!

(aka - bump!!!)
Check this (in italian)

There is a problem for action.unsubscribe_email.php. Dowload revision 108 and substitute (after backup) the relative file in modules/NMS folder.

Alby
Splynx
Forum Members
Forum Members
Posts: 20
Joined: Tue Jun 26, 2007 2:41 pm

Re: Unsubscribe from NMS or newsletter alternative

Post by Splynx »

Thanks for the help mate

I tried the 108 and the 96 as suggested in the link (allthough I didnt understand the italian part :-D) but to no help :-(

I then visited the Newsletter part of SVN at http://viewsvn.cmsmadesimple.org/viewsv ... newsletter and downloaded the latest versions of action.unsubscribe.php & action.unsubscribe_email.php but again getting the same error :-(

This is really frustrating because everything else works neatly - but I have to have this feature in it as well

Any more help would be very much appreciated (Ill be sure to post when / if I find a fix on my own)
Splynx
Forum Members
Forum Members
Posts: 20
Joined: Tue Jun 26, 2007 2:41 pm

Re: Unsubscribe from NMS or newsletter alternative

Post by Splynx »

It seems to be these lines
if( !isset( $params['uniqueid'] ) )
  {
    $this->_DisplayErrorPage( $id, $params, $returnid,
      $this->Lang('error_insufficientparams'));
    return;
  }
That generates the error - but I aint no hardcore programmer so dont know what to do :-(
Splynx
Forum Members
Forum Members
Posts: 20
Joined: Tue Jun 26, 2007 2:41 pm

Re: Unsubscribe from NMS or newsletter alternative

Post by Splynx »

Found solution by downloading the files from

http://svn.cmsmadesimple.org/svn/newsletter/
caramello
Forum Members
Forum Members
Posts: 19
Joined: Sun May 27, 2007 5:46 pm

Re: Unsubscribe from NMS or newsletter alternative

Post by caramello »

Try this version.

Remember to rename the file from NMS_1.01_ok.zip.txt to NMS_1.01_ok.zip

Bye
Attachments

[The extension txt has been deactivated and can no longer be displayed.]

namloc
Forum Members
Forum Members
Posts: 10
Joined: Sun May 13, 2007 7:05 pm

Re: Unsubscribe from NMS or newsletter alternative [SOLVED]

Post by namloc »

The problem with the Error message in the unsubscribe is that action_unsubscribe_email.php is trying to use a uniqueid when all you get from the web form is an email address

change the following code at the start of the file


------------------- start old code -----------------------

if( !isset( $params['uniqueid'] ) )
  {
    $this->_DisplayErrorPage( $id, $params, $returnid,
      $this->Lang('error_insufficientparams'));
    return;
  }

  $db = $this->GetDb();

  $query = "SELECT * from ".cms_db_prefix().$this->table_prefix."users where uniqueid = ?";
  $record["uniqueid"] = $params['uniqueid'];
  $dbresult = $db->Execute($query, $record);
  if( !$dbresult || ( $dbresult->RecordCount() == 0 ) )
    {
      $this->_DisplayErrorPage( $id, $params, $returnid,
$this->Lang('error_invaliduniqueid'));
      return;
    }

----------------------- end old code ---------------

to


--------------------- start new code ---------------------

if( !isset( $params['email'] ) )
  {
    $this->_DisplayErrorPage( $id, $params, $returnid,
      $this->Lang('error_insufficientparams'));
   
    return;
  }

  $db = $this->GetDb();
  $query = "SELECT * from ".cms_db_prefix().$this->table_prefix."users where email = ?";
  $record["email"] = $params['email'];
  $dbresult = $db->Execute($query, $record);
  if( !$dbresult || ( $dbresult->RecordCount() == 0 ) )
    {
      $this->_DisplayErrorPage( $id, $params, $returnid,
$this->Lang('error_invalidemail'));
      return;
    }



--------------------- end new code -------------------------


this made the unsubscribe work for me on version 1.0.1 of NMS with the latest SVN fixes version 119 of action_unsubscribe_email.php
and 1.0.8 of CMS

could somebody check this into SVN , as I do not have access
NomadSoul
Forum Members
Forum Members
Posts: 24
Joined: Tue Jul 25, 2006 12:45 am

Re: Unsubscribe from NMS or newsletter alternative [SOLVED]

Post by NomadSoul »

that worked for me!

Changes in file action_unsubscribe_email.php :
namloc wrote:
change the following code at the start of the file


------------------- start old code -----------------------

if( !isset( $params['uniqueid'] ) )
  {
    $this->_DisplayErrorPage( $id, $params, $returnid,
      $this->Lang('error_insufficientparams'));
    return;
  }

  $db = $this->GetDb();

  $query = "SELECT * from ".cms_db_prefix().$this->table_prefix."users where uniqueid = ?";
  $record["uniqueid"] = $params['uniqueid'];
  $dbresult = $db->Execute($query, $record);
  if( !$dbresult || ( $dbresult->RecordCount() == 0 ) )
    {
      $this->_DisplayErrorPage( $id, $params, $returnid,
$this->Lang('error_invaliduniqueid'));
      return;
    }

----------------------- end old code ---------------

to


--------------------- start new code ---------------------

if( !isset( $params['email'] ) )
  {
    $this->_DisplayErrorPage( $id, $params, $returnid,
      $this->Lang('error_insufficientparams'));
   
    return;
  }

  $db = $this->GetDb();
  $query = "SELECT * from ".cms_db_prefix().$this->table_prefix."users where email = ?";
  $record["email"] = $params['email'];
  $dbresult = $db->Execute($query, $record);
  if( !$dbresult || ( $dbresult->RecordCount() == 0 ) )
    {
      $this->_DisplayErrorPage( $id, $params, $returnid,
$this->Lang('error_invalidemail'));
      return;
    }



--------------------- end new code -------------------------
Thank You namloc !
Last edited by NomadSoul on Sun Oct 07, 2007 11:53 pm, edited 1 time in total.
calguy1000
Support Guru
Support Guru
Posts: 8169
Joined: Tue Oct 19, 2004 6:44 pm

Re: Unsubscribe from NMS or newsletter alternative

Post by calguy1000 »

Soon (hopefully November) I will be catching up on the NMS issues (hopefully) however I won't be searching through the forum to find solved vs. unsolved NMS issues.

so please put an item into the forge under the NMS project for everything that needs fixing.
and if that includes a patch, it's even better.

I'd also like to get external vs embedded images into the next version.

funny thing, Is, I don't even use it.
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Post Reply

Return to “Modules/Add-Ons”