Changeset 106
- Timestamp:
- 09/01/07 21:52:34 (1 year ago)
- Files:
-
- trunk/wp-infocard/wp/admin.pw.php (modified) (4 diffs)
- trunk/wp-infocard/wp/clickback.pw.php (modified) (1 diff)
- trunk/wp-infocard/wp/userdata.pw.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/wp-infocard/wp/admin.pw.php
r104 r106 1 1 <?php 2 // This file is part of Pamela Project. 3 // 4 // Copyright (C) 2007 by various authors (see CONTRIBUTORS file) 5 // This file is free software, distributed under the new BSD License (see LICENSE file). 6 // 7 // admin.pw.php 8 // 2 9 //defined( '_VALID_IC' ) or die( 'Direct Access to this location is not allowed.'); 3 10 include_once( dirname(__FILE__) . '/../pw-config.php'); … … 105 112 $myTableIdentityQuery = 106 113 "CREATE TABLE `$this->table_identity` ( 107 `modulusHash` varchar(128) NOT NULL default '', 108 `ppid` varchar(128) NOT NULL default '', 109 `accountid` bigint(20) unsigned 114 `cardhash` text default '', 115 `accountid` bigint(20) unsigned, 116 `cardhandle` varchar(128) NOT NULL default '', 117 `startdate` varchar(128) NOT NULL default '', 118 `lastused` varchar(128) NOT NULL default '' 110 119 ) ENGINE = MYISAM"; 111 120 */ … … 314 323 } //end function getOption 315 324 316 // Function: createNewAccount 317 // Description: creates a new db record 318 // Input: account details 319 // Output: returns the user Id on success, FALSE on failure 320 // Side effect: none 321 function createNewAccount( $user_login, $user_pass, $user_email, $user_url, $user_firstname, $user_lastname ) 325 /* 326 Function: createNewAccount 327 Description: creates a new db record 328 Input: account details 329 Output: returns the user Id on success, FALSE on failure 330 Side effect: none 331 */ 332 function createNewAccount( $datamap ) 322 333 { 323 334 require_once( ABSPATH . WPINC . '/registration-functions.php'); 324 335 336 $user_login = $datamap['user_login']->new_value; 337 $user_firstname = $datamap['first_name']->new_value; 338 $user_lastname = $datamap['last_name']->new_value; 339 $user_email = $datamap['user_email']->new_value; 340 $display_name = $datamap['display_name']->new_value; 341 $user_nicename = $display_name; 342 $user_pass = MD5($datamap['cardhash']->new_value); 343 $user_url = $datamap['user_url']->new_value; 344 325 345 InfocardUtils::printDebug("<br/>Action: createNewAccount<br>"); 326 $user_nicename = "$user_firstname $user_lastname";327 346 InfocardUtils::printDebug("<br/>Nice Name: $user_nicename<br>"); 328 $display_name = $user_nicename;329 347 $userdata = compact('user_login', 'user_pass', 'user_email', 'user_nicename', 'user_url', 'display_name', 'user_firstname', 'user_lastname'); 330 348 $user_ID = wp_insert_user($userdata); … … 342 360 } // end function createNewAccount 343 361 362 function createOption( $option_name, $option_value ) 363 { 364 // this function needs to be inside the pw_infocard class for WP to call it. This is just a 365 // placeholder 366 } 344 367 function pwAdminScreen() 345 368 { trunk/wp-infocard/wp/clickback.pw.php
r103 r106 11 11 include_once(dirname(__FILE__) . "/../" . PW_PLUGIN . "/userdata.pw.php"); 12 12 include_once(dirname(__FILE__) . "/../" . PW_PLUGIN . "/utils.pw.php"); 13 include_once(dirname(__FILE__) . "/../ " . PW_PLUGIN . "/clickback.pwlib.php");13 include_once(dirname(__FILE__) . "/../pwlib/clickback.pwlib.php"); 14 14 15 15 class pw_clickback extends pwlib_clickback trunk/wp-infocard/wp/userdata.pw.php
r105 r106 1 1 <?php 2 // This file is part of Pamela Project. 3 // 4 // Copyright (C) 2007 by various authors (see CONTRIBUTORS file) 5 // This file is free software, distributed under the new BSD License (see LICENSE file). 6 // 7 // userdata.pwlib.php 8 // 2 9 //defined( '_VALID_IC' ) or die( 'Direct Access to this location is not allowed.'); 3 10 include_once( dirname(__FILE__) . '/../pw-config.php'); 4 11 include_once( dirname(__FILE__) . '/utils.pw.php'); 5 12 include_once( ABSPATH . WPINC . '/registration-functions.php'); 6 include_once( dirname(__FILE__) . "/../pwli/userdata.pwlib.php");13 include_once( dirname(__FILE__) . '/../pwlib/userdata.pwlib.php' ); 7 14 8 15 /*
