vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Rules hack (https://vborg.vbsupport.ru/showthread.php?t=68291)

HiDeo 08-12-2004 10:00 PM

Rules hack
 
Rules hack [3.0.3]

???????????????????????????????????????????
vB Version: vBulletin 3.0.3
Author: HiDeo
Email: webmaster@programmation-web.org
Site: http://www.programmation-web.org
???????????????????????????????????????????

Hack Information

Administrator can create rules for a forum !
Members and guests can see the rules.

Hack Specifications
  • vbphrases
  • navbar link
  • add, edit or delete rules via admincp

Hack Test

I test this hack on vBulletin 3.0.3

Hack Support

The support will be given here in this thread and at Programmation Web.

Hack Demos

Here (in french)

Important
  • If you do install this hack, please click on the INSTALL button. There are going to be some updates for this which you're really not going to want to miss!
  • It's my first hack in vb.org !!

Polo 08-13-2004 12:53 PM

Nice, great job, thanks for sharing!

*clicks install*

Polo 08-13-2004 02:07 PM

Ok, this mod is great... loved it... anyways, for those who would like to have their rules listed by date, (oldest first instead of newest rules first) change the following around line 55 of rules.php:

Code:

$rules = $DB_site->query("SELECT * FROM " . TABLE_PREFIX . "rules ORDER BY ruleid DESC");
to

Code:

$rules = $DB_site->query("SELECT * FROM " . TABLE_PREFIX . "rules ORDER BY ruleid ASC");

TheComputerGuy 08-13-2004 02:07 PM

Awesome hack! I like this alot

Polo 08-13-2004 02:13 PM

Quote:

Members can only see the rules.
What do i need to modify so that everyone, even guests can see the rules?

HiDeo 08-13-2004 03:22 PM

Very nice modifications polo ! ;)

Quote:

Members can only see the rules.
It's an error, first post edited

Koutaru 08-13-2004 03:49 PM

Nice Hack :) I'll definately be using this probably with another rules hack

ranger2kxlt 08-13-2004 07:04 PM

Whats the main purpose, seems like others seem to like it, but not really sure how it works or what it does....Some insight please :-D

turbidblue 08-14-2004 12:52 AM

thanks!

[high]* turbidblue clicks install :)[/high]

dndog 08-14-2004 05:13 PM

Bravo! Excellent hack.

/me clicks install.

Battle_Ring 08-14-2004 09:42 PM

Hmmm, I Click Rules, And A Blank Screen Shows Up!....Help Me Plz

Battle_Ring 08-14-2004 09:49 PM

Oh Nvm, My Fault...Got It...Great Hack!

mrboz 08-15-2004 02:10 PM

when i view the rules page the main section is too wide.

my forums have a width of 770, the main rules page sticks out, but if i view a rule it's back to the correct width

why is this?

(see attached picture)

daFish 08-15-2004 05:55 PM

Wow.
I was looking for this and will install it in the next days.

Great work.

Polo 08-16-2004 12:23 PM

Quote:

Originally Posted by mrboz
when i view the rules page the main section is too wide.

my forums have a width of 770, the main rules page sticks out, but if i view a rule it's back to the correct width

why is this?

(see attached picture)

in the template "rules"

find

PHP Code:

<table class="tborder" cellpadding="$stylevar[cellpadding]cellspacing="$stylevar[cellspacing]border="0" width="70%" align="center"

and change 70% to what fits you best ;)

mrboz 08-18-2004 07:47 AM

Quote:

Originally Posted by Polo
in the template "rules"

find

PHP Code:

<table class="tborder" cellpadding="$stylevar[cellpadding]cellspacing="$stylevar[cellspacing]border="0" width="70%" align="center"

and change 70% to what fits you best ;)

no that affects the rule list table only, not the width of the page.
i found out what is was tho...

there was no
PHP Code:

$stylevar[htmldoctype

at the top of the rules template

Caiman 08-26-2004 12:22 PM

Can't use HTML?

Mickie D 08-27-2004 09:10 PM

i installed this great hack but its not the one i was after :(

i was sure i read that you could make your members agree to the rules or they would not be allowed to view the forums ?

HiDeo 08-27-2004 09:34 PM

No, it's simply a display of your rules, but you can edit the rules in the register form ! Members have to agree this rules or they would not be allowed to view the forums

nelto 09-06-2004 03:12 AM

I just installed this, but....
where do I go on the admin area to insert my rules?
I cant find anything there.

Mamochka 10-20-2004 07:48 PM

I have a problem.
I have installed the hack,but i became an error from MySQL in init.php :
Line 517

What can i do?
I need this hack.

HiDeo 10-20-2004 09:11 PM

I suggest you to desinstall and reinstall the hack because I can't see the bug and nobody tell me about this bug !

Mamochka 10-21-2004 02:31 PM

Hallo!

Just now i have reinstall hack.
Here is error:
Warning: array_merge() [function.array-merge]: Argument #2 is not an array in /www/includes/init.php on line 517

Database error in vBulletin :
Invalid SQL:
SELECT * FROM style
WHERE (styleid = 0 AND userselect = 1)
OR styleid =
ORDER BY styleid ASC
LIMIT 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 'ORDER BY styleid ASC
LIMIT 1' at line 4
mysql error number: 1064

Script: http://www.*****/rules.php?
Referer: http://www.****/rules.php?

My init.php line 517:
), $specialtemplates);

