phpslash-commit Mailing List for phpSlash (Page 89)
Brought to you by:
joestewart,
nhruby
You can subscribe to this list here.
2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(11) |
Nov
(59) |
Dec
(60) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2002 |
Jan
(52) |
Feb
(77) |
Mar
(118) |
Apr
(76) |
May
(106) |
Jun
(145) |
Jul
(9) |
Aug
(15) |
Sep
(78) |
Oct
(83) |
Nov
(105) |
Dec
(51) |
2003 |
Jan
(105) |
Feb
(100) |
Mar
(111) |
Apr
(149) |
May
(95) |
Jun
(56) |
Jul
(8) |
Aug
(2) |
Sep
|
Oct
(22) |
Nov
(117) |
Dec
(6) |
2004 |
Jan
(1) |
Feb
|
Mar
(3) |
Apr
(25) |
May
|
Jun
(11) |
Jul
(26) |
Aug
(85) |
Sep
(119) |
Oct
(312) |
Nov
(271) |
Dec
(5) |
2005 |
Jan
(6) |
Feb
|
Mar
|
Apr
(12) |
May
(7) |
Jun
(8) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2009 |
Jan
(5) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Joe S. <joe...@us...> - 2002-05-21 15:08:17
|
Update of /cvsroot/phpslash/phpslash-ft/public_html/templates/en/basic In directory usw-pr-cvs1:/tmp/cvs-serv16069/phpslash-ft/public_html/templates/en/basic Modified Files: loginformCR.tpl Log Message: reg or log authmode Index: loginformCR.tpl =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/templates/en/basic/loginformCR.tpl,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** loginformCR.tpl 20 May 2002 21:59:56 -0000 1.4 --- loginformCR.tpl 21 May 2002 15:02:04 -0000 1.5 *************** *** 69,74 **** --- 69,76 ---- </script> </div> + <!-- BEGIN reg_block --> <div align="center">Don't have an account yet? Use our <a href="{PHP_SELF}?login=yes&mode=reg">Registration form</a> </div> + <!-- END reg_block --> <!-- id="loginForm" --> <!-- end loginformCR.tpl --> |
From: Joe S. <joe...@us...> - 2002-05-21 15:08:17
|
Update of /cvsroot/phpslash/phpslash-ft/class In directory usw-pr-cvs1:/tmp/cvs-serv16069/phpslash-ft/class Modified Files: slashAuthCR.class Log Message: reg or log authmode Index: slashAuthCR.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/slashAuthCR.class,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** slashAuthCR.class 20 May 2002 21:59:56 -0000 1.9 --- slashAuthCR.class 21 May 2002 15:02:04 -0000 1.10 *************** *** 29,37 **** $this->psl = $_PSL; - // if( !empty($_PSL['authmode'])) { - // $mode = $_PSL['authmode']; - // } if ($mode=='reg') { ! $this->mode='reg'; } else { $this->mode='log'; --- 29,38 ---- $this->psl = $_PSL; if ($mode=='reg') { ! if( !empty($_PSL['authmode'])) { ! $this->mode = $_PSL['authmode']; ! } else { ! $this->mode='reg'; ! } } else { $this->mode='log'; *************** *** 70,79 **** $templ->set_var('ERROR', ""); } ! slashhead("Login", "Login"); $templ->pparse('OUT',"form"); slashfoot(); } ! /* function auth_preauth() { --- 71,84 ---- $templ->set_var('ERROR', ""); } ! ! $templ->set_block("form","reg_block","regblock"); ! if( $_PSL['authmode'] == "reg") { ! $templ->parse("regblock", "reg_block", true); ! } slashhead("Login", "Login"); $templ->pparse('OUT',"form"); slashfoot(); } ! function auth_preauth() { *************** *** 119,123 **** } ! */ function auth_validatelogin() { --- 124,128 ---- } ! function auth_validatelogin() { |
From: Joe S. <joe...@us...> - 2002-05-21 15:08:16
|
Update of /cvsroot/phpslash/phpslash-ft/public_html In directory usw-pr-cvs1:/tmp/cvs-serv16069/phpslash-ft/public_html Modified Files: config.php3 Log Message: reg or log authmode Index: config.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/config.php3,v retrieving revision 1.139 retrieving revision 1.140 diff -C2 -d -r1.139 -r1.140 *** config.php3 20 May 2002 19:52:48 -0000 1.139 --- config.php3 21 May 2002 15:02:03 -0000 1.140 *************** *** 380,383 **** --- 380,389 ---- ////////////////////////////////////////////////////////////////////////// + // 2.1) PHPLIB Auth Class extension + + // allow self registration. + // set to 'reg' for self registration, 'log' otherwise. + $_PSL['authmode'] = 'reg'; + // 2.1) PHPLIB DB Class extension |
From: Joe S. <joe...@us...> - 2002-05-21 15:08:16
|
Update of /cvsroot/phpslash/phpslash-ft In directory usw-pr-cvs1:/tmp/cvs-serv16069/phpslash-ft Modified Files: CHANGES Log Message: reg or log authmode Index: CHANGES =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/CHANGES,v retrieving revision 1.490 retrieving revision 1.491 diff -C2 -d -r1.490 -r1.491 *** CHANGES 20 May 2002 22:03:47 -0000 1.490 --- CHANGES 21 May 2002 15:02:03 -0000 1.491 *************** *** 14,17 **** --- 14,21 ---- 2002-May-20 5:00PM CDT Joe Stewart <joe...@us...> + [ET] - slashAuthCR.class, config.php3, loginformCR.tpl - use of authmode + variable to set reg or log mode. + + 2002-May-20 5:00PM CDT Joe Stewart <joe...@us...> [ET] - slashAuthCR.class, config.php3, loginformCR.tpl, registerform.tpl began test of reg mode. |
From: Joe S. <joe...@us...> - 2002-05-21 15:08:13
|
Update of /cvsroot/phpslash/phpslash-ft/public_html/templates/en/default In directory usw-pr-cvs1:/tmp/cvs-serv16069/phpslash-ft/public_html/templates/en/default Modified Files: loginformCR.tpl Log Message: reg or log authmode Index: loginformCR.tpl =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/templates/en/default/loginformCR.tpl,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** loginformCR.tpl 20 May 2002 21:59:56 -0000 1.4 --- loginformCR.tpl 21 May 2002 15:02:04 -0000 1.5 *************** *** 69,73 **** // --> </script> <center><font size="-1" face="verdana,arial,helvetica,san-serif">Don't have an account yet? Use our <a href="{PHP_SELF}?login=yes&mode=reg">Registration form</font></a> </center> ! --- 69,74 ---- // --> </script> + <!-- BEGIN reg_block --> <center><font size="-1" face="verdana,arial,helvetica,san-serif">Don't have an account yet? Use our <a href="{PHP_SELF}?login=yes&mode=reg">Registration form</font></a> </center> ! <!-- END reg_block --> |
From: Joe S. <joe...@us...> - 2002-05-20 22:03:50
|
Update of /cvsroot/phpslash/phpslash-ft/doc/html In directory usw-pr-cvs1:/tmp/cvs-serv17476/phpslash-ft/doc/html Modified Files: phpslash.sgml Log Message: reg mode Index: phpslash.sgml =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/doc/html/phpslash.sgml,v retrieving revision 1.27 retrieving revision 1.28 diff -C2 -d -r1.27 -r1.28 *** phpslash.sgml 20 May 2002 21:37:04 -0000 1.27 --- phpslash.sgml 20 May 2002 22:03:48 -0000 1.28 *************** *** 751,757 **** --- 751,762 ---- <tscreen><code> + authorEmailLostPW.tpl + authorList.tpl + authorProfile.tpl framedbox.tpl loginblock.tpl + loginformCR.tpl navbarBlock.tpl + registerform.tpl openbox.tpl </code></tscreen> *************** *** 1308,1312 **** --- 1313,1319 ---- articleEmailSubject.tpl articleEmailToAddress.tpl + authorEmailLostPW.tpl - email confirmation link authorList.tpl - list of authors in authorAdmin + authorProfile - User Profile page authorNew.tpl - manage authors in authorAdmin backendBlock.tpl - %% delimited text *************** *** 1375,1378 **** --- 1382,1386 ---- queryblock.tpl - format of query block contents quoteblock.tpl - format of quote block contents + registerform.tpl - registration page searchPage.tpl - search page layout sectionList.tpl - list of sections in sectionAdmin |
From: Joe S. <joe...@us...> - 2002-05-20 22:03:50
|
Update of /cvsroot/phpslash/phpslash-ft In directory usw-pr-cvs1:/tmp/cvs-serv17476/phpslash-ft Modified Files: CHANGES Log Message: reg mode Index: CHANGES =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/CHANGES,v retrieving revision 1.489 retrieving revision 1.490 diff -C2 -d -r1.489 -r1.490 *** CHANGES 20 May 2002 21:59:55 -0000 1.489 --- CHANGES 20 May 2002 22:03:47 -0000 1.490 *************** *** 16,19 **** --- 16,20 ---- [ET] - slashAuthCR.class, config.php3, loginformCR.tpl, registerform.tpl began test of reg mode. + [D] - phpslash.sgml - template changes 2002-May-20 4:30PM CDT Joe Stewart <joe...@us...> |
From: Joe S. <joe...@us...> - 2002-05-20 22:00:00
|
Update of /cvsroot/phpslash/phpslash-ft/class In directory usw-pr-cvs1:/tmp/cvs-serv16412/phpslash-ft/class Modified Files: slashAuthCR.class Log Message: reg mode Index: slashAuthCR.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/slashAuthCR.class,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** slashAuthCR.class 20 May 2002 19:54:17 -0000 1.8 --- slashAuthCR.class 20 May 2002 21:59:56 -0000 1.9 *************** *** 26,32 **** function slashAuth() { ! global $_PSL; $this->psl = $_PSL; } --- 26,41 ---- function slashAuth() { ! global $_PSL, $mode; $this->psl = $_PSL; + // if( !empty($_PSL['authmode'])) { + // $mode = $_PSL['authmode']; + // } + if ($mode=='reg') { + $this->mode='reg'; + } else { + $this->mode='log'; + } + } *************** *** 66,70 **** slashfoot(); } ! function auth_preauth() { --- 75,79 ---- slashfoot(); } ! /* function auth_preauth() { *************** *** 110,114 **** } ! function auth_validatelogin() { --- 119,123 ---- } ! */ function auth_validatelogin() { *************** *** 200,203 **** --- 209,363 ---- return false; } + + function auth_registerform() { + global $sess; + + $templ = new Template($this->psl['templatedir']); + $templ->set_file(array( + form => "registerform.tpl" + )); + + $templ->set_var(ACTION_URL,$this->psl['rooturl']."/login.php3?mode=reg"); + $templ->set_var(PHP_SELF,$this->psl[phpself]); + if (isset($this->auth["uname"])) { + $templ->set_var(USERNAME,$this->auth['uname']); + } else { + $templ->set_var(USERNAME,""); + $this->auth["error"] = ""; + } + if (isset($this->auth["email"])) { + $templ->set_var(EMAIL,$this->auth["email"]); + } else { + $templ->set_var(EMAIL,""); + } + if (isset($this->auth["realname"])) { + $templ->set_var(REALNAME,$this->auth["realname"]); + } else { + $templ->set_var(REALNAME,""); + } + if (isset($this->auth["url"])) { + $templ->set_var(URL,$this->auth["url"]); + } else { + $templ->set_var(URL,""); + } + if (isset($this->auth["quote"])) { + $templ->set_var(QUOTE,$this->auth["quote"]); + } else { + $templ->set_var(QUOTE,""); + } + if (isset($this->auth["seclev"])) { + $templ->set_var(SECLEV,$this->auth["seclev"]); + } else { + $templ->set_var(SECLEV,""); + } + + if (isset($this->auth["error"])) { + $templ->set_var(ERROR,$this->auth["error"]); + } else { + $templ->set_var(ERROR,""); + } + slashhead("Register", "Register"); + $templ->pparse(OUT,"form"); + slashfoot(); + } + + + function auth_doregister() { + + global $username,$pass1, $pass2, $realname, $email, $mode; + global $password, $url, $quote, $seclev, $HTTP_POST_VARS; + + # the login form will save the username + $this->auth["uname"] = $username; + $this->auth["realname"] = $realname; + $this->auth["email"] = $email; + $this->auth["url"] = $url; + $this->auth["quote"] = $quote; + $this->auth["seclev"] = $seclev; + + + if ($username == "" || $pass1 == ""){ + $this->auth["error"] = "Username or password missing. Please try again."; + return false; + } + + // $debug = true; + + ## Check the passwords for validity. + if ($pass1 != $pass2) { + $this->auth["error"] = "Password and repeated password do not match. Please try again."; + return false; + } + if (($pass1 == "") OR ($pass2 == "")) { + $this->auth["error"] = "Please enter your password."; + return false; + + } + + # assume the check is gonna fail + $uid = false; + + $q = "SELECT * + FROM psl_author + WHERE author_name = '$username' "; + + # debug ("QUERY", $q); + + $this->db->query($q); + + while ($this->db->next_record()) { + ## If user is present and password matches, silently log + ## the user in. + if ($this->db->f("password") == md5($username .":". $pass1)) { + $uid = $this->db->f("author_id"); + $this->auth["uid"] = $this->db->f("author_id"); + $this->auth["uname"] = $this->db->f("author_name"); + $this->auth["perm"] = $this->db->f("perms"); + $this->auth["email"] = $this->db->f("email"); + $this->auth["realname"] = $this->db->f("realname"); + return $uid; + } + ## If user is present and password does not match, + ## complain and fail. + $this->auth["error"] = "This username is already taken. Please choose a different one."; + return false; + + } + + // add new user + $author = new Author; + $ary["author_name"] = $username; + $ary["password"] = $pass1; + $ary["email"] = $email; + $ary["url"] = $url; + $ary["quote"] = $quote; + $ary["author_realname"] = $realname; + $ary["seclev"] = $seclev; + $perm_ary = array("nobody", + "user"); + + $ary["permission"] = $perm_ary; + + // use Author.class saveStory for account creation + if ($author->saveAuthor($ary)) { + // $password = $pass1; + $HTTP_POST_VARS['username'] = $username; + $HTTP_POST_VARS['password'] = $pass1; + $HTTP_POST_VARS['challenge'] = md5(uniqid($this->magic)); + $HTTP_POST_VARS['response'] = ''; + // debug("username", $username); + // debug("pass1", $pass1); + $uid = $this->auth_validatelogin(); + if( $uid == false) { + $this->auth["error"] = "Account created, but validation failed"; + } + return $uid; + } else { + $this->auth["error"] = "User Registration failed"; + return false; + } + + } + } |
From: Joe S. <joe...@us...> - 2002-05-20 22:00:00
|
Update of /cvsroot/phpslash/phpslash-ft/public_html/templates/en/basic In directory usw-pr-cvs1:/tmp/cvs-serv16412/phpslash-ft/public_html/templates/en/basic Modified Files: loginformCR.tpl Added Files: registerform.tpl Log Message: reg mode --- NEW FILE: registerform.tpl --- <h3>Welcome to the Registration Page!</h3> <p>Please choose a username and a password. If you already have an account, use our <a href="{PHP_SELF}?mode=log">login form</a></p> <form action="{ACTION_URL}" method=post> <p class="error">{ERROR}</p> <table border=0 align="center" cellspacing=0 cellpadding=4> <tr> <td class="descr">Username:</td> <td><input type="text" name="username" value="{USERNAME}" size=32 maxlength=32></td> </tr> <tr> <td class="descr">Full Name:</td> <td><input type="text" name="realname" value="{REALNAME}" size=32 maxlength=32></td> </tr> <tr> <td class="descr">Email:</td> <td><input type="text" name="email" value="{EMAIL}" size=32 maxlength=32></td> </tr> <tr> <td class="descr">Password:</td> <td><input type="password" name="pass1" value="" size=32 maxlength=32></td> </tr> <tr> <td class="descr">Confirm Password:</td> <td><input type="password" name="pass2" value="" size=32 maxlength=32></td> </tr> <td> </td> <td align=right><input type="submit" name="submit" value="Register now"> <input type="submit" name="cancel" value="Cancel Login"></td> </tr> </table> Index: loginformCR.tpl =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/templates/en/basic/loginformCR.tpl,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** loginformCR.tpl 20 May 2002 19:55:19 -0000 1.3 --- loginformCR.tpl 20 May 2002 21:59:56 -0000 1.4 *************** *** 68,72 **** // --> </script> ! </div> <!-- id="loginForm" --> <!-- end loginformCR.tpl --> --- 68,75 ---- // --> </script> ! </div> ! <div align="center">Don't have an account yet? Use our <a href="{PHP_SELF}?login=yes&mode=reg">Registration form</a> ! </div> ! <!-- id="loginForm" --> <!-- end loginformCR.tpl --> |
From: Joe S. <joe...@us...> - 2002-05-20 22:00:00
|
Update of /cvsroot/phpslash/phpslash-ft In directory usw-pr-cvs1:/tmp/cvs-serv16412/phpslash-ft Modified Files: CHANGES Log Message: reg mode Index: CHANGES =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/CHANGES,v retrieving revision 1.488 retrieving revision 1.489 diff -C2 -d -r1.488 -r1.489 *** CHANGES 20 May 2002 21:37:03 -0000 1.488 --- CHANGES 20 May 2002 21:59:55 -0000 1.489 *************** *** 13,16 **** --- 13,20 ---- 9 - Removal of something (kill -9 :) + 2002-May-20 5:00PM CDT Joe Stewart <joe...@us...> + [ET] - slashAuthCR.class, config.php3, loginformCR.tpl, registerform.tpl + began test of reg mode. + 2002-May-20 4:30PM CDT Joe Stewart <joe...@us...> [D] - phpslash.sgml - perms option suggested for Submission block. |
From: Joe S. <joe...@us...> - 2002-05-20 22:00:00
|
Update of /cvsroot/phpslash/phpslash-ft/public_html/templates/en/default In directory usw-pr-cvs1:/tmp/cvs-serv16412/phpslash-ft/public_html/templates/en/default Modified Files: loginformCR.tpl Added Files: registerform.tpl Log Message: reg mode --- NEW FILE: registerform.tpl --- <br><br> <p>Welcome to the Registration Page! Please choose a username and a password. If you already have an account, use our <a href="{PHP_SELF}?mode=log">login form</a></p> <form action="{ACTION_URL}" method="post"> <p><font color="#ff0000" size="-1" face="verdana,arial,helvetica,san-serif"> {ERROR}</font></p> <table border=0 bgcolor="#eeeeee" align="center" cellspacing=0 cellpadding=4> <tr valign=top align=left> <td>Username:</td> <td><input type="text" name="username" value="{USERNAME}" size=32 maxlength=32></td> </tr> <tr valign=top align=left> <td>Full Name:</td> <td><input type="text" name="realname" value="{REALNAME}" size=32 maxlength=32></td> </tr> <tr valign=top align=left> <td>Email:</td> <td><input type="text" name="email" value="{EMAIL}" size=32 maxlength=32></td> </tr> <tr valign=top align=left> <td>Password:</td> <td><input type="password" name="pass1" value="" size=32 maxlength=32></td> </tr> <tr valign=top align=left> <td>Confirm Password:</td> <td><input type="password" name="pass2" value="" size=32 maxlength=32></td> </tr> <td> </td> <td align=right><input type="submit" name="submit" value="Register now"> <input type="submit" name="cancel" value="Cancel"></td> </tr> </table> Index: loginformCR.tpl =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/templates/en/default/loginformCR.tpl,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** loginformCR.tpl 20 May 2002 19:55:19 -0000 1.3 --- loginformCR.tpl 20 May 2002 21:59:56 -0000 1.4 *************** *** 69,72 **** // --> </script> ! --- 69,73 ---- // --> </script> ! <center><font size="-1" face="verdana,arial,helvetica,san-serif">Don't have an account yet? Use our <a href="{PHP_SELF}?login=yes&mode=reg">Registration form</font></a> ! </center> |
From: Joe S. <joe...@us...> - 2002-05-20 21:37:06
|
Update of /cvsroot/phpslash/phpslash-ft In directory usw-pr-cvs1:/tmp/cvs-serv9414/phpslash-ft Modified Files: CHANGES Log Message: submission block documentation Index: CHANGES =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/CHANGES,v retrieving revision 1.487 retrieving revision 1.488 diff -C2 -d -r1.487 -r1.488 *** CHANGES 20 May 2002 19:59:10 -0000 1.487 --- CHANGES 20 May 2002 21:37:03 -0000 1.488 *************** *** 13,17 **** 9 - Removal of something (kill -9 :) ! 2002-May-20 2:30AM CDT Joe Stewart <joe...@us...> [B] - submission.php3 - changed title to "Submission." [FT] - config.php3, profile.php3, authorProfile.tpl - user profile page. --- 13,20 ---- 9 - Removal of something (kill -9 :) ! 2002-May-20 4:30PM CDT Joe Stewart <joe...@us...> ! [D] - phpslash.sgml - perms option suggested for Submission block. ! ! 2002-May-20 2:30PM CDT Joe Stewart <joe...@us...> [B] - submission.php3 - changed title to "Submission." [FT] - config.php3, profile.php3, authorProfile.tpl - user profile page. *************** *** 20,24 **** Preauth cookie ( Stay logged in) and lost password email. ! 2002-May-20 12:00AM CDT Joe Stewart <joe...@us...> [F] - Block_render_submission.class - display submission queue in a block. [FT] - Block_render_login.class, loginblock.tpl - added login/logout --- 23,27 ---- Preauth cookie ( Stay logged in) and lost password email. ! 2002-May-20 12:00PM CDT Joe Stewart <joe...@us...> [F] - Block_render_submission.class - display submission queue in a block. [FT] - Block_render_login.class, loginblock.tpl - added login/logout |
From: Joe S. <joe...@us...> - 2002-05-20 21:37:06
|
Update of /cvsroot/phpslash/phpslash-ft/doc/html In directory usw-pr-cvs1:/tmp/cvs-serv9414/phpslash-ft/doc/html Modified Files: phpslash.sgml Log Message: submission block documentation Index: phpslash.sgml =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/doc/html/phpslash.sgml,v retrieving revision 1.26 retrieving revision 1.27 diff -C2 -d -r1.26 -r1.27 *** phpslash.sgml 20 May 2002 18:03:43 -0000 1.26 --- phpslash.sgml 20 May 2002 21:37:04 -0000 1.27 *************** *** 1034,1038 **** "home" link. <tag/Section/ Will give you a list of the sections with stories. ! <tag/Submission/ Will give you a list of the submissions in a block to a user with sufficient privileges. This block uses the submissionList.tpl and is too wide for a side column. Example use: --- 1034,1038 ---- "home" link. <tag/Section/ Will give you a list of the sections with stories. ! <tag/Submission/ Will give a list of the submissions in a block to a user with sufficient privileges. This block uses the submissionList.tpl and is too wide for a side column. Example use: *************** *** 1045,1050 **** <item> order number - "70" <item> block options: ! <item> column center ! <item> width 100% </itemize> <tag/Topics:/ Gives you a list of topics with stories. --- 1045,1051 ---- <item> order number - "70" <item> block options: ! <item> column - center ! <item> width - 100% ! <item> perms - submission </itemize> <tag/Topics:/ Gives you a list of topics with stories. |
From: Joe S. <joe...@us...> - 2002-05-20 19:59:13
|
Update of /cvsroot/phpslash/phpslash-ft/public_html In directory usw-pr-cvs1:/tmp/cvs-serv7668/phpslash-ft/public_html Modified Files: login.php3 Log Message: auth_preauth Index: login.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/login.php3,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** login.php3 14 Mar 2002 17:55:09 -0000 1.18 --- login.php3 20 May 2002 19:59:10 -0000 1.19 *************** *** 7,10 **** --- 7,11 ---- if (isset($HTTP_POST_VARS['cancel'])) { + $sess->delete(); Header("Location: " . $_PSL['rooturl'] ."/"); // go home die("\n"); // Kill script if not dead already, possible memory leak *************** *** 12,19 **** --- 13,31 ---- if (isset($HTTP_GET_VARS['logout'])) { + if(isset($HTTP_COOKIE_VARS['user_info'])) { + setcookie( 'user_info', '', time()-31536000, $this->psl['rooturl'], "", ""); + $sess->delete(); + $HTTP_COOKIE_VARS['user_info'] = ''; + } $username = $auth->auth['uname']; + $sess->delete(); // may be needed for phplib session4.inc $auth->auth["error"] = sprintf(pslgetText("%s logged out."), $username); $auth->auth['uid'] = 'nobody'; $auth->auth['perm'] = ""; + } + + if(isset($HTTP_POST_VARS['username'])) { // this would be present if a login is in progress + $auth->auth["uid"]= "form"; // this is what auth seems to want + $auth->start(); } |
From: Joe S. <joe...@us...> - 2002-05-20 19:59:13
|
Update of /cvsroot/phpslash/phpslash-ft In directory usw-pr-cvs1:/tmp/cvs-serv7668/phpslash-ft Modified Files: CHANGES Log Message: auth_preauth Index: CHANGES =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/CHANGES,v retrieving revision 1.486 retrieving revision 1.487 diff -C2 -d -r1.486 -r1.487 *** CHANGES 20 May 2002 19:54:17 -0000 1.486 --- CHANGES 20 May 2002 19:59:10 -0000 1.487 *************** *** 16,22 **** [B] - submission.php3 - changed title to "Submission." [FT] - config.php3, profile.php3, authorProfile.tpl - user profile page. ! [FT] - Author.class, authorAdmin.php3, slashAuthCR.class, authorList.tpl, ! loginformCR.tpl, authorEmailLostPW.tpl - Preauth cookie ! ( Stay logged in) and lost password email. 2002-May-20 12:00AM CDT Joe Stewart <joe...@us...> --- 16,22 ---- [B] - submission.php3 - changed title to "Submission." [FT] - config.php3, profile.php3, authorProfile.tpl - user profile page. ! [FT] - Author.class, authorAdmin.php3, slashAuthCR.class, login.php3, ! authorList.tpl, loginformCR.tpl, authorEmailLostPW.tpl - ! Preauth cookie ( Stay logged in) and lost password email. 2002-May-20 12:00AM CDT Joe Stewart <joe...@us...> |
From: Joe S. <joe...@us...> - 2002-05-20 19:55:22
|
Update of /cvsroot/phpslash/phpslash-ft/public_html/templates/en/basic In directory usw-pr-cvs1:/tmp/cvs-serv6590/phpslash-ft/public_html/templates/en/basic Modified Files: loginformCR.tpl Added Files: authorEmailLostPW.tpl Log Message: auth_preauth --- NEW FILE: authorEmailLostPW.tpl --- <!-- BEGIN to_block --> "{MAILTONAME}" <{MAILTOADDRESS}> <!-- END to_block --> <!-- BEGIN subject_block --> {SITE_NAME} Confimation <!-- END subject_block --> <!-- BEGIN headers_block --> From: "{SITE_NAME}" <{SITE_OWNER}> X-Sender: {SITE_NAME} <{ROOTURL}> X-Mailer: phpSlash X-Priority: 3 Return-Path: <{SITE_OWNER}> <!-- END headers_block --> <!-- BEGIN body_block --> Welcome to {SITE_NAME}. You can visit this web page to change your password: {ROOTURL}/profile.php3?confirm={CONFIRM} -------------------------------------------------- This message request was from: {REMOTE_ADDR} <!-- END body_block --> Index: loginformCR.tpl =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/templates/en/basic/loginformCR.tpl,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** loginformCR.tpl 9 Apr 2002 16:57:06 -0000 1.2 --- loginformCR.tpl 20 May 2002 19:55:19 -0000 1.3 *************** *** 12,15 **** --- 12,16 ---- document.logintrue.username.value = document.login.username.value; document.logintrue.response.value = MD5(str); + document.logintrue.setcookie.value = document.login.setcookie.value; document.logintrue.submit(); return false; *************** *** 39,42 **** --- 40,51 ---- </td> </tr> + <tr> + <td class="descr"><input type=checkbox name=setcookie></td> + <td class="descr">Remember me? ( Stay logged in from this computer)</td> + </tr> + <tr> + <td class="descr"><input type=checkbox name=lostpw></td> + <td class="descr">Oops, I lost my password.<br /> Send an email with a link that allows me to change my password</td> + </tr> </table> <input type="hidden" name="challenge" value="{CHALLENGE}" /> |
From: Joe S. <joe...@us...> - 2002-05-20 19:55:22
|
Update of /cvsroot/phpslash/phpslash-ft/public_html/templates/en/default In directory usw-pr-cvs1:/tmp/cvs-serv6590/phpslash-ft/public_html/templates/en/default Modified Files: loginformCR.tpl Added Files: authorEmailLostPW.tpl Log Message: auth_preauth --- NEW FILE: authorEmailLostPW.tpl --- <!-- BEGIN to_block --> "{MAILTONAME}" <{MAILTOADDRESS}> <!-- END to_block --> <!-- BEGIN subject_block --> {SITE_NAME} Confimation <!-- END subject_block --> <!-- BEGIN headers_block --> From: "{SITE_NAME}" <{SITE_OWNER}> X-Sender: {SITE_NAME} <{ROOTURL}> X-Mailer: phpSlash X-Priority: 3 Return-Path: <{SITE_OWNER}> <!-- END headers_block --> <!-- BEGIN body_block --> Welcome to {SITE_NAME}. You can visit this web page to change your password: {ROOTURL}/profile.php3?confirm={CONFIRM} -------------------------------------------------- This message request was from: {REMOTE_ADDR} <!-- END body_block --> Index: loginformCR.tpl =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/templates/en/default/loginformCR.tpl,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** loginformCR.tpl 23 Jan 2002 00:15:22 -0000 1.2 --- loginformCR.tpl 20 May 2002 19:55:19 -0000 1.3 *************** *** 10,13 **** --- 10,14 ---- document.logintrue.username.value = document.login.username.value; document.logintrue.response.value = MD5(str); + document.logintrue.setcookie.value = document.login.setcookie.value; document.logintrue.submit(); return false; *************** *** 15,19 **** // --> </script> ! <p>Welcome! <br> --- 16,20 ---- // --> </script> ! <font face="verdana,arial,helvetica,san-serif"> <p>Welcome! <br> *************** *** 22,42 **** <p>Please identify yourself with a username and a password:</p> <p><font color="#ff0000" size="-1" face="verdana,arial,helvetica,san-serif">{ERROR}</font></p> ! <form name="login" action="{ACTION_URL}" method=post onSubmit="doChallengeResponse()"> <table border=0 bgcolor="#eeeeee" align="center" cellspacing=0 cellpadding=4> <tr valign=top align=left> ! <td>Username:</td> <td><input type="text" name="username" value="{USERNAME}" size=32 maxlength=32></td> </tr> <tr valign=top align=left> ! <td>Password:</td> <td><input type="password" name="password" value="" size=32 maxlength=32></td> </tr> <tr> <td> </td> ! <td align=right><input type="submit" name="submit" value="Login now"> <input type="submit" name="cancel" value="Cancel Login"></td> ! </tr> </table> <input type="hidden" name="challenge" value="{CHALLENGE}"> --- 23,51 ---- <p>Please identify yourself with a username and a password:</p> <p><font color="#ff0000" size="-1" face="verdana,arial,helvetica,san-serif">{ERROR}</font></p> ! </font> <form name="login" action="{ACTION_URL}" method=post onSubmit="doChallengeResponse()"> <table border=0 bgcolor="#eeeeee" align="center" cellspacing=0 cellpadding=4> <tr valign=top align=left> ! <td><font size="-1" face="verdana,arial,helvetica,san-serif">Username:</font></td> <td><input type="text" name="username" value="{USERNAME}" size=32 maxlength=32></td> </tr> <tr valign=top align=left> ! <td><font size="-1" face="verdana,arial,helvetica,san-serif">Password:</font></td> <td><input type="password" name="password" value="" size=32 maxlength=32></td> </tr> <tr> <td> </td> ! <td align=left><input type="submit" name="submit" value="Login now"> <input type="submit" name="cancel" value="Cancel Login"></td> ! </tr> ! <tr> ! <td align=right><input type=checkbox name=setcookie></td> ! <td align=left><font size="-1" face="verdana,arial,helvetica,san-serif">Remember me? ( Stay logged in from this computer)</font></td> ! </tr> ! <tr> ! <td align=right><input type=checkbox name=lostpw></td> ! <td align=left><font size="-1" face="verdana,arial,helvetica,san-serif">Oops, I lost my password.<br /> Send an email with a link that allows me to change my password</font></td> ! </tr> </table> <input type="hidden" name="challenge" value="{CHALLENGE}"> *************** *** 48,51 **** --- 57,61 ---- <input type="hidden" name="challenge" value="{CHALLENGE}"> <input type="hidden" name="response" value=""> + <input type="hidden" name="setcookie" value=""> </form> <script language="JavaScript"> |
From: Joe S. <joe...@us...> - 2002-05-20 19:54:20
|
Update of /cvsroot/phpslash/phpslash-ft/public_html/templates/en/default In directory usw-pr-cvs1:/tmp/cvs-serv6220/phpslash-ft/public_html/templates/en/default Modified Files: authorList.tpl Log Message: auth_preauth Index: authorList.tpl =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/templates/en/default/authorList.tpl,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** authorList.tpl 11 Apr 2002 21:05:06 -0000 1.7 --- authorList.tpl 20 May 2002 19:54:17 -0000 1.8 *************** *** 20,24 **** <TD>{EMAIL}</TD> <TD>{QUOTE}</TD> ! <TD><a href="{ACTION_URL}?submit=edit{AMP}id={AUTHOR_ID}">Modify</a> || <a href="{ACTION_URL}?submit=delete{AMP}id={AUTHOR_ID}">Delete</a></TD> </TR> --- 20,25 ---- <TD>{EMAIL}</TD> <TD>{QUOTE}</TD> ! <TD><TD><a href="{ACTION_URL}?submit=lostpw{AMP}id={AUTHOR_ID}">Lost Password</a> ! ||<a href="{ACTION_URL}?submit=edit{AMP}id={AUTHOR_ID}">Modify</a> || <a href="{ACTION_URL}?submit=delete{AMP}id={AUTHOR_ID}">Delete</a></TD> </TR> *************** *** 33,37 **** <TD>{EMAIL}</TD> <TD>{QUOTE}</TD> ! <TD><a href="{ACTION_URL}?submit=edit{AMP}id={AUTHOR_ID}">Modify</a> || <a href="{ACTION_URL}?submit=delete{AMP}id={AUTHOR_ID}">Delete</a></TD> </TR> --- 34,39 ---- <TD>{EMAIL}</TD> <TD>{QUOTE}</TD> ! <TD><TD><a href="{ACTION_URL}?submit=lostpw{AMP}id={AUTHOR_ID}">Lost Password</a> ! ||<a href="{ACTION_URL}?submit=edit{AMP}id={AUTHOR_ID}">Modify</a> || <a href="{ACTION_URL}?submit=delete{AMP}id={AUTHOR_ID}">Delete</a></TD> </TR> |
From: Joe S. <joe...@us...> - 2002-05-20 19:54:20
|
Update of /cvsroot/phpslash/phpslash-ft/public_html/admin In directory usw-pr-cvs1:/tmp/cvs-serv6220/phpslash-ft/public_html/admin Modified Files: authorAdmin.php3 Log Message: auth_preauth Index: authorAdmin.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/admin/authorAdmin.php3,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** authorAdmin.php3 11 Apr 2002 21:05:06 -0000 1.5 --- authorAdmin.php3 20 May 2002 19:54:17 -0000 1.6 *************** *** 50,53 **** --- 50,63 ---- $author->listAuthor(); break; + case "lostpw": + $success = $author->lostpw($HTTP_GET_VARS, $auth->auth["uid"]); + if($success) { + echo message( pslgetText($author->message)); + } else { + error( pslgetText($author->message)); + } + $author->newAuthor(); + $author->listAuthor(); + break; case "update": case "new": |
From: Joe S. <joe...@us...> - 2002-05-20 19:54:20
|
Update of /cvsroot/phpslash/phpslash-ft/public_html/templates/en/basic In directory usw-pr-cvs1:/tmp/cvs-serv6220/phpslash-ft/public_html/templates/en/basic Modified Files: authorList.tpl Log Message: auth_preauth Index: authorList.tpl =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/templates/en/basic/authorList.tpl,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** authorList.tpl 9 Apr 2002 16:57:06 -0000 1.2 --- authorList.tpl 20 May 2002 19:54:17 -0000 1.3 *************** *** 22,25 **** --- 22,26 ---- <td>{QUOTE}</td> <td> + <a href="{ACTION_URL}?submit=lostpw{AMP}id={AUTHOR_ID}">Lost Password</a> || <a href="{ACTION_URL}?submit=edit{AMP}id={AUTHOR_ID}">Modify</a> || <a href="{ACTION_URL}?submit=delete{AMP}id={AUTHOR_ID}">Delete</a> *************** *** 36,39 **** --- 37,41 ---- <td>{QUOTE}</td> <td> + <a href="{ACTION_URL}?submit=lostpw{AMP}id={AUTHOR_ID}">Lost Password</a> || <a href="{ACTION_URL}?submit=edit{AMP}id={AUTHOR_ID}">Modify</a> || <a href="{ACTION_URL}?submit=delete{AMP}id={AUTHOR_ID}">Delete</a> |
From: Joe S. <joe...@us...> - 2002-05-20 19:54:20
|
Update of /cvsroot/phpslash/phpslash-ft/class In directory usw-pr-cvs1:/tmp/cvs-serv6220/phpslash-ft/class Modified Files: Author.class slashAuthCR.class Log Message: auth_preauth Index: Author.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Author.class,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** Author.class 13 Apr 2002 16:35:21 -0000 1.18 --- Author.class 20 May 2002 19:54:17 -0000 1.19 *************** *** 10,14 **** */ class Author { ! var $author_templ, $db, $perm, $psl; /** --- 10,14 ---- */ class Author { ! var $author_templ, $db, $perm, $psl, $auth; /** *************** *** 22,30 **** function Author () { ! global $perm, $_PSL; $this->db = new slashDB; $this->perm = $perm; $this->psl = $_PSL; /* Templates */ --- 22,31 ---- function Author () { ! global $perm, $_PSL, $auth; $this->db = new slashDB; $this->perm = $perm; $this->psl = $_PSL; + $this->auth = $auth; /* Templates */ *************** *** 483,487 **** * * @access public ! * @param $ary - permission array for futute use * @return author_array(id, name) */ --- 484,488 ---- * * @access public ! * @param $ary - permission array for future use * @return author_array(id, name) */ *************** *** 505,508 **** --- 506,613 ---- return $author_array; } + + /** + * lostpw - send confirmation email for login + * + * + * @access public + * @param $ary - HTTP_GET_VARS + * @return success state + */ + function lostpw($ary = "") { + + global $REMOTE_ADDR; + + $this->author_templ->set_file(array( + "author-lostpw" => "authorEmailLostPW.tpl" + )); + + if( $ary['id']) { + $q = "SELECT * + FROM psl_author + WHERE author_id = '$ary[id]' "; + } elseif( $ary['username']) { + $q = "SELECT * + FROM psl_author + WHERE author_name = '$ary[username]' "; + } else { + $this->message = "Missing Username or ID"; + return false; + } + + $this->db->query($q); + + if ($this->db->num_rows() == 0) { + $this->message = "Username not found"; + return false; + } + + if ($this->db->next_record()) { + + $cookie_challenge = md5($this->auth->magic .":". $this->psl['basedir']); + $md5_pw = $this->db->Record['password']; // this is the raw MD5ed user/pass combo + $cookie_response = md5("$md5_pw:$cookie_challenge"); + // replace the challenge with the date + $cookie_challenge = date("Ymd"); + $cookie_ary[] = $cookie_response; + $cookie_ary[] = $this->db->Record['author_name']; + $cookie_ary[] = $cookie_challenge; + $confirm_hash=serialize($cookie_ary); + $confirm_hash=base64_encode($confirm_hash); + $confirm_hash=urlencode($confirm_hash); + if(!is_valid_email($this->db->Record['email'])) { + $this->message = "Sorry the user's email address is not valid"; + return false; + } + $this->author_templ->set_var(array( + 'REMOTE_ADDR' => $REMOTE_ADDR, + 'CONFIRM' => $confirm_hash, + 'ROOTURL' => $this->psl['rooturl'], + 'MAILTONAME' => $this->db->Record['author_realname'], + 'MAILTOADDRESS' => $this->db->Record['email'], + 'SITE_NAME' => $this->psl['site_name'], + 'SITE_OWNER' => $this->psl['site_owner'] + )); + // parse the to_block to the mail_to variable + $this->author_templ->set_block("author-lostpw","to_block","mail_to"); + $this->author_templ->parse("mail_to", "to_block", true); + + $mail_to = trim($this->author_templ->get_var("mail_to")); + debug("mail_to", $mail_to); + + // parse the subject_block to the mail_subject variable + $this->author_templ->set_block("author-lostpw","subject_block","mail_subject"); + $this->author_templ->parse("mail_subject", "subject_block", true); + + $mail_subject = trim($this->author_templ->get_var("mail_subject")); + debug("mail_subject", $mail_subject); + + // parse the headers_block to the mail_headers variable + $this->author_templ->set_block("author-lostpw","headers_block","mail_headers"); + $this->author_templ->parse("mail_headers", "headers_block", true); + + $mail_headers = trim($this->author_templ->get_var("mail_headers")); + debug("mail_headers", $mail_headers); + + // parse the body_block to the mail_body variable + $this->author_templ->set_block("author-lostpw","body_block","mail_body"); + $this->author_templ->parse("mail_body", "body_block", true); + + $mail_body = $this->author_templ->get_var("mail_body"); + debug("mail_body", $mail_body); + + if(mail( $mail_to, $mail_subject, $mail_body, $mail_headers)) { + $this->message = "Email Confirmation sent"; + $success = true; + } else { + $this->message = "Email Confirmation failure"; + $success = false; + } + } + + return $success; + } + + } /* end of Author.class */ ?> Index: slashAuthCR.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/slashAuthCR.class,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** slashAuthCR.class 12 Apr 2002 15:44:21 -0000 1.7 --- slashAuthCR.class 20 May 2002 19:54:17 -0000 1.8 *************** *** 22,25 **** --- 22,34 ---- var $cancel_login = "cancel"; var $mode = "log"; + var $psl; + + function slashAuth() { + + global $_PSL; + + $this->psl = $_PSL; + + } function auth_loginform() { *************** *** 58,61 **** --- 67,114 ---- } + function auth_preauth() { + + global $HTTP_COOKIE_VARS; + + // debug("auth", "preauth"); + if( !empty($HTTP_COOKIE_VARS['user_info'])){ + + $cookie_challenge = md5($this->magic .":". $this->psl['basedir']); + + $cookie_ary = unserialize(base64_decode($HTTP_COOKIE_VARS['user_info'])); + + # assume the check is gonna fail + $uid = false; + + $q = "SELECT * + FROM psl_author + WHERE author_name = '$cookie_ary[1]' "; + + $this->db->query($q); + + if ($this->db->num_rows() == 0) { + return false; + } + + while ($this->db->next_record()) { + $this->auth["uname"] = $this->db->Record["author_name"]; + + $md5_pw = $this->db->Record['password']; // this is the raw MD5ed user/pass combo + $expected_response = md5("$md5_pw:$cookie_challenge"); + if( $expected_response == $cookie_ary[0]) { + // preauth successful + // debug("preauth", "successful"); + $this->auth["perm"] = $this->db->Record["perms"]; + return $this->db->Record["author_id"]; + } else { + // preauth failed + // debug("preauth", "failed"); + return false; + } + } + } + } + + function auth_validatelogin() { *************** *** 66,69 **** --- 119,124 ---- $challenge = $HTTP_POST_VARS['challenge']; $response = $HTTP_POST_VARS['response']; + $setcookie = $HTTP_POST_VARS['setcookie']; + $lostpw = $HTTP_POST_VARS['lostpw']; # the login form will save the username *************** *** 80,83 **** --- 135,146 ---- return false; } + + if( $lostpw) { + $author = new Author; + $ary['username'] = $username; + $success = $author->lostpw($ary); + $this->auth["error"] = $author->message; + return false; + } # assume the check is gonna fail *************** *** 113,124 **** // Response is set, JS might be enabled... ! if ($expected_response != $response) { $this->auth["error"] = "Either your username or password are invalid.<br>Please try again."; return false; } else { $this->auth["perm"] = $this->db->Record["perms"]; return $uid; ! } ! return false; } --- 176,198 ---- // Response is set, JS might be enabled... ! if ($expected_response != $response) { $this->auth["error"] = "Either your username or password are invalid.<br>Please try again."; return false; } else { $this->auth["perm"] = $this->db->Record["perms"]; + if(isset($setcookie)){ + $cookie_challenge = md5($this->magic .":". $this->psl['basedir']); + $md5_pw = $this->db->Record['password']; // this is the raw MD5ed user/pass combo + $cookie_response = md5("$md5_pw:$cookie_challenge"); + $cookie_ary[] = $cookie_response; + $cookie_ary[] = $this->auth['uname']; + $cookie_ary[] = $cookie_challenge; + + // setcookie( 'user_info', serialize($cookie_ary), time()+31536000, $this->psl['rooturl'], ereg_replace("www.", "", "$SERVER_NAME"), ""); + setcookie( 'user_info', base64_encode(serialize($cookie_ary)), time()+31536000,$this->psl['rooturl'] , "" , ""); + } return $uid; ! } ! return false; } |
From: Joe S. <joe...@us...> - 2002-05-20 19:54:20
|
Update of /cvsroot/phpslash/phpslash-ft In directory usw-pr-cvs1:/tmp/cvs-serv6220/phpslash-ft Modified Files: CHANGES Log Message: auth_preauth Index: CHANGES =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/CHANGES,v retrieving revision 1.485 retrieving revision 1.486 diff -C2 -d -r1.485 -r1.486 *** CHANGES 20 May 2002 17:52:46 -0000 1.485 --- CHANGES 20 May 2002 19:54:17 -0000 1.486 *************** *** 13,16 **** --- 13,23 ---- 9 - Removal of something (kill -9 :) + 2002-May-20 2:30AM CDT Joe Stewart <joe...@us...> + [B] - submission.php3 - changed title to "Submission." + [FT] - config.php3, profile.php3, authorProfile.tpl - user profile page. + [FT] - Author.class, authorAdmin.php3, slashAuthCR.class, authorList.tpl, + loginformCR.tpl, authorEmailLostPW.tpl - Preauth cookie + ( Stay logged in) and lost password email. + 2002-May-20 12:00AM CDT Joe Stewart <joe...@us...> [F] - Block_render_submission.class - display submission queue in a block. |
From: Joe S. <joe...@us...> - 2002-05-20 19:52:51
|
Update of /cvsroot/phpslash/phpslash-ft/public_html/templates/en/default In directory usw-pr-cvs1:/tmp/cvs-serv5669/phpslash-ft/public_html/templates/en/default Added Files: authorProfile.tpl Log Message: user profile --- NEW FILE: authorProfile.tpl --- <!-- authorProfile.tpl --> <FORM ACTION="{ACTION_URL}" METHOD=POST> <TABLE BORDER=0> <TR ALIGN=MIDDLE> <TD WIDTH=30> </TD> <TD> </TD> </TR> <TR> <TD><B>Name</B><FONT COLOR=RED></FONT></TD> <TD><INPUT type="hidden" name="author_name" value="{NAME}" SIZE="20"><b>{NAME}</b></TD> </TR> <TR> <TD><B>Real Name</B></TD> <TD><INPUT type="input" name="author_realname" value="{REALNAME}" SIZE="30"></TD> </TR> <TR> <TD><B>URL</B></TD> <TD><INPUT type="input" name="url" value="{URL}" SIZE="50"></TD> </TR> <TR> <TD><B>Email</B></TD> <TD><INPUT type="input" name="email" value="{EMAIL}" SIZE="50"></TD> </TR> <TR> <TD><B>Quote</B></TD> <TD><INPUT type="input" name="quote" value="{QUOTE}" SIZE="50"></TD> </TR> <TR> <TD><B>Password</B><FONT COLOR=RED></FONT></TD> <TD><INPUT type="password" name="password" value="{PASSWORD}" SIZE="10"></TD> </TR> </TABLE> <INPUT type="hidden" name="author_id" value="{AUTHOR_ID}"> <INPUT type="submit" name="submit" value="update"><HR> </FORM> <!-- authorProfile.tpl --> |
From: Joe S. <joe...@us...> - 2002-05-20 19:52:51
|
Update of /cvsroot/phpslash/phpslash-ft/public_html/templates/en/basic In directory usw-pr-cvs1:/tmp/cvs-serv5669/phpslash-ft/public_html/templates/en/basic Added Files: authorProfile.tpl Log Message: user profile --- NEW FILE: authorProfile.tpl --- <!-- start authorProfile.tpl --> <div id="authorProfile"> <form action="{ACTION_URL}" method="post"> <table border="0"> <tr> <td> </td> <td> </td> </tr> <tr> <td class="descr">Name <span class="must">*</span></td> <td><input type="text" name="author_name" value="{NAME}" size="20" /></td> </tr> <tr> <td class="descr">Real Name</td> <td><input type="text" name="author_realname" value="{REALNAME}" size="20" /></td> </tr> <tr> <td class="descr">URL</td> <td><input type="text" name="url" value="{URL}" size="15" /></td> </tr> <tr> <td class="descr">Email</td> <td><input type="text" name="email" value="{EMAIL}" size="15" /></td> </tr> <tr> <td class="descr">Quote</td> <td><input type="text" name="quote" value="{QUOTE}" size="20" /></td> </tr> <tr> <td class="descr">Password <span class="must">*</span></td> <td><input type="password" name="password" value="{PASSWORD}" size="10" /></td> </tr> </table> <input type="hidden" name="author_id" value="{AUTHOR_ID}" /> <input type="submit" name="submit" value="update" /> </form> <hr /> </div> <!-- id="authorProfile" --> <!-- end authorProfile.tpl --> |
From: Joe S. <joe...@us...> - 2002-05-20 19:52:51
|
Update of /cvsroot/phpslash/phpslash-ft/public_html In directory usw-pr-cvs1:/tmp/cvs-serv5669/phpslash-ft/public_html Modified Files: submission.php3 config.php3 Added Files: profile.php3 Log Message: user profile --- NEW FILE: profile.php3 --- <?php /* $Id: profile.php3,v 1.1 2002/05/20 19:52:48 joestewart Exp $ */ $pagetitle = "User Profile"; // header title $xsiteobject = "Profile"; // Defines The META TAG Page Type require("config.php3"); page_open(array("sess"=>"slashSess","auth"=>"slashAuth","perm"=>"slashPerm")); /***************************** START OF PAGE *****************************/ if ( $HTTP_GET_VARS['confirm']) { $confirm = $HTTP_GET_VARS['confirm']; $confirm_hash = base64_decode($confirm); $confirm_hash = unserialize($confirm_hash); // $confirm_hash = unserialize($HTTP_GET_VARS['confirm']); if($confirm_hash[2] == date("Ymd")) { $confirm_hash[2] = md5($auth->magic .":". $_PSL['basedir']); $HTTP_COOKIE_VARS['user_info'] = base64_encode(serialize($confirm_hash)); } } $auth->login_if(!$perm->have_perm('user')); slashhead($pagetitle,$xsiteobject); /* DEBUG */ /* debug("HTTP_POST_VARS", $HTTP_POST_VARS); debug("HTTP_GET_VARS", $HTTP_GET_VARS); debug("author_id_ary", $author_id_ary); debug("author_name_ary", $author_name_ary); debug("real_name_ary", $author_name_ary); debug("email", $email); debug("quote", $quote); debug("password", $password); debug("permission", $permission); */ /* DEBUG */ $author = new Author; if ($perm->have_perm("user")) { switch ($submit) { case "update": if($author->saveProfile($HTTP_POST_VARS)) { message("Profile Updated"); } else { error("Profile not updated"); } case "edit": default: $author->editAuthor($auth->auth['uid'], 'authorProfile'); } } else { titlebar("100%","Error! Invalid Privileges"); echo "Sorry. You do not have the necessary privilege to view this page."; } slashfoot(); page_close(); ?> Index: submission.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/submission.php3,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** submission.php3 6 Mar 2002 04:29:54 -0000 1.6 --- submission.php3 20 May 2002 19:52:48 -0000 1.7 *************** *** 2,7 **** // $id: submission.php3,v 1.0 2000/04/25 12:08:03 ajay Exp $ ! $pagetitle = "Administration"; # The name to be displayed in the header ! $xsiteobject = "Administration";#Defines The META TAG Page Type require("config.php3"); --- 2,7 ---- // $id: submission.php3,v 1.0 2000/04/25 12:08:03 ajay Exp $ ! $pagetitle = "Submission"; # The name to be displayed in the header ! $xsiteobject = "Submission";#Defines The META TAG Page Type require("config.php3"); Index: config.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/config.php3,v retrieving revision 1.138 retrieving revision 1.139 diff -C2 -d -r1.138 -r1.139 *** config.php3 20 May 2002 15:38:29 -0000 1.138 --- config.php3 20 May 2002 19:52:48 -0000 1.139 *************** *** 292,297 **** ); $menuitem[] = array( ! 'name' => "User", 'link' => $_PSL['rooturl'] . "/login.php3", 'perm' => "user", 'module' => "" --- 292,304 ---- ); $menuitem[] = array( ! 'name' => "Admin", 'link' => $_PSL['rooturl'] . "/login.php3", + 'perm' => "user", + 'module' => "" + + ); + $menuitem[] = array( + 'name' => "User Profile", + 'link' => $_PSL['rooturl'] . "/profile.php3", 'perm' => "user", 'module' => "" |