Prevent the PHPWIND Forum from being maliciously registered by the registration machine for advertising. Recently, my forum has a registration machine that maliciously registers and publishes advertisement information, which is annoying. I am trying to prevent malicious registration. The following are some methods: Method 1: I recently registered a registered forum with an old registrar who maliciously registered the website and published advertisement information. I am so annoyed that I have tried some ways to prevent malicious registration. The following are some methods:
Method 1: Change the NAME of the registry list (most effective, but you must have some knowledge about PHP and MYSQL .)
Modify the NAME of the content entered in the registry form. this must be used with the data table, and the MYSQL form keyword must also be changed.
Method 2: Enter the answer to the website registration question
Change two files: register.htm and register. php.
Step 1: Open the register.htm under Forum template/wind/. of course, this is the default style template. if you change the template, find the file under the name of the modified template.
First, find a place. we recommend that you put it on it:
Edit-search
User name
In this sentence, I would like to add a few words: it is a problem. of course, you can modify the specific content of the problem.
Protection against malicious registration problems:
How old is your mom aged 49 last year?
Enter the number in the left space.
Save, upload to space to replace the original file
Step 2: Open register. php in the main directory of the Forum.
Edit-search
$ Db-> update ("insert into pw_members (username, password, email, publicmail, groupid, memberid, icon, gender, regdate, signature, introduce, oicq, icq, site, location, bday, receivemail, yz, signchange) VALUES
Add a few words above this sentence: Check whether the answer to the question is correct, and specify the answer according to your own question
If ($ manianling! = 50 ){
Showmsg !! "," Javascript: history. back ()");
}
Save, upload to space to replace the original file.
Method 3: Change the name of register. php.
It is to change the file name of the registration page, for example, to change register. php to r. php or something. Note that the register. php page of all links must be changed to r. php. Otherwise, it will become a whiteboard.
There is no way to do this. There are many modifications that affect the upgrade and the current operation of the forum, but they are absolutely effective.
Change register. php to your desired name first.
Start of modification:
Change register. php to the name you changed, for example, welcome. php.
Login. php
Global. php 2
Then modify it at "template/wind" (all templates must be modified as long as they have the following files!
Faq.htm
Login.htm
Lang_email.php
Lang_other.php
Register.htm 3 simple_index.htm
Simple_read.htm
Simple_thread.htm
Search
Register. php
Change the name of register. php after modification. For example, welcome. php
No additional information is required for this method!
Method 4: enter the current day
1. modify register. php (register. php is in the main directory)
Find:
$ Db-> update ("insert into pw_members (username, password, email, publicmail, groupid, memberid, icon, gender, regdate, signature, introduce, oicq, icq, site, location, bday, receivemail, yz, signchange) VALUES
Add the above (modified by yourself in Chinese ):
If ($ nowday! = $ Nowday1 ){
Showmsg ("The date is incorrect. you won't forget the number of today's day, will you? "," Javascript: history. back ()");
}
Find:
@ Include_once (D_P.data/bbscache/inv_config.php );
Add the following:
$ Nowday1 = gmdate ("d", $ timestamp + $ timeoffset * 3600 );
$ Nowday2 = gmdate ("m Month D", $ timestamp + $ timeoffset * 3600 );
2、modify register.htm(register.htm in the directory/template/wind/register.htm or other style directories)
Find:
Required information
Add the following (modify the Chinese version by yourself ):
Anti-malicious registration question: What is the date today?
If today
The expiration date is July 04.
Tip: Enter
Color = "# FF0000"> $ nowday1 enter it in the text box on the left (ignore the time difference in the morning)
Friendly reminder: Please delete the IDs previously registered by robots. many robots are registered before and do not post, and then send them to the specified date. if you find similar IDs, such as Lijian, please delete it. keep it as a hidden danger.
Method 5: Add the anti-automatic registration server verification code to the background
1. open template/admin/settings.htm
Search
Initial registration {$ db_moneyname}: (it is recommended to set it to 0 .)
Add
Anti-automatic registration server verification code: for example, "phpwinnd" (if it is set to Null, it indicates that the verification code is disabled)(Note: after modification, you must go to the background to set your desired verification code. if you leave it blank, this function is not enabled)
2. open admin/settings. php
Search
If ($ reg [regmaxname]> 15 ){
Adminmsg (illegal_username );
}
Add
$ Reg [autoreg] = str_replace ("", "", trim ($ reg [autoreg]);
3. open template/wind/register.htm
Search
Confirm password *
Add
Anti-automatic registration server verification code *
Color = red>$ Rg_autoreg
4. open the register. php file.
Search
If (! $ Rg_rglower ){
For ($ asc = 65; $ asc <= 90; $ asc ++ ){
If (strpos ($ regname, chr ($ asc ))! = False ){
Showmsg (username_limit );
}
}
}
Add
If ($ rg_autoreg! = "" & $ Autoreg! = $ Rg_autoreg ){
Showmsg (sorry, the verification of the anti-automatic registration machine failed !);
}
Complete
I hope to help you.
Bytes. The following are some methods: Method 1: Change registration...