[geeklog-cvs] Geeklog-1.x/system lib-custom.php,1.39,1.40
Blaine Lang
blaine at qs1489.pair.com
Sat May 31 15:49:38 EDT 2008
Update of /cvsroot/geeklog/Geeklog-1.x/system
In directory qs1489.pair.com:/tmp/cvs-serv65923/system
Modified Files:
lib-custom.php
Log Message:
Added a call to CUSTOM_usercheck when editing a user under My Account if custom registratrion is enabled
Test for a numeric return and if not set or not numeric display a generic message
Added new generic message to language file for CUSTOM membership edit validation failed
Index: lib-custom.php
===================================================================
RCS file: /cvsroot/geeklog/Geeklog-1.x/system/lib-custom.php,v
retrieving revision 1.39
retrieving revision 1.40
diff -C2 -d -r1.39 -r1.40
*** lib-custom.php 11 May 2008 07:25:08 -0000 1.39
--- lib-custom.php 31 May 2008 19:49:36 -0000 1.40
***************
*** 333,347 ****
/**
! * Check if it's okay to create a new user.
! *
! * Geeklog is about to create a new user with the given username and email
! * address. This is the custom code's last chance to prevent that,
* e.g. to check if all required data has been entered.
*
* @param string $username username that Geeklog would use for the new user* @param string $email email address of that user
! * @return string an error message or an empty string for "OK"
! *
*/
! function CUSTOM_userCheck ($username, $email)
{
$msg = '';
--- 333,347 ----
/**
! * Geeklog is about to create a new user or edit an existing user.
! * This is the custom code's last chance to do any form validation,
* e.g. to check if all required data has been entered.
*
* @param string $username username that Geeklog would use for the new user* @param string $email email address of that user
! * @return mixed Creating a new user: An error message or an empty string for "OK".
! * Edit user function under My Account: the script expects a message number,
! * that will map to the GLOBALS $MESSAGE define in the site language files
! * By default $MESSAGE[97] will appear if a non-numeric is returned to usersettings.php - saveuser function
*/
! function CUSTOM_userCheck ($username, $email='')
{
$msg = '';
***************
*** 387,391 ****
$noboxes = $_USER['noboxes'];
}
!
foreach($showblocks as $block) {
$sql = "SELECT bid, name,type,title,content,rdfurl,phpblockfn,help,allow_autotags FROM {$_TABLES['blocks']} WHERE name='$block'";
--- 387,391 ----
$noboxes = $_USER['noboxes'];
}
!
foreach($showblocks as $block) {
$sql = "SELECT bid, name,type,title,content,rdfurl,phpblockfn,help,allow_autotags FROM {$_TABLES['blocks']} WHERE name='$block'";
More information about the geeklog-cvs
mailing list