Quote:

OR styleid =
The value is empty.
Where is a problem?

rex_b 10-30-2004 09:19 PM

I have a question.

I changed the name of the files to advertise.php and admincp/advertise.php and I changed the code where everytime I saw rules.php i put advertise.php

Now I got the hack all going I can access advertise.php and I can see the stuff in the admincp but when I try to add something in the admincp it just gives me a blank screen.

Did I miss something?

rex_b 10-31-2004 06:53 PM

anybody ^^^^

HiDeo 10-31-2004 08:28 PM

Do you edit the .php files ?

rex_b 10-31-2004 10:01 PM

edited them everywhere it said rules.php I changed to advertise.php

X-Fan 11-13-2004 04:01 AM

Cool hack, thanks!

I have a request, though, and that is to be able to select the order that the rules are displayed in. Is that possible to do?

rex_b 11-16-2004 06:31 PM

Quote:

Originally Posted by rex_b
edited them everywhere it said rules.php I changed to advertise.php

I figured it out. Just leave the admincp/rules.php the same. And it works!

shadiguy1 11-26-2004 10:44 AM

for some reason everything works for the rules hack except the Button in the admincp is showing up blank then if u click the blank button it will show rules manager and add a rule. Any info would be greatly helpful and yes the hack is working otherwise i can ad rules and they will display on the forums if clicked just the title of the button in admincp is not working please help

Delphiprogrammi 12-16-2004 03:41 PM

installation went fine but no rules i add them but they don't show up in the attached image you'll see what i mean

TwinsX2Dad 12-16-2004 04:21 PM

Did you upload the rules.php files correctly?

One goes in your forum root directory, while the other (admin/rules.php) goe in your admincp folder.

My install went flawlessly, even though I did a little customizing on the fly.

*** install clicked ***

trevelyn1015 12-16-2004 04:31 PM

Execute this request :

CREATE TABLE rules (
ruleid int(5) unsigned NOT NULL auto_increment,
title varchar(50) NOT NULL default '',
description mediumtext NOT NULL,
PRIMARY KEY (ruleid)
) TYPE=MyISAM;

?????????????????????

Delphiprogrammi 12-16-2004 04:44 PM

hehe the database table is already there otherwise it wouldn't work at all i see that "nav groep" in my acp i can even add rules but ....

HiDeo 12-16-2004 09:35 PM

TRy to reupload the rules.php files !

FlyingHammer 01-01-2005 12:05 AM

aight, I know htis is a stupid mistake on my part some where. I have been at this for 2 pathetic hours, I have deleted and reinstalled, checked the list twice, 2 problems.

1. Rules is NOT showing up on the navbar --I bet this is a style error of somesort, I only have 2 styles default and HT I have done everything in HT.

2.The button in the admincp DOES NOT say Rules manager --I redid the phrases trying to correct this and looked in the rules.php.

Any help please, ohh and I have the forums shut off for this and about 4 other hacks, simply due to backing it up and haveing people post whaile I was working onit. I found it easier to tell em to wait thatn to deal with loosing their posts when ya have to restore from the backup so time is of the essance here.

THANKS, Hammer

FlyingHammer 01-01-2005 09:58 PM

Alrighty then, I got #'s 1 and 2 fixed, now when I click on the "rules" in the nav dar I get a blank whit screen. I am able to add rules in the admincp, its on the navbar all is coolio but the blank whit screen.

I have uploaded rules.php twice to double check nd I have them in the right folders. Any help?

stevey 03-21-2005 07:15 PM

Quote:

Originally Posted by FlyingHammer
Alrighty then, I got #'s 1 and 2 fixed, now when I click on the "rules" in the nav dar I get a blank whit screen. I am able to add rules in the admincp, its on the navbar all is coolio but the blank whit screen.

I have uploaded rules.php twice to double check nd I have them in the right folders. Any help?

i have just installed it and have the same problem, when you go to rules page its just a blank screen ? thanks

Polo 03-21-2005 08:29 PM

you need to probably add the templates in step 4

stevey 03-21-2005 11:47 PM

thanks :) i missed one of templates out. working now :D


All times are GMT. The time now is 04:47 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.01270 seconds
  • Memory Usage 1,818KB
  • 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
  • (2)bbcode_code_printable
  • (3)bbcode_php_printable
  • (7)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)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