vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Hide thread from forum (https://vborg.vbsupport.ru/showthread.php?t=108619)

kgp43 02-22-2006 12:55 PM

Hide thread from forum
 
Hi,

I have a thread that I wan't only to be accessed by direct link.
I tried to set "visible" to 0 directly in the database, but only admin and moderators have access to the thread then (others get "Access denied").

How do I give everybody access to the thread (if they have the link) and still hide it from the forum (like when I set "visible" to 0)?

kgp43 02-22-2006 12:59 PM

Woops, can someone move this to the correct forum?
https://vborg.vbsupport.ru/forumdisplay.php?f=111

LincolnForums 02-22-2006 02:10 PM

Create a forum, give it a visible of 0 in the AdminCP, move that thread into it, and your done :D

kgp43 02-25-2006 10:49 AM

I tried it but it does not work.
You can see all threads if you know the forum id of the hidden forum, which isnt that hard to find :P

Think I found a solution but need a little help.

- I created a coloumn in the table 'thread' with the name "hide".
- If the value of 'hide' is '0' then the thread will be displayed as normal (forumdisplay.php).

Have been looking at the forumdisplay.php coding, but can't locate the query where I should add " AND hide='0' ".
Anyone know where to add this?

////////////////////////////////////////////////////

Think I found it.
Is this correct:

$getthreadids = $db->query_read("
SELECT " . iif($sortfield == 'voteavg', $votequery) . " threadid
$hook_query_fields
FROM " . TABLE_PREFIX . "thread AS thread
$hook_query_joins
WHERE forumid = $foruminfo[forumid]
AND hide= 0 AND sticky = 0
$visiblethreads
$globalignore
$datecut
$limitothers
$hook_query_where
ORDER BY sticky DESC, $sqlsortfield $sqlsortorder
LIMIT $limitlower, $perpage
");


All times are GMT. The time now is 03:27 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.00980 seconds
  • Memory Usage 1,712KB
  • 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)post_thanks_navbar_search
  • (1)printthread
  • (4)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