vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Advanced Warning System (AWS) (https://vborg.vbsupport.ru/forumdisplay.php?f=105)
-   -   Error if user has no rights (https://vborg.vbsupport.ru/showthread.php?t=77127)

jluerken 02-27-2005 12:45 PM

Error if user has no rights
 
Hi,

I have a huge problem with the actual AWS 3.1.8 installation.
Everytime a user does something where he has no rights for, he is getting an error message.

white browser page with:
Fatal error: Call to a member function on a non-object in /pathtomyforum/forum/includes/functions.php on line 2174

Line 2174 says:
PHP Code:

$warn_opts=$DB_site->query_first("select * from ".TABLE_PREFIX."warning_options where oid='1'"); 

He is getting this error instead of the message that he has no right to access this page.

Is this line needed there or did I copy&paste something wrong there?

Kind regards
jluerken

sv1cec 02-28-2005 06:39 AM

Quote:

Originally Posted by jluerken
Hi,

I have a huge problem with the actual AWS 3.1.8 installation.
Everytime a user does something where he has no rights for, he is getting an error message.

white browser page with:
Fatal error: Call to a member function on a non-object in /pathtomyforum/forum/includes/functions.php on line 2174

Line 2174 says:
PHP Code:

$warn_opts=$DB_site->query_first("select * from ".TABLE_PREFIX."warning_options where oid='1'"); 

He is getting this error instead of the message that he has no right to access this page.

Is this line needed there or did I copy&paste something wrong there?

Kind regards
jluerken

Strange, this part of the code change, is used for users who are banned from the forums, it has nothing to do with other usage. Can you please provide me with an example if what you mean with "Everytime a user does something where he has no rights for"?

Rgds

jluerken 02-28-2005 07:49 AM

Quote:

Originally Posted by sv1cec
Strange, this part of the code change, is used for users who are banned from the forums, it has nothing to do with other usage. Can you please provide me with an example if what you mean with "Everytime a user does something where he has no rights for"?

Rgds

Hi John,

I will send you some testdata now via PM.

sv1cec 02-28-2005 08:14 AM

Quote:

Originally Posted by jluerken
Hi John,

I will send you some testdata now via PM.

A little bit above that, in file functions.php, there is a line which should look like:

PHP Code:

global $DB_site$vboptions$logincode$url$bbuserinfo$session$stylevar

Make sure you have $DB_site in that line.

jluerken 02-28-2005 08:51 AM

Quote:

Originally Posted by sv1cec
A little bit above that, in file functions.php, there is a line which should look like:

PHP Code:

global $DB_site$vboptions$logincode$url$bbuserinfo$session$stylevar

Make sure you have $DB_site in that line.

You are right, it was not there. Don't know why!
After adding it the problem is gone.

Thanks for your help.


All times are GMT. The time now is 04:39 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.01006 seconds
  • Memory Usage 1,734KB
  • 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
  • (4)bbcode_php_printable
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (5)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete