vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Graveyard (https://vborg.vbsupport.ru/forumdisplay.php?f=224)
-   -   Miscellaneous Hacks - Rules and User Agreement Hack (https://vborg.vbsupport.ru/showthread.php?t=97699)

webgroup 06-01-2006 03:30 PM

Just by installing the product I got this error in the whole forum:

Fatal error: Cannot redeclare check_rulesneeded() (previously declared in /home/xxxx/public_html/xxxxx/global.php(503) : eval()'d code:80) in /home/xxxxxx/public_html/xxxxxx/global.php(503) : eval()'d code on line 548

PLUS, i got this error message on my email:

Database error in vBulletin 3.5.4:

Invalid SQL:
SELECT * FROM vbnewruleshack
WHERE (fileurl LIKE 'http://www.xxxxxxx.net/xxxxxx/member.php?s=&u=10538' AND exactmatch = 1 )
OR (fileurl LIKE 'http://www.xxxxxx.net/xxxxxxx/member.php%' AND exactmatch = 0 ) AND active = 1 ORDER BY ruleid;

MySQL Error : Table 'XXXX.vbnewruleshack' doesn't exist Error Number : 1146
Date : Thursday, June 1st 2006 @ 12:25:58 PM
Script : http://www.xxxxxxxxx.net/xxxx/member.php?s=&u=10538



I'm running 3.5.4, any ideas???

imranbaig 06-04-2006 10:06 AM

This is a Great Hack!
Thank you very much m8

webgroup 06-04-2006 03:01 PM

Quote:

Originally Posted by webgroup
Just by installing the product I got this error in the whole forum:

Fatal error: Cannot redeclare check_rulesneeded() (previously declared in /home/xxxx/public_html/xxxxx/global.php(503) : eval()'d code:80) in /home/xxxxxx/public_html/xxxxxx/global.php(503) : eval()'d code on line 548

PLUS, i got this error message on my email:

Database error in vBulletin 3.5.4:

Invalid SQL:
SELECT * FROM vbnewruleshack
WHERE (fileurl LIKE 'http://www.xxxxxxx.net/xxxxxx/member.php?s=&u=10538' AND exactmatch = 1 )
OR (fileurl LIKE 'http://www.xxxxxx.net/xxxxxxx/member.php%' AND exactmatch = 0 ) AND active = 1 ORDER BY ruleid;

MySQL Error : Table 'XXXX.vbnewruleshack' doesn't exist Error Number : 1146
Date : Thursday, June 1st 2006 @ 12:25:58 PM
Script : http://www.xxxxxxxxx.net/xxxx/member.php?s=&u=10538



I'm running 3.5.4, any ideas???

anybody?

Essam 06-05-2006 08:44 PM

is there way or script to see who agreed for the rule in individual page ?

Bubble #5 06-05-2006 10:19 PM

Quote:

Originally Posted by Essam
is there way or script to see who agreed for the rule in individual page ?

Everyone who can access that forum has agreed to it. A list wouldn't be needed as that would be redundant :bunny:

redlabour 06-08-2006 04:13 PM

Will it work in the Future with vBulletin 3.6 ?

TheHeartSmasher 06-09-2006 12:06 AM

Code:

Database error in vBulletin 3.5.4:

Invalid SQL:
SELECT * FROM vbruleshack
                        WHERE (fileurl LIKE 'http://www.teamcronus.net/' AND exactmatch = 1 )
                        OR (fileurl LIKE 'http://www.teamcronus.net/%' AND exactmatch = 0 ) AND active = 1 ORDER BY ruleid;

MySQL Error  : Table 'xxxxxxx.vbruleshack' doesn't exist
Error Number : 1146
Date        : Thursday, June 8th 2006 @ 05:54:56 PM
Script      : http://www.teamcronus.net/
Referrer    : http://www.teamcronus.net/forums/mem...name&order=asc
IP Address  : xxxxxxxxxxx
Username    : TheHeartSmasher
Classname    : vb_database

This is the error I get

Do you have a sql statment that I can use to create the table, or if anyone has one please post it.for the vbruleshack table.

I see two versions this one and a version 1.1.1 that always comes back even after I uninstall.

webgroup 06-09-2006 08:36 PM

Quote:

Originally Posted by webgroup
Just by installing the product I got this error in the whole forum:

Fatal error: Cannot redeclare check_rulesneeded() (previously declared in /home/xxxx/public_html/xxxxx/global.php(503) : eval()'d code:80) in /home/xxxxxx/public_html/xxxxxx/global.php(503) : eval()'d code on line 548

PLUS, i got this error message on my email:

Database error in vBulletin 3.5.4:

Invalid SQL:
SELECT * FROM vbnewruleshack
WHERE (fileurl LIKE 'http://www.xxxxxxx.net/xxxxxx/member.php?s=&u=10538' AND exactmatch = 1 )
OR (fileurl LIKE 'http://www.xxxxxx.net/xxxxxxx/member.php%' AND exactmatch = 0 ) AND active = 1 ORDER BY ruleid;

MySQL Error : Table 'XXXX.vbnewruleshack' doesn't exist Error Number : 1146
Date : Thursday, June 1st 2006 @ 12:25:58 PM
Script : http://www.xxxxxxxxx.net/xxxx/member.php?s=&u=10538



I'm running 3.5.4, any ideas???


Anybody?

Quarterbore 06-12-2006 03:52 AM

Strange new error on my website.... Trying to figure out is this mod is related...

Today I reformated my forums so that all my forums are now children under one form and the main reason I did this was to allow me to use this rules hack on all of my forums when I update my Code Of Conduct....

Well, I made the change this morning and I created a new rule for my "Updated Code" and I applied it to my new parent forum and all children (ALL FORUMS ON MY WEBSITE).

Well, after doing this I have got more then a few complaints about the following error:

Fatal error: Call to undefined function: preg_replace() in /home/MYSERVER/public_html/includes/class_core.php on line 1871

Following is the code from the includes file:


PHP Code:

    function strip_sessionhash(&$string)
    {
        
$string preg_replace('/(s|sessionhash)=[a-z0-9]{32}?&?/'''$string);
        return 
$string;
    } 

I have not turned off the rule yet as I am trying to see if there is any pattern to who is getting the error. I am also curious if there would be a problem if I have a rule that affects the parent and childern if one of the children has a second rule that also applies to it?

I have tried to reproduce the error on my computers with no luck but I have heard from half a dozen people that have had issues... Several of those are on AOL of all places so who knows...

SupremeWeapon 06-17-2006 09:45 PM

doesnt work for me. doesnt pull up any type of rules page when the selected area is reached.

Bubble #5 06-22-2006 02:44 AM

Quote:

Originally Posted by redlabour
Will it work in the Future with vBulletin 3.6 ?

Does anyone know if it's safe to install this in 3.6.2? :confused:

COBRAws 06-27-2006 08:51 PM

Quote:

Originally Posted by Bubble #5
Does anyone know if it's safe to install this in 3.6.2? :confused:

3.6.2 doesnt exist.


Im getting this SQL error

Code:

Database error in vBulletin 3.5.4:

Invalid SQL:
INSERT INTO ruleshack
                                    (forumid, ruletitle, ruletext, ruleurl, firstnewthread, groupids, memberids, userids,
                                    usernames, postmore, postless, joindateafter, joindatebefore,
                                    lastactiveafter, lastactivebefore, lastpostafter, lastpostbefore,
                                conditions, allowbbcode, active, repeat, childforum, newthread, newreply, viewforum, fileurl, exactmatch)
                                    values ('58', 'Seccion Pedidos', 'texto de regla', 'http://xxxxxxxxx/forumdisplay.php?f=58', '1',
                                    '4,6,15,3,1,14,7,2,18,17,19,12,10,5,8', '', '', '', '0',
                                    '0', UNIX_TIMESTAMP(''),
                                    UNIX_TIMESTAMP(''), UNIX_TIMESTAMP(''),
                                    UNIX_TIMESTAMP(''), UNIX_TIMESTAMP(''),
                                    UNIX_TIMESTAMP(''), '0', '1', '1', '0', '0', '1', '1', '0', '',
                                    '0');

MySQL Error  : 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 'repeat, childforum, newthread, newreply, viewforum, fileurl, exactmatch)
                    ' at line 5
Error Number : 1064
Date        : Tuesday, June 27th 2006 @ 06:54:16 PM
Script      : http://xxxxxxxxx/admincp/rulesagreement.php
Referrer    : http://xxxxxxxxx/admincp/rulesagreement.php?do=rule
IP Address  : xxxxxxxxx
Username    : xxxxxxxxx
Classname    : vB_Database_MySQLi


shoupz 07-01-2006 10:13 AM

great hack, i got it working but it doesnt show up in the profile after i did the templete edit, but still great hack! cheers.

Blue-Inc 07-01-2006 01:05 PM

Great Modification, works perfectly. Thank you for making it.

COBRAws 07-01-2006 04:36 PM

Quote:

Originally Posted by Blue-Inc
Great Modification, works perfectly. Thank you for making it.

You guys using MySQL 4 or 5?

Brian31fl 07-02-2006 12:36 AM

is there a guide on how to use it like setting up a rule?

Blue-Inc 07-02-2006 09:11 AM

Quote:

Originally Posted by COBRAws
You guys using MySQL 4 or 5?

MyQSL 4 ;)

Quote:

Originally Posted by Brian31fl
is there a guide on how to use it like setting up a rule?

Look at the screen shot(s).

Brian31fl 07-02-2006 06:15 PM

Quote:

Originally Posted by Blue-Inc
MyQSL 4 ;)



Look at the screen shot(s).

that still doesnt show ecatly what to fill in and explain how it used

COBRAws 07-06-2006 01:31 AM

Quote:

Originally Posted by Blue-Inc
MyQSL 4 ;)

I supposed. I use MySQL 5 and this hack doesnt work.

Ugga Bugga 07-07-2006 12:28 PM

what does this step mean?

Step 4. Import product-rulesagreement.xml

TMAC 07-09-2006 02:59 PM

Quote:

what does this step mean?
That means to go to your plugin sytem and import the file. You will find this near the bottom of your left hand admin control panel navigation menu.


This is a great hack, easy to install and works great! Testeted.

Clicks Install:)

blackshadowc4p 07-14-2006 12:14 PM

Question: I have just one forun where I enabled this (installed version 1.1.5). Altough I have it to show only for Full Members, all my moderators, supermods and me (only admin on primary usergroup, no secondary usergroup) have to agree with the rule. Why?

Hornstar 07-21-2006 07:42 AM

Originally Posted by uae
if you are talking about the Rule's Page URL field which is just under the rule's text field in the Add New Rule Page in ADMINCP, that would be the url to the rules and agreement page you've got already, if there was one, filling this field with a url will have the rules listed in the member profile page whenever they submit to agree on that rules..

Where do I find the URL to insert, im confused on this step.

tommykjensen 07-23-2006 07:26 AM

Will this be updated for vb 3.6 ?

Peter_Rosado 07-24-2006 03:36 PM

I'm having trouble with the profile of a user:

Database error in vBulletin 3.5.4:

Invalid SQL:
SELECT * from theprefixofthedb_ruleshack
WHERE ruleid in (5,3,2,) AND ruleurl <> '';

MySQL Error : 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 ') AND ruleurl <> ''' at line 2
Error Number : 1064
Date : Monday, July 24th 2006 @ 12:31:28 PM
Script : http://www.mundopoesia.com/foros/member.php?u=3874
Referrer : http://www.mundopoesia.com/foros/private.php?
IP Address :
Username :
Classname : vb_database


The other profiles work well.

Treak 07-27-2006 12:28 AM

DUDE this hack is insane and works like a charm can you for your nex instalment add a mod to it where you can RESTRICT users under 18 from accessing certain forums and or Subforums?
i have a NWS or Not Work Safe subforum in my offtopic section and i want only those that are 18 and up to be able to view it according to the rules.. you can't set permissions based on age in vBulletin but maybe your hack can include that? to where they cannot view the rules cause they are not 18 so they won't see the rules... so they cannot enter that section of the forum cause they cannot agree.. its kinda like setting permissions thru your rules without editing anyone users permissions on the actual forum it self does this make sense?

ixian 07-27-2006 01:22 AM

What's to stop someone from just lying about their age? Which, to access NWS forums, they most certainly will. Seems kind of pointless to me.

Treak 07-27-2006 02:15 AM

Quote:

Originally Posted by ixian
What's to stop someone from just lying about their age? Which, to access NWS forums, they most certainly will. Seems kind of pointless to me.

you can choose to have them set that up before they even join.. and you can make it to where they can not edit that part via user permissions.. just not forum specific..

Treak 07-27-2006 02:23 AM

Quote:

Originally Posted by hornstar1337
Originally Posted by uae
if you are talking about the Rule's Page URL field which is just under the rule's text field in the Add New Rule Page in ADMINCP, that would be the url to the rules and agreement page you've got already, if there was one, filling this field with a url will have the rules listed in the member profile page whenever they submit to agree on that rules..



Where do I find the URL to insert, im confused on this step.

OK !!! EVERYONE PAY ATTENTION!!!!

this is the easiest way to do this!

go to the section you plan on posting this user agreement for ..

for example.. lets say you have like i have a Not Work Safe Section in your Forum and you want to Set Rules and User Agreements for members so that way when they first VIEW! that NWS forum they have to agree to the rules or else they cannot view that section! GO TO YOUR NWS OR WHATEVER FORUM YOU WANT THE RULES FOR! MAKE A NEW STICKY THREAD! and name it NWS RULES! or whatever your forum name happens to be.

after you have laid out your rules in that thread.. close that thread so no one else can post there.. just all they can do is view those rules..

k now click on that thread so you can see your post... copy that URL from your browser and INSERT THAT LINK INTO THE URL AT THE TOP OF THE NEW RULE! WHERE IT ASKS YOU FOR THE URL FOR THE RULES PAGE!

now! when they view it and agree to it! and you view their PROFILE you will see they agreed to the NWS forum rules! and now when you click on that link that says NWS FORUM RULES! it takes you right to the RULES you POSTED! inside the NWS Forum!

you can use the same rules you just posted.. VIA COPY AND PASTE! and paste them into the New Rule your making for that forum!


so!! this is the effect you get!!

When the User now goes to view the NWS Section of your board they get the rules that THEY MUST AGREE TO! before they can view the forums there! once they click agree they are taken to the NWS forum

now! inside the forum you have your sticky thread up top that has the NWS rules! so the link in their user profile that says they agreed to NWS rules ! THAT LINK WILL TAKE YOU TO YOUR STUCK THREAD THAT HAS YOUR RULES IN IT!!!

hope that clarified alot for you guys.. if not i suck at life and please delete my post lol

redlabour 08-02-2006 07:36 AM

It will be nice if i can check different Sections/Forums to pull the Users to a Rule.

soletrader 08-02-2006 08:49 AM

How do I edit the text in the user agreement?

louis_chypher 08-02-2006 12:47 PM

Quote:

Originally Posted by hornstar1337
Originally Posted by uae
if you are talking about the Rule's Page URL field which is just under the rule's text field in the Add New Rule Page in ADMINCP, that would be the url to the rules and agreement page you've got already, if there was one, filling this field with a url will have the rules listed in the member profile page whenever they submit to agree on that rules..



Where do I find the URL to insert, im confused on this step.

Hi, There is a modification Rules Hack for vBulletin 3.5.x by Hasann that I use to create rule pages that holds the rules for my web site. I go to those pages of rules I created with Rules Hack for vBulletin 3.5.x by Hasann, copy the urls and paste them into the url location for this modification.

It would be great if this modification could be combined with the Rules Hack for vBulletin 3.5.x by Hasann modification. nudge, nudge.

louis_chypher 08-02-2006 01:01 PM

Quote:

Originally Posted by Treak
you can choose to have them set that up before they even join.. and you can make it to where they can not edit that part via user permissions.. just not forum specific..


Hi, While there is nothing to stop anyone from lieing about their age you can protect yourself (your site) by using a few 'tricks', like adding the modification

Age Lock is an all-in-one Forum locking facillity that works off the users age instead of there permissions. It gives you the abillity to keep those Under 18's out of your adult sections
and by enabling the COPPA and thorough a modification to the register.php line 99 to reflect only allowing those who say they are 18 or over to access the site:

Code:

if ($vbulletin->GPC['year'] < ($current['year'] - 18) OR ($vbulletin->GPC['year'] == ($current['year'] - 18) AND $vbulletin->GPC['month'] <= $current['month']))
That's about the best one can do *shrug*.

mhammed 08-03-2006 03:22 AM

great hack,
but the font size rules is too small . how can I increase it

louis_chypher 08-03-2006 10:49 AM

Quote:

Originally Posted by mhammed
great hack,
but the font size rules is too small . how can I increase it

<font size=X>rule text</font> works for me.

mhammed 08-04-2006 12:14 AM

Quote:

Originally Posted by louis_chypher
<font size=X>rule text</font> works for me.

very easy to say :D
but where you put this in the code? :surprised:

Chris Lang 08-04-2006 02:39 AM

I've installed this hack, and it works fine for the forums, but I can't get it to function with Private.php (PMs)

I'm using the format http://mydomain.com/forum/private.php (and every variation, including www, etc) but no luck. Any ideas?

Neo_obs 08-04-2006 07:02 AM

Quote:

Originally Posted by Chris Lang
I've installed this hack, and it works fine for the forums, but I can't get it to function with Private.php (PMs)

I'm using the format http://mydomain.com/forum/private.php (and every variation, including www, etc) but no luck. Any ideas?

disregard I fixed this the conditionals were set up wrong

ryansmith 08-04-2006 01:31 PM

Is this going to be released for vB 3.6, or is someone working on something similar?

moonclamp 08-05-2006 10:35 PM

My webhost recently upgraded our version of mySQL to 5.0.21

Ever since then I have been getting the following error email:

Quote:

Invalid SQL:
SELECT * FROM vb_ruleshack WHERE repeat = 1 AND active = 1;

MySQL Error : 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 '= 1 AND active = 1' at line 1 Error Number : 1064
Date : Sunday, August 6th 2006 @ 12:30:00 AM
Script : http://xxxxx/forums/cron.php?&rand=463803
Referrer : http://xxxxx/forums/showthread.php?t=3943&page=4
IP Address : 1xx.9x.21.xx
Username : Unregistered
Classname : vB_Database
It doesn't seem to affect anyone, just getting loads of emails telling me about the error.

None of my rules reset themselves, is it safe to just turn off the cron?


All times are GMT. The time now is 07:48 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01798 seconds
  • Memory Usage 1,862KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (3)bbcode_code_printable
  • (1)bbcode_php_printable
  • (19)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete