[14/12/06] Textual Confirmation

All new MODs released in our MOD Database will be announced in here. All support for released MODs needs to take place in here. No new MODs will be accepted into the MOD Database for phpBB2
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

On February 1, 2009 this forum will be set to read only as part of retiring of phpBB2.
Post Reply

Rating:

Excellent!
118
82%
Very Good
17
12%
Good
3
2%
Fair
1
1%
Poor
5
3%
 
Total votes: 144

lodp
Registered User
Posts: 9
Joined: Fri Jan 05, 2007 2:47 pm

Post by lodp » Mon Jan 22, 2007 3:14 am

this mod is working like charm, in the two days that i've got it operational, it already fought off more than 50 spammers :)

two things i'd like to bring up:

1. it would be great to have a checkbox for turning off e-mail notification to the site admin. it's an interesting read in the beginning, but it really fills up your mailbox..

2. will you come up with a version of the mod for phpBB3? it looks like beta 5 and after that rc1 will soon come out, and as i understood it they're mainly fixing bugs as of now, so you should hopefully be on the safe side if you start porting mods..

again, many thanks for your terrific work!

User avatar
olpa
Registered User
Posts: 255
Joined: Tue Jan 25, 2005 6:44 pm
Location: Saint-Petersburg, Russia
Contact:

Post by olpa » Mon Jan 22, 2007 3:42 am

1. it would be great to have a checkbox for turning off e-mail notification to the site admin. it's an interesting read in the beginning, but it really fills up your mailbox..

Sorry, it's an incentive to sponsor me for further anti-spam development. However, if you know PHP, you can switch off the emails very easy.
2. will you come up with a version of the mod for phpBB3?

I don't know yet. There is rumour that phpBB 3 has built-in ability to define custom registration fields. If it is true, Textual Confirmation might be not needed. Anyway, I'm waiting for the release.

User avatar
JezUK1
Registered User
Posts: 735
Joined: Wed Jul 27, 2005 11:12 pm
Location: England, Somerset
Contact:

Post by JezUK1 » Mon Jan 22, 2007 8:10 pm

Well done anyway on this mod my friend its ace!

My one says this:
Please answer the Textual Confirmation question, this stops spammers and bots from registering.


What you think?
Jez

ControlThis.co.uk - Your online model shop

hotrodkush
Registered User
Posts: 16
Joined: Tue Sep 26, 2006 2:59 am
Contact:

Post by hotrodkush » Tue Jan 23, 2007 5:29 pm

Hey guys, just tried installing this and getting this error:
Could not insert question/answer pair!

DEBUG MODE

SQL Error : 1146 Table 'icmodified.TEXTUAL_CONFIRMATION_TABLE' doesn't exist

INSERT INTO TEXTUAL_CONFIRMATION_TABLE(question,answers) VALUES('hi
','hi')

Line : 113
File : admin_tc.php


I'm using multiple skins but ran the DB_update file after installing each of them. Any thoughts?

User avatar
drathbun
Former Team Member
Posts: 12204
Joined: Thu Jun 06, 2002 3:51 pm
Location: TOPICS_TABLE
Contact:

Post by drathbun » Tue Jan 23, 2007 5:34 pm

Check your edits to includes/constants.php... the table name is not being translated from the CONSTANT_STRING to the actual table name. I have not reviewed this MOD but generally that information is stored in includes/constants.php.
I blog about phpBB: phpBBDoctor blog
Still using phpbb2? So am I! Click below for details
Image

hotrodkush
Registered User
Posts: 16
Joined: Tue Sep 26, 2006 2:59 am
Contact:

Post by hotrodkush » Tue Jan 23, 2007 8:27 pm

Thanks, I'll take a look.

EDIT: that worked, thanks alot!

z28cave
Registered User
Posts: 27
Joined: Thu Feb 09, 2006 1:37 am
Location: Bay Area, CA
Contact:

Post by z28cave » Thu Jan 25, 2007 4:19 pm

I just wanted to thank you for this MOD. Works awesome!

User avatar
GilaMonster
Registered User
Posts: 83
Joined: Mon Jan 10, 2005 12:52 am
Location: CSC Scania, Iraq - Silver City, NM
Contact:

Post by GilaMonster » Fri Jan 26, 2007 1:34 am

OK, the SQL changes are somehting I am learning, but don't know hat much about. I know I can use the db_update file and do it quickly, but I would like to learn how to do it manually. :wink:
Here's the SQL proceedure as privided:

Code: Select all

#
#-----[ SQL ]------------------------------------------
#
CREATE TABLE phpbb_textual_confirmation (
 id       INTEGER NOT NULL AUTO_INCREMENT,
 question TEXT    NOT NULL,
 answers  TEXT    NOT NULL,
 PRIMARY KEY (id)
);
INSERT INTO phpbb_textual_confirmation(question,answers) VALUES ('Are you human?', 'yes\nja\noui');
INSERT INTO phpbb_textual_confirmation(question,answers) VALUES ('Say hello', 'hello\nhi\nhallo');
My question is: Do I enter the information above into "Create new table on database"? and what do I enter for "Number of fields:"? or do I add the code somewhere else entirely? :?
Thanks for any help... :D

User avatar
olpa
Registered User
Posts: 255
Joined: Tue Jan 25, 2005 6:44 pm
Location: Saint-Petersburg, Russia
Contact:

Post by olpa » Fri Jan 26, 2007 3:38 am

GilaMonster, I think you are playing with phpmysqladmin. The easiest way is to find an SQL console there to execute arbitrary SQL queries. I don't use phpmysqladmin, therefore can't suggest where it is. Probably this topic can help: How to use phpMyadmin.

To all who said thanks: thanks for the kind words!

TTR_Graeme
Registered User
Posts: 1
Joined: Fri Jan 26, 2007 4:01 pm
Location: Melbourne, Australia
Contact:

Problem with SQL change

Post by TTR_Graeme » Fri Jan 26, 2007 4:37 pm

Thanks to all involved for this MOD. I have just installed it on my board.

I did have a small problem on the way, however. I have found a solution that seems to work so I thought I'd post the problem and the solution here.

I hope that someone more knowledgeable than me will check and make sure it's not a huge mistake and if not I hope this will help someone else.

When I got to this instruction...
#
#-----[ SQL ]------------------------------------------
#
CREATE TABLE phpbb_textual_confirmation (
id INTEGER NOT NULL AUTO_INCREMENT,
question TEXT NOT NULL,
answers TEXT NOT NULL,
PRIMARY KEY (id)
);


...I got the following error:
ERROR: syntax error at or near "AUTO_INCREMENT" at character 70


After some searching, I found that my database, PostgreSQL, doesn't quite understand this the same way MySQL does. I guess the MOD developers and most users are using MySQL.

By using the following command instead I was able to get it to work:

Code: Select all

CREATE TABLE phpbb_textual_confirmation (
 id       SERIAL,
 question TEXT    NOT NULL,
 answers  TEXT    NOT NULL,
 PRIMARY KEY (id)
 );
However it did produce the following notices:
NOTICE: CREATE TABLE will create implicit sequence "phpbb_textual_confirmation_id_seq" for "serial" column "phpbb_textual_confirmation.id"

NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index "phpbb_textual_confirmation_pkey" for table "phpbb_textual_confirmation"


If you understand the problem and the suggested solution I would very much like to hear your comments.

Thanks

User avatar
drathbun
Former Team Member
Posts: 12204
Joined: Thu Jun 06, 2002 3:51 pm
Location: TOPICS_TABLE
Contact:

Post by drathbun » Fri Jan 26, 2007 4:58 pm

You're correct, mysql provides the "auto_increment" attribute as a way to have the database assign the primary key. Setting up a sequence for postgresql accomplishes the same thing.
I blog about phpBB: phpBBDoctor blog
Still using phpbb2? So am I! Click below for details
Image

User avatar
GilaMonster
Registered User
Posts: 83
Joined: Mon Jan 10, 2005 12:52 am
Location: CSC Scania, Iraq - Silver City, NM
Contact:

Post by GilaMonster » Fri Jan 26, 2007 7:05 pm

olpa wrote: GilaMonster, I think you are playing with phpmysqladmin. The easiest way is to find an SQL console there to execute arbitrary SQL queries. I don't use phpmysqladmin, therefore can't suggest where it is. Probably this topic can help: How to use phpMyadmin.

To all who said thanks: thanks for the kind words!

I clicked on SQL. I'm not sure if this is what you are refering to..
This image has been reduced...
Image
Should I copy and past the following into this and click on "go"? Is that how it works? Sorry I am so stupid about this.

Code: Select all

CREATE TABLE phpbb_textual_confirmation ( 
 id       INTEGER NOT NULL AUTO_INCREMENT, 
 question TEXT    NOT NULL, 
 answers  TEXT    NOT NULL, 
 PRIMARY KEY (id) 
); 
INSERT INTO phpbb_textual_confirmation(question,answers) VALUES ('Are you human?', 'yes\nja\noui'); 
INSERT INTO phpbb_textual_confirmation(question,answers) VALUES ('Say hello', 'hello\nhi\nhallo');
If so, do I add the entire code all at once or put the CREATE TABLE part into it and click go and then do the same thing with each of the INSERT INTO parts? Yes, I have no clue...
Thanks for any help. :D

colin_bb
Registered User
Posts: 104
Joined: Tue Feb 14, 2006 8:40 pm

Post by colin_bb » Fri Jan 26, 2007 9:56 pm

Installed with easymod, no problems at all. Really good mod, 5/5. Thanks :)

User avatar
VPWanda
Registered User
Posts: 15
Joined: Tue Mar 07, 2006 12:08 am

Post by VPWanda » Sat Jan 27, 2007 4:08 am

Great mod!
I haven't had a single spammer on my forum since I've installed it.
And it's nice not to have to remove a whole bunch of inactive accounts each day.

User avatar
olpa
Registered User
Posts: 255
Joined: Tue Jan 25, 2005 6:44 pm
Location: Saint-Petersburg, Russia
Contact:

Post by olpa » Sat Jan 27, 2007 4:37 am

Again, thanks everyone for greate feedback! (And please don't forget to vote for the MOD as "Excellent".)

TTR_Graeme, according to the tool EasyMOD :: SQL Parser, the PostgreSQL code to create the table looks so:

Code: Select all

CREATE TABLE phpbb_textual_confirmation (
    id SERIAL,
    question TEXT NOT NULL,
    answers TEXT NOT NULL,
    CONSTRAINT phpbb_textual_confirmation_pk PRIMARY KEY (id)
);
However, I think your variant should work too.

GilaMonster: yes, you can copy the SQL commands to the text field "Run SQL query/queries on database..." and click on "Go". You can execute all the three command at once, or you can execute command-by-command three times. Not important.

Post Reply

Return to “[2.0.x] MOD Database Releases”

Who is online

Users browsing this forum: No registered users and 4 guests