Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 General Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 04-03-2002, 03:39 PM
Gutspiller's Avatar
Gutspiller Gutspiller is offline
 
Join Date: Dec 2001
Posts: 1,046
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Making a new "view new posts" link that only shows new posts in certain forums?

OK Firefly helped me with part of what my users wanted. They didn't want to click the "view new posts" and get all the news posts that don't have any replys in them. So FireFly helped me take those out. Now they want another button/link that will only show the new news posts, but they don't want it to replace the "view new posts" they want a new link for "view new news posts"

The way FireFly helped me before is just a few threads down in the forum currently, but is all he did was make it so that I could put in the forumid and exclude that forum from being in the "getnew" results. I was thinking I could just copy my search.php and do the exact opposite and exclude all the forums, except the news forums, but I was wondering if there was an easier way or if that WOULD be the easy way?

Any help would be great. Thanks!
Reply With Quote
  #2  
Old 04-03-2002, 03:44 PM
Admin's Avatar
Admin Admin is offline
Coder
 
Join Date: Oct 2023
Location: Server
Posts: 1
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Next time post this in the same thread please.

Anyway, in search.php find this:
Code:
    $datesql=" AND thread.lastpost>=".$bbuserinfo[lastvisit];

    $wheresql="1=1".$forumsql.$datesql;
    $wheresql.=" AND thread.open<>10";
Note: the middle line was changed due to what I helped you with before.
Replace that with this:
Code:
    $datesql=" AND thread.lastpost>=".$bbuserinfo[lastvisit];

    if ($newsonly) {
        $wheresql="1=1 AND forumid=XX".$datesql;
    } else {
        $wheresql="1=1".$forumsql.$datesql;
    }
    $wheresql.=" AND thread.open<>10";
Again, the line there is changed in your code.
Change XX to the ID of your news forum, then link to search.php?action=getnew&newsonly=1.
Reply With Quote
  #3  
Old 04-03-2002, 04:58 PM
Gutspiller's Avatar
Gutspiller Gutspiller is offline
 
Join Date: Dec 2001
Posts: 1,046
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

OK I am a little confused. So where do I put the forumid numbers for the news forum TO search? The ones that I have blocked where you helped me firsted, aren't the exact same ones that I want to be searched in the new news posts. I need two different sets of forumid places. Ones to exclude in the new posts link and one to include in the new news link.

Or did I not understand the instructions?

Oh and I didn't post it in the same thread, because I didn't want you to feel like I was only asking for your help, but if you don't mind then I will always bug you for help.
Reply With Quote
  #4  
Old 04-04-2002, 05:03 AM
Admin's Avatar
Admin Admin is offline
Coder
 
Join Date: Oct 2023
Location: Server
Posts: 1
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ok never mind my first post, I was tired last night.
Just link to search.php?action=getnew&forumid=XX where XX is your news forum's ID.
Reply With Quote
  #5  
Old 04-04-2002, 06:24 AM
Gutspiller's Avatar
Gutspiller Gutspiller is offline
 
Join Date: Dec 2001
Posts: 1,046
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by FireFly
Ok never mind my first post, I was tired last night.
Just link to search.php?action=getnew&forumid=XX where XX is your news forum's ID.
Nope I tried linking to http://www.theforumz.com/forumz/sear...68,158,165,166

and it still didn't work. it might help if you take a look what I have going on. :nervous: http://www.theforumz.com

I don't have one single news forum, I have 13 news forums. I am starting to think my original idea with coping the search.php might not be so bad after all.

Or are you sleepy again?
Reply With Quote
  #6  
Old 04-04-2002, 06:32 AM
Admin's Avatar
Admin Admin is offline
Coder
 
Join Date: Oct 2023
Location: Server
Posts: 1
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Just link to http://www.theforumz.com/forumz/sear...w&forumid=150. It will get subforums.
Reply With Quote
  #7  
Old 04-04-2002, 02:10 PM
Gutspiller's Avatar
Gutspiller Gutspiller is offline
 
Join Date: Dec 2001
Posts: 1,046
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by FireFly
Just link to http://www.theforumz.com/forumz/sear...w&forumid=150. It will get subforums.
Those forums that it's showing posts from are not even in the news catagory... What gives? aranoid:
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 05:01 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05513 seconds
  • Memory Usage 2,225KB
  • Queries Executed 13 (?)
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
  • (2)bbcode_code
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (7)post_thanks_box
  • (7)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (7)post_thanks_postbit_info
  • (7)postbit
  • (7)postbit_onlinestatus
  • (7)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_postinfo_query
  • fetch_postinfo
  • 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
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete