Go Back   vb.org Archive > vBulletin Article Depository > Read An Article > Programming Articles
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
How To Move anything, including shoutboxes, into any forum
HPIA
Join Date: Jul 2006
Posts: 196

 

Show Printable Version Email this Page Subscription
HPIA HPIA is offline 10-28-2006, 10:00 PM

I have asked so many people and the task was a simple if condition code and moving a template. It took me forever to figure out, but here I am.

First, go to your vbshout template. Copy it all.

Now go to the FORUMDISPLAY template. You can put it in two places. You can put it in many places: exactly under $navbar, or exactly right above $forumbits. I recomend right above $forumbits. Fill in the code then past that down wherever you want it to show up in your forum.

Code:
<if condition="$forumid==XXX">

Code here...

</if>
Change the XXX to the forum id you want to move this to.

This will work for anything, not just shoutboxes, cboxes, etc. But I thought I'd post this up since no one could tell me the answer.

Plus, now the vbshout template is no longer needed. You can delete the template if you want. If you do delete it, the shoutbox on the main index will then disappear, which you most likely want.

I am not sure, but there is probably a way to just put like $vbshout instead of deleting the current template and pasting that long code, but I am not a coder, and couldn't tell you that. I will do some studying, as I have a hunch.

Enjoy .
Reply With Quote
  #2  
Old 10-31-2006, 02:23 AM
HPIA HPIA is offline
 
Join Date: Jul 2006
Posts: 196
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Found it!

Here is the easiest way to move the shoutbox. Use peterska2's tutorial on making custom templates via plugins, see here. By using the stand template name, or you can change it I suppose, $forumhome_vbshout , you can then keep all templates unfooled around with .

Easy!

Again, I am sure most of you coders know how to do this easily, but I didn't and I asked for help and no one could give me an honest answer. But I figured it out eventually, after my board crashing...twice XD. So yeah, criticism or comments or whatever is welcome
Reply With Quote
  #3  
Old 06-04-2007, 04:44 PM
tillcat5 tillcat5 is offline
 
Join Date: May 2007
Posts: 64
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

this works .. i just cant get it to add more then one forum id and still work. any suggestions
Reply With Quote
  #4  
Old 06-04-2007, 04:56 PM
dyna88 dyna88 is offline
 
Join Date: Dec 2006
Location: Wisconsin
Posts: 164
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Maybe try an array???

HTML Code:
<if condition="in_array($forumid, array(X,Y,Z))">
</if>
Reply With Quote
  #5  
Old 06-04-2007, 05:45 PM
tillcat5 tillcat5 is offline
 
Join Date: May 2007
Posts: 64
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

thanks
Reply With Quote
  #6  
Old 06-11-2007, 02:30 PM
fly fly is offline
 
Join Date: Oct 2003
Posts: 1,215
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Now, if you could move thread icons into the thread itself without file edits, I'd probably start a religion based on you.

(I know its an entirely different task, but seems semi-related to me.)
Reply With Quote
  #7  
Old 04-23-2008, 08:16 PM
Jasem's Avatar
Jasem Jasem is offline
 
Join Date: Feb 2006
Location: www.menokia.com
Posts: 594
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thank you very much
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 08:51 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.03881 seconds
  • Memory Usage 2,252KB
  • Queries Executed 22 (?)
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)bbcode_code
  • (1)bbcode_html
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_article
  • (1)navbar
  • (4)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
  • (6)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