Paulz Posted January 12, 2004 Share Posted January 12, 2004 Im getting passwords sent to users in the form of Your password is: ?kw?I?? I want to change the characters so they are easily typed: This has something to do with the mod: signup_confirm_email maybe something to do with the following code edit in catalog/create_account_process.php >>>>>>> Near the top, find: require('includes/application_top.php'); require(DIR_WS_LANGUAGES . $language . '/' . FILENAME_CREATE_ACCOUNT_PROCESS); if (!isset($HTTP_POST_VARS['action'])) { tep_redirect(tep_href_link(FILENAME_CREATE_ACCOUNT)); } Below it add: $newpass = tep_create_random_value(ENTRY_PASSWORD_MIN_LENGTH); $encrypted_password = tep_encrypt_password($newpass); A little below that, find: $password = tep_db_prepare_input($HTTP_POST_VARS['password']); $confirmation = tep_db_prepare_input($HTTP_POST_VARS['confirmation']); Change these 2 lines to: // $password = tep_db_prepare_input($HTTP_POST_VARS['password']); // $confirmation = tep_db_prepare_input($HTTP_POST_VARS['confirmation']); $password = $newpass; $confirmation = $newpass; Find: $passlen = strlen($password); if ($passlen < ENTRY_PASSWORD_MIN_LENGTH) { $error = true; $entry_password_error = true; } else { $entry_password_error = false; } if ($password != $confirmation) { $error = true; $entry_password_error = true; } Change it to: /* $passlen = strlen($password); if ($passlen < ENTRY_PASSWORD_MIN_LENGTH) { $error = true; $entry_password_error = true; } else { $entry_password_error = false; } if ($password != $confirmation) { $error = true; $entry_password_error = true; } */ Find: $email_text .= EMAIL_WELCOME . EMAIL_TEXT . EMAIL_CONTACT Change it to: $email_text .= EMAIL_WELCOME . EMAIL_USERNAME . 'Your password is: <b>' . stripslashes($plain_pass) . '</b>' . "\n\n" . EMAIL_TEXT . EMAIL_CONTACT Also change the line below it to read (Added By Ricky Woodbridge): tep_mail($name, $email_address, $email_text, $email_subject, STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS); >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> anyhelp appreciated Link to comment Share on other sites More sharing options...
Paulz Posted January 16, 2004 Author Share Posted January 16, 2004 Can someone please help me with this why am i getting passwords sent in this format : Your password is: t?H9J?L :unsure: Link to comment Share on other sites More sharing options...
241 Posted January 16, 2004 Share Posted January 16, 2004 What default language are you using? No longer giving free advice. Please place deposit in meter slot provided. Individual: [=] SME: [==] Corporation: [===] If deposit does not fit one of the slots provided then you are asking too much! Is your Osc dated try Phoenix raising oscommerce from the ashes. Link to comment Share on other sites More sharing options...
Paulz Posted January 16, 2004 Author Share Posted January 16, 2004 its set to english Link to comment Share on other sites More sharing options...
Paulz Posted January 17, 2004 Author Share Posted January 17, 2004 Urgently need some help with this nearly ready for going live any hints what it could be Link to comment Share on other sites More sharing options...
241 Posted January 17, 2004 Share Posted January 17, 2004 possibly something in the encryption $encrypted_password = tep_encrypt_password($newpass); No longer giving free advice. Please place deposit in meter slot provided. Individual: [=] SME: [==] Corporation: [===] If deposit does not fit one of the slots provided then you are asking too much! Is your Osc dated try Phoenix raising oscommerce from the ashes. Link to comment Share on other sites More sharing options...
Paulz Posted January 17, 2004 Author Share Posted January 17, 2004 Ive removed the mod signup_confirm_email and just realized Ive got the same problem with password forgotten email? sending the same password format : eg: S?Cjt?T I dont appear to have any other Character problems anywhere? could this be a problem with my server ? Also Im using osc2.2ms1 Link to comment Share on other sites More sharing options...
Paulz Posted January 17, 2004 Author Share Posted January 17, 2004 Tried everything I can think of Its nothing obvious, the only setting I can think that relates to it is in includes/languages/english.php // charset for web pages and emails define('CHARSET', 'iso-8859-1'); But that appears ok??? I decided to change the temp password to digits as below: $new_password = tep_create_random_value(ENTRY_PASSWORD_MIN_LENGTH,'digits'); This worked OK. Id still like to resolve this problem, any help would be much appreciated. Regards Paul Link to comment Share on other sites More sharing options...
Paulz Posted January 18, 2004 Author Share Posted January 18, 2004 For anyone that has the same issue I resolved the problem. as Im using osc2.2ms1, I checked out the /includes/languages/english.php in 2.2CVS to see if there any changes. it suggested for available locales type locale -a on the server. which I did and discovered as en_GB en_GB.iso885915 so I changed from : @setlocale(LC_TIME, 'en_GB.ISO_8859-1'); to @setlocale(LC_TIME, 'en_GB.iso885915'); and its worked! :D Normal passwords at last Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.