vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Need help (https://vborg.vbsupport.ru/showthread.php?t=46392)

Roody 12-05-2002 12:47 PM

Need help
 
I have made two posts about this, but havent received any help so far, so Im providing those posts in here. Here is my situation. I am currently running a hack that shows the number of threads/posts since a persons last visit. The problem with the hack is, that it isnt done at member level meaning people who dont have permission to see certain forums are still having the hack tell them that posts are there to be seen when they arent.

Naturally this is a bit confusing, and I could use any help that someone could provide. Here is the link where I have been trying to obtain help. Thanks

Link

N9ne 12-05-2002 03:08 PM

I don't understand...do you want something that will cut out the new posts and threads of a private forum which the user cannot access?

NTLDR 12-05-2002 03:50 PM

If you have moderation on for forums or users then this is why, you need to add:

[SQL]AND visible=1[/SQL]

To the WHERE clause of both the queries you add to index.php

Roody 12-05-2002 04:14 PM

ok here is what I mean. lets say you are a basic member on my boards. When you click on the new posts/new thread hack which lists exactly how many are new since your last visit if your permissions arent set to see all the forums then even if it lists posts as being new it may come up saying that their is no more new ones.

My questions is, is there a way to incorporate this hack on the member level so the hack correctly shows new posts and threads based on a person's permissions?

As for your post NTDLR..im not sure I follow if what you showed me will do this? Does it?

Erwin 12-06-2002 02:37 AM

In your query, put what NTLDR wrote after the WHERE section of that query, so that only posts visible to the user is counted.

Roody 12-06-2002 11:32 AM

ok thanks Erwin for clearing that up for me. I was a little confused with what NTDLR was saying.

Roody 12-08-2002 05:43 PM

ok guys i finally got this up and running, but i got the following error when I ran that query:

Error

SQL-query :

AND visible = 1

MySQL said:

You have an error in your SQL syntax near 'AND visible = 1' at line 1

Dean C 12-08-2002 06:11 PM

[sql]
AND visible = '1'
[/sql]

That should be part of the query

You shouldn't have the apostrophes in those positions

- miSt

Roody 12-08-2002 07:08 PM

I actually did it without apostrophes also Mist, and received the same error. Any other ideas?

NTLDR 12-08-2002 07:15 PM

Can you post the entire query from the PHP file here?


All times are GMT. The time now is 08:49 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.00946 seconds
  • Memory Usage 1,727KB
  • 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
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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