some bug fix in scripts
authordinesh <dinesh@dinesh-laptop>
Thu, 14 Aug 2008 06:52:37 +0000 (12:22 +0530)
committerdinesh <dinesh@dinesh-laptop>
Thu, 14 Aug 2008 06:52:37 +0000 (12:22 +0530)
web/functions.php
web/requestid.php

index 4228c3ae430242b798dd4695fad5cd4ddcd7deea..4b89fa5a38bd3748edb602efac515e681c616595 100644 (file)
@@ -36,7 +36,7 @@ function getccanadmin($db)
        $result = sqlite3_query($handle, $query) or die("Error in query: ".sqlite3_error($handle));
 
        while ($row = sqlite3_fetch_array($result))
-        $admin = $admin.$row[0].",";
+        $admin = $admin.$row['email'].",";
    return $admin; 
 }
-?>
\ No newline at end of file
+?>
index eedada5323a8cce107171a8630588fd7d459cbe3..3d293ddd074fb99d391b15762068709969cfe2e4 100644 (file)
@@ -3,6 +3,7 @@ session_start();
 include('logo.html');
 include('menulist.html');
 include('configuration');
+include('functions.php');
 
 if(isset($_POST['submit'])) {
        $name = $_REQUEST['name'];
@@ -80,7 +81,7 @@ $result = sqlite3_exec($handle, $query) or die("Error in query: ".sqlite3_error(
 
 $subject = "Approval of ccan account";
 $message = "There is new request for ccan account id.\n\n Please use the following link to approve http://ccan.ozlabs.org/dinesh/approval.php?accountid=".$accountid;
-mail($ccan_admin, $subject, $message, "From: $email");
+mail(getccanadmin($db), $subject, $message, "From: $email");
 ?>
        </br><div>Thank you for registering with CCAN. You will get the password to your mail after approval.</div>
 <?php