Terms of Service Module
Posted by Brian Moon
September 01, 2006 06:06PM |
Admin Registered: 19 years ago Posts: 8,532 |
Try {IF USERINFO->mod_tos_current} instead.
Maurice Makaay
Phorum Development Team
my blog
linkedin profile
secret sauce
Maurice Makaay
Phorum Development Team



Re: Terms of Service Module September 01, 2006 06:39PM |
Registered: 17 years ago Posts: 110 |
I think we were typing at the same time.. I'm uploading the updated .tpl file.
I reversed the logic on the IF cause this is my personal preference.. I dont like (if = false) else when an (if) else would be sufficient :P
Oliver, I'll remove the file once you've added it to your package
EDIT: file deleted--included in 2.2.0 package
Edited 3 time(s). Last edit at 09/03/2006 05:21PM by freedman.
I reversed the logic on the IF cause this is my personal preference.. I dont like (if = false) else when an (if) else would be sufficient :P
Oliver, I'll remove the file once you've added it to your package
EDIT: file deleted--included in 2.2.0 package
Edited 3 time(s). Last edit at 09/03/2006 05:21PM by freedman.
September 01, 2006 07:05PM |
Admin Registered: 19 years ago Posts: 8,532 |
I think that Oliver has written this code against the Phorum 5.2 development tree. In Phorum 5.2, {USERINFO} was renamed to {USER}.
Maurice Makaay
Phorum Development Team
my blog
linkedin profile
secret sauce
Maurice Makaay
Phorum Development Team



