[pmwiki-users] FAST Data Project Addon

The Editor editor at fast.st
Fri Aug 11 11:14:58 CDT 2006

I've been doing more work to the FAST Data Project hoping to add
capabilities for emailing data, enabling chat/shoutboxes, creating
members accounts, doing authentication, etc.  The flexibility of it
gives it some exciting capabilities.

Anyway, I'm trying to debug a frustrating bit of code for the
authentication process.  Seemingly, Pass1 is retrieved from the form
properly, and Pass2 is retrieved from that members info page properly.
 When I uncomment the debugging line, I get "testtest" exactly what I
would expect. In the source code there are no spaces, or anything else
out of the ordinary.

Yet the conditional immediately after fails.  Any suggestions for why
"test" should not equal "test"?  Here's the relevant part of the

case "login" :
 	 if ($dr = fopen("$WorkDir/Data-Account.$_POST[Member]", "rb")){
		$pc = fread($dr, filesize("$WorkDir/Data-Account.$_POST[Member]"));
		$dc = explode("(:comment data:) %0a%0a", $pc);
		$db = explode(" %0a%0a", $dc[1]);
		$dv = explode ("=", $db[1]);
		$pass1 = stripslashes("$dv[1]");
		$pass2 = $_POST[Password];
//	        Redirect(FmtPageName("$pagename?myname=$pass1.$pass2", $pagename));
		if ($pass1 == $pass2) {
		       AuthUserId($pagename, $_POST[Member]);
		       Redirect(FmtPageName("Members.Members", $pagename));

Any help anyone could suggest, I'd appreciate!


More information about the pmwiki-users mailing list