Go Back   vb.org Archive > Community Discussions > Modification Requests/Questions (Unpaid)
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #11  
Old 02-25-2004, 10:46 PM
Andreas's Avatar
Andreas Andreas is offline
 
Join Date: Jan 2004
Location: Germany
Posts: 6,863
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

That might happen on the frist call as the cashed search is deleted after displaying the results.
Reply With Quote
  #12  
Old 02-25-2004, 10:59 PM
Reverend Reverend is offline
 
Join Date: Mar 2002
Location: England
Posts: 206
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Nope,after several refreshes,logging out/in and deleting temp internet files it still shows a couple of threads with replies.
Reply With Quote
  #13  
Old 02-25-2004, 11:44 PM
Andreas's Avatar
Andreas Andreas is offline
 
Join Date: Jan 2004
Location: Germany
Posts: 6,863
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hmm ...
Does the nocache=1 appear in the URL when the search results are being displayed?
Reply With Quote
  #14  
Old 02-26-2004, 12:09 AM
Reverend Reverend is offline
 
Join Date: Mar 2002
Location: England
Posts: 206
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

When the results are displayed the url is forums/search.php?searchid=xxxx

the xxxx is always the same number
Reply With Quote
  #15  
Old 02-26-2004, 12:27 AM
Andreas's Avatar
Andreas Andreas is offline
 
Join Date: Jan 2004
Location: Germany
Posts: 6,863
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

OK, so it still uses the cached results.

Maybe this does work (remove the other mods):

In search.php FIND
PHP Code:
// check our results and decide what to do
switch ($highScore
ABOVE that ADD
PHP Code:
if ($highScore AND $_REQUEST['dontcache']) {
  
$highScore 0;
  
$DB_site->query("DELETE FROM " TABLE_PREFIX "search WHERE searchid=$search[searchid]");

Reply With Quote
  #16  
Old 02-26-2004, 01:07 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Will the same line be used for the link then?
Reply With Quote
  #17  
Old 02-26-2004, 04:01 AM
EvilLS1's Avatar
EvilLS1 EvilLS1 is offline
 
Join Date: Apr 2002
Location: Georgia, USA
Posts: 987
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Why not show unanswered threads on a forum by forum basis or for specific forums with a link on the index page?

I have it set up like that on my test forum and it seems to work nicely. Comes in handy if you want to quickly see just the unanswered posts from specific forums such as a support or tech forum without having to go to the search page.

To do it, open forumdisplay.php and find:
Code:
$actiontemplates = array(
	'none' => array(
		'FORUMDISPLAY',
		'threadbit',
		'threadbit_deleted',
		'forumdisplay_announcement',
		'forumhome_lastpostby',
		'forumhome_forumbit_level1_post',
		'forumhome_forumbit_level2_post',
		'forumhome_forumbit_level1_nopost',
		'forumhome_forumbit_level2_nopost',
		'forumdisplay_loggedinuser',
		'forumhome_moderator',
		'forumdisplay_moderator',
		'forumdisplay_sortarrow',
		'forumhome_subforumbit_post',
		'forumhome_subforumseparator_post',
		'forumrules'
	)
Replace it with:
Code:
$actiontemplates = array(
	'none' => array(
		'FORUMDISPLAY',
		'threadbit',
		'threadbit_deleted',
		'forumdisplay_announcement',
		'forumhome_lastpostby',
		'forumhome_forumbit_level1_post',
		'forumhome_forumbit_level2_post',
		'forumhome_forumbit_level1_nopost',
		'forumhome_forumbit_level2_nopost',
		'forumdisplay_loggedinuser',
		'forumhome_moderator',
		'forumdisplay_moderator',
		'forumdisplay_sortarrow',
		'forumhome_subforumbit_post',
		'forumhome_subforumseparator_post',
		'forumrules'
	),
	'getunanswered' => array(
		'FORUMDISPLAY',
		'threadbit',
		'threadbit_deleted',
		'forumdisplay_announcement',
		'forumhome_lastpostby',
		'forumhome_forumbit_level1_post',
		'forumhome_forumbit_level2_post',
		'forumhome_forumbit_level1_nopost',
		'forumhome_forumbit_level2_nopost',
		'forumdisplay_loggedinuser',
		'forumhome_moderator',
		'forumdisplay_moderator',
		'forumdisplay_sortarrow',
		'forumhome_subforumbit_post',
		'forumhome_subforumseparator_post',
		'forumrules'
	)
Find:
Code:
$threadscount = $DB_site->query_first("
Above it add:
Code:
if ($_REQUEST['do'] == 'getunanswered') 
{
$condition = "AND replycount=0";
}
else
{
$condition = "";
}
Find:
Code:
		FROM " . TABLE_PREFIX . "thread AS thread
		$deljoin
		WHERE forumid = $foruminfo[forumid]
Replace it with:
Code:
		FROM " . TABLE_PREFIX . "thread AS thread
		$deljoin
		WHERE forumid = $foruminfo[forumid]
                                $condition
Find:
Code:
WHERE thread.threadid IN (0$ids)
Replace it with:
Code:
WHERE thread.threadid IN (0$ids)
$condition
Then just put this somewhere in your forumhome_forumbit_level2_post & forumhome_forumbit_level1_post templates.
Code:
(<a href="forumdisplay.php?$session[sessionurl]f=$forum[forumid]&do=getunanswered">View Unanswered Threads</a>)
Reply With Quote
  #18  
Old 02-26-2004, 04:57 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by KirbyDE
OK, so it still uses the cached results.

Maybe this does work (remove the other mods):

In search.php FIND
PHP Code:
// check our results and decide what to do
switch ($highScore
ABOVE that ADD
PHP Code:
if ($highScore AND $_REQUEST['dontcache']) {
$highScore 0;
$DB_site->query("DELETE FROM " TABLE_PREFIX "search WHERE searchid=$search[searchid]");

That works great! Can we do this on a forum by forum basis with a link in each forum just for that forum?
Reply With Quote
  #19  
Old 02-26-2004, 08:14 AM
Andreas's Avatar
Andreas Andreas is offline
 
Join Date: Jan 2004
Location: Germany
Posts: 6,863
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Yes you can limit that on one (or multiple) forums:

/search.php?do=process&replyless=1&replylimit=0&don tcache=1&forumchoice[]=id
Reply With Quote
  #20  
Old 02-26-2004, 08:19 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Like this?

PHP Code:
&forumchoice[1,5,7
or

PHP Code:
 &forumchoice[12
If I put a link in each forum on forumhome, is there a way to pull the ID out automatically of will it do that this way?

Aslo, how can I add this to the search.php so the date and time show up in there too when searching? I have been trying for a couple of hours now to add it there, but to no avail.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 11:29 AM.


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.08320 seconds
  • Memory Usage 2,277KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (9)bbcode_code
  • (6)bbcode_php
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete