Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Replace Text Details »»
Replace Text
Version: 1.00, by amykhar amykhar is offline
Developer Last Online: Nov 2013 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 03-12-2003 Last Update: Never Installs: 18
 
No support by the author.

This is more of a getting you started piece of code than a copy and paste your board is hacked kind of release. If you don't know how to code in PHP, this hack is NOT for you.


What this "hack" does is it allows you to replace a word in a post with something else. It doesn't replace the word in titles or anywhere else like replacements do. Just in a post.

What I use it for: I replace the word Netflix in every post with a link to my Netflix affilliate.

What you might use it for: affilliate links, swear word replacements with style, pranks, whatever

You will need to modify the function that I have included to set up your own replacement words. You might want to replace more than one thing. It's up to you. Have fun with this and share what you have done.

Demo:

http://www.eaforums.com/forums/showt...threadid=22557

I will help as much as I can in customizing this for you within reason.

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #32  
Old 06-02-2003, 01:30 AM
limey's Avatar
limey limey is offline
 
Join Date: Dec 2001
Location: -
Posts: 187
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

When the correct phrase is typed in html link is the output, but its text and not linkable. Anyway to make it just show FOO linked?

Ive seen this output on your site as well Amy for the Netflix code. Is this way its supposed to be?

<a href="http://www.foo.com/index.html?fooAffilID=716" TARGET="_top">FOO</a>

thanks again.
Reply With Quote
  #33  
Old 06-02-2003, 01:50 AM
amykhar's Avatar
amykhar amykhar is offline
 
Join Date: Oct 2001
Location: PA
Posts: 4,438
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Not sure what you are asking Limey
Reply With Quote
  #34  
Old 06-02-2003, 01:57 AM
limey's Avatar
limey limey is offline
 
Join Date: Dec 2001
Location: -
Posts: 187
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ok go to this link:

http://www.eaforums.com/forums/showt...hlight=netflix

Goto Joubert's post. The output from the hack is not linkable. I'm seeing the same output of html on the site. I was wondering if there was a way to make the output a real link and not just text.

Hope I'm not confusing ya!
Reply With Quote
  #35  
Old 06-06-2003, 04:43 PM
xone9 xone9 is offline
 
Join Date: Jun 2003
Posts: 4
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

is this still working?
Reply With Quote
  #36  
Old 06-06-2003, 07:14 PM
amykhar's Avatar
amykhar amykhar is offline
 
Join Date: Oct 2001
Location: PA
Posts: 4,438
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Limey, It's not working on my site right this second because I have a clean functions.php installed. My functions.php was corrupted a few days ago and I haven't rehacked it.

Amy
Reply With Quote
  #37  
Old 06-06-2003, 07:14 PM
amykhar's Avatar
amykhar amykhar is offline
 
Join Date: Oct 2001
Location: PA
Posts: 4,438
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Xone, yes it still works.

Amy
Reply With Quote
  #38  
Old 06-07-2003, 04:07 AM
limey's Avatar
limey limey is offline
 
Join Date: Dec 2001
Location: -
Posts: 187
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I have the hacked functions and its doing the same thing on my site as it is on your site. Very weird.
Reply With Quote
  #39  
Old 06-07-2003, 04:13 AM
limey's Avatar
limey limey is offline
 
Join Date: Dec 2001
Location: -
Posts: 187
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

<a href="http://www.pokeritis.com/forums/showthread.php?threadid=11612" target="_blank">my example</a>
Reply With Quote
  #40  
Old 06-07-2003, 05:56 AM
gmarik's Avatar
gmarik gmarik is offline
 
Join Date: May 2002
Location: Mocsow
Posts: 1,288
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great! If it would for titles - it would be ven better!
Reply With Quote
  #41  
Old 06-07-2003, 07:51 AM
Darax The Good Darax The Good is offline
 
Join Date: Jan 2003
Posts: 29
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I can't seem to get this to work. My problem is that I can't find the proper place to put stri_replace. The doc says to find
[code[]?> [/code[]

but I can't seem to find that in functions.php. What am I missing?
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:04 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.05141 seconds
  • Memory Usage 2,301KB
  • Queries Executed 25 (?)
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)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)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