- UID
- 90015
- 帖子
- 366
- 主題
- 6
- 精華
- 0
- 積分
- 151
- 楓幣
- 84
- 威望
- 141
- 存款
- 0
- 贊助金額
- 0
- 推廣
- 0
- GP
- 15
- 閱讀權限
- 20
- 性別
- 保密
- 在線時間
- 196 小時
- 註冊時間
- 2015-1-25
- 最後登入
- 2024-11-10
|
首先打開您的www目錄且找到register.php
使用記事本打開並找到
$username = ereg_replace("[^A-Za-z0-9]", "", $_POST['username']);
改成
$username = preg_replace("/[^A-Za-z0-9]/", "", $_POST['username']);
接著找到
$password = ereg_replace("[^A-Za-z0-9]", "", $_POST['password']);
改成
$password = preg_replace("/[^A-Za-z0-9]/", "", $_POST['password']);
然後找到
if (!eregi("^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*$", $_POST['mail'])){header("Location: index.php?page=register&error=emer"); die();}
改成
if (!preg_match("/^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*$/i", $_POST['mail'])){header("Location: index.php?page=register&error=emer"); die();}
最後找到
if (!eregi("^[_a-z0-9-]", $_POST['yahoo'])){header("Location: index.php?page=register&error=emer"); die();}
改成
if (!preg_match("/^[_a-z0-9-]/i", $_POST['yahoo'])){header("Location: index.php?page=register&error=emer"); die();}
(轉貼小馬論壇) |
|