function getRedirectText($text) { $arr = explode(" ", $text); $index = 0; foreach ($arr as $value) { echo "<br/>arrValue: " . $value; if (stripos($value, "http") === 0) { echo " ______equial http"; $value = getRedirectURL($value); } $reArr[$index] = $value; $index++; } $reText = implode(" ", $reArr); echo "<br/>\nreDirectedText: " . $reText . "<br/>\n"; return $reText; }
$pw = random_word(); $md5 = md5($pw); $db->query("UPDATE {$db->pre}user SET pw = '{$md5}' WHERE id = '{$user['id']}' LIMIT 1", __LINE__, __FILE__); $user = $gpc->plain_str($user); $data = $lang->get_mail('pwremind2'); $to = array('0' => array('name' => $user['name'], 'mail' => $user['mail'])); $from = array(); xmail($to, $from, $data['title'], $data['comment']); ($code = $plugins->load('log_pwremind3_success')) ? eval($code) : null; ok($lang->phrase('log_pwremind_changed'), "log.php?action=login" . SID2URL_x); } else { ($code = $plugins->load('log_pwremind3_failed')) ? eval($code) : null; error($lang->phrase('log_pwremind_wrong_code'), "log.php?action=pwremind" . SID2URL_x); } } else { $loc = getRedirectURL(false); if (empty($loc)) { $loc = getRefererURL(); } $loc = htmlspecialchars($loc); if ($my->vlogin) { error($lang->phrase('log_already_logged'), $loc); } $breadcrumb->Add($lang->phrase('log_title')); echo $tpl->parse("header"); echo $tpl->parse("menu"); ($code = $plugins->load('log_login_form_start')) ? eval($code) : null; echo $tpl->parse("log/login"); ($code = $plugins->load('log_login_form_end')) ? eval($code) : null; $slog->updatelogged(); }