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

Reply
 
Thread Tools Display Modes
  #21  
Old 01-24-2004, 11:10 PM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I can't find any of the code you said to search for in the functions.php.

EDIT: I found the code in functions_newpost.php. It seems to work except for the thread title in the message and the Subject of the message. Can those be fixed?
Reply With Quote
  #22  
Old 01-25-2004, 10:40 AM
fly fly is offline
 
Join Date: Oct 2003
Posts: 1,215
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by NTLDR
It should replace it on any page, anywhere as long as the page goes through process_replacement_vars(), which all the main vB (forum) pages that output something do.

@flypaper, I'm a bit confused as to how you'd like this to work.
Lemme do an example and tell me if this can be done w/ vb3...

(original post with [you] hack): flypaper is cool.

(post quoted for reply w/ current hack): flypaper is cool.

(post quoted for reply w/ vb2 hack): [you] is cool.

Personally, I think it works better if the [you] code shows up in the quoted post. Hopefully, that makes sense now. Either way, I really appreciate the help.
Reply With Quote
  #23  
Old 01-25-2004, 10:50 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 flypaper
Lemme do an example and tell me if this can be done w/ vb3...

(original post with [you] hack): flypaper is cool.

(post quoted for reply w/ current hack): flypaper is cool.

(post quoted for reply w/ vb2 hack): [you] is cool.

Personally, I think it works better if the [you] code shows up in the quoted post. Hopefully, that makes sense now. Either way, I really appreciate the help.
That would be ok if it only showed up as [you] for the Admins and Mods. Otherwise, once everyone on the forum sees what the code is to do it, then you have everyone doing it and it gets old really quick. It kills it basically. On my site, once I get the thread title and subject of the email notifications taken care of, I am going to change the word for the hack to something no one will figure out so it won't get abused on the site.
Reply With Quote
  #24  
Old 01-25-2004, 04:30 PM
NTLDR's Avatar
NTLDR NTLDR is offline
Coder
 
Join Date: Apr 2002
Location: Bristol, UK
Posts: 3,644
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

@Boofo, sorry I meant functions_newpost.php

For the [you] part I think he means [you] appears and isn't the next to get the username.

To fix thread titles, find again in functions_newpost.php:

PHP Code:
$threadinfo['title'] = unhtmlspecialchars($threadinfo['title']); 
Add after:
PHP Code:
$temptitle =  $threadinfo['title']; 
Find: (you added this code from the above instructions)

PHP Code:
$pagetext preg_replace('/{bbusername}/i'$touser['username'], $pagetext); 
Add after:

PHP Code:
$threadinfo['title'] = preg_replace('/{bbusername}/i'$touser['username'], $threadinfo['title']); 
Find (again you added this from the above posts instructions):

PHP Code:
$pagetext $temptext
Add after:

PHP Code:
$threadinfo['title'] = $temptitle 
To get [you] working as I think you want it too, try this it should work:

in newreply.php find:

PHP Code:
$pagetext htmlspecialchars_uni($postinfo['pagetext']); 
Add before:

PHP Code:
$pagetext =  preg_replace('/{bbusername}/i''\[you\]'$pagetext); 
Reply With Quote
  #25  
Old 01-25-2004, 07:01 PM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This:

PHP Code:
$threadinfo['title'] = $temptitle 
is supposed to have a semi-colon after it, right?

Also, I put this:

PHP Code:
$temptitle $threadinfo['title']; 
AFTER the 2nd instance of this:

PHP Code:
$threadinfo['title'] = unhtmlspecialchars($threadinfo['title']); 
since it shows in 2 places in the file. Is it in the right place now?
Reply With Quote
  #26  
Old 01-25-2004, 09:03 PM
NTLDR's Avatar
NTLDR NTLDR is offline
Coder
 
Join Date: Apr 2002
Location: Bristol, UK
Posts: 3,644
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

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

Thank you and thank you, sir.
Reply With Quote
  #28  
Old 01-26-2004, 12:27 PM
fly fly is offline
 
Join Date: Oct 2003
Posts: 1,215
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Boofo
That would be ok if it only showed up as [you] for the Admins and Mods. Otherwise, once everyone on the forum sees what the code is to do it, then you have everyone doing it and it gets old really quick. It kills it basically. On my site, once I get the thread title and subject of the email notifications taken care of, I am going to change the word for the hack to something no one will figure out so it won't get abused on the site.
LOL

I enjoy watching my users abuse the n00bs. That's fun to me.
Reply With Quote
  #29  
Old 01-26-2004, 08:58 PM
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 flypaper
LOL

I enjoy watching my users abuse the n00bs. That's fun to me.
Did the [you] code NTLDR post for you work like you wanted it to?
Reply With Quote
  #30  
Old 01-27-2004, 12:15 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

NTLDR, one last area. Can we get this to work for the forum names in the archive display?
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 03:24 PM.


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.06317 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
  • (11)bbcode_php
  • (4)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
  • (3)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