September 03, 2006 04:10PM |
Admin Registered: 17 years ago Posts: 744 |
Hi Keith, Hi Maurice,
I attached new version 2.2.0 in my original post. From change log:
Regards
Oliver
Using Phorum since 7/2000: forum.langzeittest.de (actual version 5.2.23)
Modules "Made in Germany" for version 5.2: Author_as_Sender, CarCost, Close_Topic, Conceal_Message_Timestamp,
Format_Email, Index_Structure, Mailing_List, Pervasive_Forum, Spritmonitor, Terms_of_Service and German_Language_Files_Package.
I attached new version 2.2.0 in my original post. From change log:
2006/09/01 version 2.2.0 by Oliver Riesen (oliver@riesen.org) - Added sanity checks. See "System Sanity Checks" in Phorum administration. - Default settings are stored automatically on first usage of the module. So the admin don't have to go to the settings page. - Module language strings now uses own sub-array. - Correcting error: whenever someone posted a message their TOS accept date got updated to the current date; thanks to freedman. - Correcting error: a TOS version date in the future forced a renew for each post; thanks to freedman. - Including template for version 5.1 and future 5.2.
Regards
Oliver
Using Phorum since 7/2000: forum.langzeittest.de (actual version 5.2.23)
Modules "Made in Germany" for version 5.2: Author_as_Sender, CarCost, Close_Topic, Conceal_Message_Timestamp,
Format_Email, Index_Structure, Mailing_List, Pervasive_Forum, Spritmonitor, Terms_of_Service and German_Language_Files_Package.
Re: Terms of Service Module September 24, 2006 12:47AM |
Registered: 17 years ago Posts: 28 |
I am running phorum 5.1.16a, Terms-of-service 2.2.0
It seems that the terms-of-service has a bug (or not working on my system). Whenever user clicks: "I agree with these terms."
It will generate the following bug:
"You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near ''20060922')' at line 1: insert into phorum_user_custom_fields (user_id,type,data) VALUES(4,,'20060922')"
I checked that the custom profile had created: mod_tos, and it has three fields.
It seems that the terms-of-service has a bug (or not working on my system). Whenever user clicks: "I agree with these terms."
It will generate the following bug:
"You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near ''20060922')' at line 1: insert into phorum_user_custom_fields (user_id,type,data) VALUES(4,,'20060922')"
I checked that the custom profile had created: mod_tos, and it has three fields.
September 25, 2006 05:53AM |
Admin Registered: 17 years ago Posts: 744 |
Hi BBSNewbie,
Strange. Did you use the "System sanity checks" in admin section to see if the module reports some problem?
Regards
Oliver
Using Phorum since 7/2000: forum.langzeittest.de (actual version 5.2.23)
Modules "Made in Germany" for version 5.2: Author_as_Sender, CarCost, Close_Topic, Conceal_Message_Timestamp,
Format_Email, Index_Structure, Mailing_List, Pervasive_Forum, Spritmonitor, Terms_of_Service and German_Language_Files_Package.
Quote
BBSNewbie
It seems that the terms-of-service has a bug (or not working on my system). Whenever user clicks: "I agree with these terms."
It will generate the following bug:
"You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near ''20060922')' at line 1: insert into phorum_user_custom_fields (user_id,type,data) VALUES(4,,'20060922')"
I checked that the custom profile had created: mod_tos, and it has three fields.
Strange. Did you use the "System sanity checks" in admin section to see if the module reports some problem?
Regards
Oliver
Using Phorum since 7/2000: forum.langzeittest.de (actual version 5.2.23)
Modules "Made in Germany" for version 5.2: Author_as_Sender, CarCost, Close_Topic, Conceal_Message_Timestamp,
Format_Email, Index_Structure, Mailing_List, Pervasive_Forum, Spritmonitor, Terms_of_Service and German_Language_Files_Package.
Re: Terms of Service Module September 25, 2006 08:13PM |
Registered: 17 years ago Posts: 4 |
Quote
BBSNewbie
"You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near ''20060922')' at line 1: insert into phorum_user_custom_fields (user_id,type,data) VALUES(4,,'20060922')"
I had the same error on MySQL 5.0.17
The admin of the server said it is because of a strict mode, changed something, then it worked.
September 25, 2006 08:17PM |
Admin Registered: 22 years ago Posts: 4,495 |
No, that is just a bad query. strict mode wont' fix that.
Brian - Cowboy Ninja Coder - Personal Blog - Twitter
Re: Terms of Service Module September 25, 2006 10:14PM |
Registered: 17 years ago Posts: 28 |
I did use the "System sanity checks", and it kept reporting:
"Sanity check failed
The default settings for the module are missing.
Possible solution:
Login as administrator in Phorum's administrative interface and go to the "Modules" section. Open the module settings for the Terms of Service Module and save the default values."
I had done this a few times, I still got the same sanity check failed error.
I checked Custom Profiles field, it did report
mod_tos 8 Yes
Thank you in advance.
(BTW, I am running 5.1.16a, TOS 2.2.0, it is on godaddy server, I was told that
MySQL version is 4.0.27)
"Sanity check failed
The default settings for the module are missing.
Possible solution:
Login as administrator in Phorum's administrative interface and go to the "Modules" section. Open the module settings for the Terms of Service Module and save the default values."
I had done this a few times, I still got the same sanity check failed error.
I checked Custom Profiles field, it did report
mod_tos 8 Yes
Thank you in advance.
(BTW, I am running 5.1.16a, TOS 2.2.0, it is on godaddy server, I was told that
MySQL version is 4.0.27)
Quote
Oliver Riesen
Hi BBSNewbie,
Quote
BBSNewbie
It seems that the terms-of-service has a bug (or not working on my system). Whenever user clicks: "I agree with these terms."
It will generate the following bug:
"You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near ''20060922')' at line 1: insert into phorum_user_custom_fields (user_id,type,data) VALUES(4,,'20060922')"
I checked that the custom profile had created: mod_tos, and it has three fields.
Strange. Did you use the "System sanity checks" in admin section to see if the module reports some problem?
Regards
Oliver
September 26, 2006 05:14AM |
Admin Registered: 17 years ago Posts: 744 |
Hi BBSNewbie,
Did you get the message "Settings Updated" after clicking on "Save"?
Please check your phorum_settings table for the default settings (for example with phpMyAdmin):
You should get two rows.
Regards
Oliver
Using Phorum since 7/2000: forum.langzeittest.de (actual version 5.2.23)
Modules "Made in Germany" for version 5.2: Author_as_Sender, CarCost, Close_Topic, Conceal_Message_Timestamp,
Format_Email, Index_Structure, Mailing_List, Pervasive_Forum, Spritmonitor, Terms_of_Service and German_Language_Files_Package.
Quote
BBSNewbie
I had done this a few times
Did you get the message "Settings Updated" after clicking on "Save"?
Please check your phorum_settings table for the default settings (for example with phpMyAdmin):
SELECT `name`,`type`,`data` FROM `phorum_settings` WHERE 1 AND `name` LIKE 'mod_tos%'
You should get two rows.
Regards
Oliver
Using Phorum since 7/2000: forum.langzeittest.de (actual version 5.2.23)
Modules "Made in Germany" for version 5.2: Author_as_Sender, CarCost, Close_Topic, Conceal_Message_Timestamp,
Format_Email, Index_Structure, Mailing_List, Pervasive_Forum, Spritmonitor, Terms_of_Service and German_Language_Files_Package.
Sorry, only registered users may post in this forum.