Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> NSN Other
Author Message
srhh
Involved
Involved



Joined: Dec 27, 2005
Posts: 296

PostPosted: Tue Oct 10, 2006 4:06 pm Reply with quote

I just installed the NSN Mailing list. I try to sign up for a list, then click on the validation link it send to my e-mail. I get a page saying "The link is not valid!"
Any ideas?


Last edited by srhh on Thu Oct 19, 2006 11:10 pm; edited 1 time in total 
View user's profile Send private message
srhh







PostPosted: Tue Oct 10, 2006 4:13 pm Reply with quote

I just checked my database and the information is getting to the database, it just isn't validating and thus doesn't show me as a subscriber.
 
kguske
Site Admin



Joined: Jun 04, 2004
Posts: 6437

PostPosted: Tue Oct 10, 2006 8:18 pm Reply with quote

Are you tapped (i.e. using a URL rewriting scheme)?

_________________
I search, therefore I exist...
Only registered users can see links on this board! Get registered or login!
 
View user's profile Send private message
srhh







PostPosted: Tue Oct 10, 2006 8:39 pm Reply with quote

I would have to say 'no' cuz I have no idea what that is. Smile

I do vaguly remember something about URL rewriting when I installed Gallery. I think it said to turn it off.
Maybe I'm confused.
Wait, no scratch that. I'm definatly confused.

Wink
 
srhh







PostPosted: Tue Oct 10, 2006 8:41 pm Reply with quote

I'm on RN 2.02.02, btw.
 
srhh







PostPosted: Tue Oct 10, 2006 8:45 pm Reply with quote

Ooo, I think I'm onto something. I don't think the clicky-URL in the email is being formated right. Here is the URL I got:
http://www.mysite.com/nukesite//modules.php?name=Mailing_List&op=MLActivate&email=myemail@yahoo.com&lid=1&check=1072713987

Now if you look, there are two of "/" after the .com/nukesite
I took out the extra / and I still get the invalid link error.
 
srhh







PostPosted: Thu Oct 19, 2006 1:23 pm Reply with quote

*bump*

Anyone? I reformated my $nukeurl so there wasn't that extra "\" and still no go. Also tried re-uploaded and re-installing to.

So here is the code from modules/Mailing_List/public/MLAction.php that first puts together the confirmation URL
Code:


$pagetitle = " - "._ML_TITLE." ".$ml_config['version_number'];
include("header.php");
title(_ML_TITLE." ".$ml_config['version_number']);
OpenTable();
if(!preg_match("/@/", $email)) {
  echo "<center><b>"._ML_ERROR_INVALID."</b></center><br>";
  echo "<center>"._GOBACK."</center>";
} elseif($sub == 'sub') {
  $mid = $db->sql_numrows($db->sql_query("SELECT * FROM `".$prefix."_nsnml_users` WHERE `email`='$email' AND `lid`='$lid'"));
  if($mid > 0) {
    echo "<center><b>"._ML_ERROR_ALREADY."</b></center><br>";
    echo "<center>"._GOBACK."</center>";
  } else {
    srand ((double)microtime()*1000000);
    $mycode = rand();
    $joined = time();
    $query = "INSERT INTO `".$prefix."_nsnml_users` VALUES (NULL, '$lid', '$email', '0', '$type', '$mycode', '$joined')";
    if(!$db->sql_query($query)) {
      $result = $db->sql_error($query);
      echo "<center><b>".$result['code'].": ".$result['message']."</b></center>\n";
    } else {
      $buildlink = "$nukeurl/modules.php?name=$module_name&op=MLActivate&email=$email&lid=$lid&check=$mycode";
      mail($email, _ML_SUBSCRIPTION, _ML_CONFIGTEXT."\n\n$buildlink", "From: $adminmail");
      echo "<center><b>"._ML_CONFIRSENT."</b></center><br>";
      echo "<center>"._GOBACK."</center>";
    }

I'm getting the confirmation e-mail and URL correctly. (I compared it with another functioning Mailing List system)
and here is the code from modules/Mailing_List/MLActivate.php:
Code:


$pagetitle = " - "._ML_TITLE." ".$ml_config['version_number'];
include("header.php");
title(_ML_TITLE." ".$ml_config['version_number']);
OpenTable();
$query2 = "UPDATE `".$prefix."_nsnml_users` SET `active`='1', `act_key`='0', `joined`='".time()."' WHERE `email`='$email' AND `lid`='$lid'";
$result = $db->sql_query("SELECT * FROM `".$prefix."_nsnml_users` WHERE `email`='$email' AND `act_key`='$check' AND `lid`='$lid'");
if($db->sql_numrows($result) != 1) {
  echo "<center><b>"._ML_ERROR_SUBLINK."</b></center>";
} elseif(!$db->sql_query($query2)) {
   $result = $db->sql_error($query);
   echo "<center><b>".$result['code'].": ".$result['message']."</b></center>\n";
} else {
  $result = $db->sql_query("SELECT * FROM `".$prefix."_nsnml_lists` WHERE `lid`='$lid'");
  $list_info = $db->sql_fetchrow($result);
  echo "<center><b>"._ML_MAIN."</b>: ".$list_info['title']."<br>\n";
  echo "<b>"._ML_SUBCOMPLETED."</b></center>";
}
CloseTable();
include("footer.php");

My feeling is the problem is from the MLActivate.php and the fact I'm on a subdomain, but just can't track it down.
 
srhh







PostPosted: Thu Oct 19, 2006 1:32 pm Reply with quote

I like trying to figure things out, so in MLActivate.php, this is what is calling up the invalid link error, right?
Code:


if($db->sql_numrows($result) != 1) {
  echo "<center><b>"._ML_ERROR_SUBLINK."</b></center>";


But I'm stuck on what ever that means. It's not reading the database correctly ?
 
srhh







PostPosted: Thu Oct 19, 2006 11:09 pm Reply with quote

Interesting.
It works now.

I de-activated an add-on module that I guess was causing conflicts.
In the words of the immortal Rodney King, Why can't we all just get along?
Wink
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> NSN Other

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©