Jump to content
xisto Community
chaosx2x

SMF - Shout Box Mod Installation Help Requested

Recommended Posts

hey! i'm the first to open a topic in this forum! :D

I've a problem, i've donwloaded and installed with success SMF board, then i've downloaded Shout Box created by Grudge

Shout Box MOD

installed it with success...but i can't find the shoutbox....in admin control panel i can set up many options of shout box but i can see it into my forum....on SMF forum them say i have to add some codelines in my index.template.php but i dunno how to do that....can anyone help me?

THX in advance!

Share this post


Link to post
Share on other sites

Hi guys, you'll need to edit your template to include the shoutbox.

 

Open:

Themes > default > index.template.php

 

Add in the template where you want the shoutbox:

smfshout()

=OR=

', smfshout() ,'

 

Use the first command if you are not inside an echo command.

And use thae second command if you are inside a echo command.

 

Here is what I did:

Find:

// The "key stats" box.	echo '   	 <div class="headertitles" style="width: 260px;"><img src="', $settings['images_url'], '/blank.gif" height="12" alt="" /></div>   	 <div class="headerbodies" style="width: 260px; position: relative; background-image: url(', $settings['images_url'], '/box_bg.gif);">      <img src="', $settings['images_url'], '/', $context['user']['language'], '/keystats.gif" style="position: absolute; left: -1px; top: -16px;" alt="" />      <div style="height: 35px; padding: 5px;" class="smalltext">     	 <b>', $modSettings['totalMessages'], '</b> ', $txt[95], ' ', $txt['smf88'], ' <b>', $modSettings['totalTopics'], '</b> ', $txt[64], ' ', $txt[525], ' <b>', $modSettings['memberCount'], '</b> ', $txt[19], '<br />     	 ', $txt[656], ': <b> <a href="', $scripturl, '?action=profile;u=', $modSettings['latestMember'], '">', $modSettings['latestRealName'], '</a></b>      </div>   	 </div>';	echo '    </td> 	 </tr>';

Add After:

// The "shoutbox" box.	echo ' 	 <tr>    <td align="left"><!-- // Shout Box Script Start-->   	 <div class="headertitles" style="margin-right: 5px; position: relative;"><img src="', $settings['images_url'], '/blank.gif" height="12" alt="" /></div>   	 <div class="headerbodies" style="position: relative; margin-right: 5px; background-image: url(', $settings['images_url'], '/box_bg.gif);">      <img src="', $settings['images_url'], '/', $context['user']['language'], '/shoutbox.gif" style="position: absolute; left: -1px; top: -16px;" alt="" />      <div style="overflow: auto; padding: 5px;" class="smalltext">',smfshout(),'</div>   	 </div><!-- // Shout Box Script End-->    </td>    <td align="center">   	 <!-- // blank table cell here -->    </td> 	 </tr>';
I actually use the blank table cell for a translation box from http://search.yahoo.com/?fr=altavista.

 

This will give you a box similar to the News Flash box. You'll need to create a shoutbox.gif and place it in your images directory.

 

Additionally, I edited the shout.template.php to customize the look of the shout box.

 

Happy Modding, :D

vujsa

Share this post


Link to post
Share on other sites

i've the changes to moy index.template.php but i've received an error :D

Template Parse Error!There was a problem loading the /Themes/default/index.template.php template or language file. Please check the syntax and try again - remember, single quotes (') often have to be escaped with a slash (\). To see more specific error information from PHP, try accessing the file directly.

You may want to try to refresh this page or use the default theme.


This is the code as i changed it

// The "key stats" box.	echo '   	 <div class="headertitles" style="width: 260px;"><img src="', $settings['images_url'], '/blank.gif" height="12" alt="" /></div>   	 <div class="headerbodies" style="width: 260px; position: relative; background-image: url(', $settings['images_url'], '/box_bg.gif);">      <img src="', $settings['images_url'], '/', $context['user']['language'], '/keystats.gif" style="position: absolute; left: -1px; top: -16px;" alt="" />      <div style="height: 35px; padding: 5px;" class="smalltext">     	 <b>', $modSettings['totalMessages'], '</b> ', $txt[95], ' ', $txt['smf88'], ' <b>', $modSettings['totalTopics'], '</b> ', $txt[64], ' ', $txt[525], ' <b>', $modSettings['memberCount'], '</b> ', $txt[19], '<br />     	 ', $txt[656], ': <b> <a href="', $scripturl, '?action=profile;u=', $modSettings['latestMember'], '">', $modSettings['latestRealName'], '</a></b>      </div>   	 </div>';	echo '    </td> 	 </tr> // The "shoutbox" box.echo '  <tr>   <td align="left"><!-- // Shout Box Script Start-->    <div class="headertitles" style="margin-right: 5px; position: relative;"><img src="', $settings['images_url'], '/blank.gif" height="12" alt="" /></div>    <div class="headerbodies" style="position: relative; margin-right: 5px; background-image: url(', $settings['images_url'], '/box_bg.gif);">     <img src="', $settings['images_url'], '/', $context['user']['language'], '/shoutbox.gif" style="position: absolute; left: -1px; top: -16px;" alt="" />     <div style="overflow: auto; padding: 5px;" class="smalltext">',smfshout(),'</div>    </div><!-- // Shout Box Script End-->   </td>   	 </table>  <a href="#" onclick="shrinkHeader(!current_header); return false;"><img id="upshrink" src="', $settings['images_url'], '/', empty($options['collapse_header']) ? 'upshrink.gif' : 'upshrink2.gif', '" alt="*" title="', $txt['upshrink_description'], '" style="margin: 2px 0;" border="0" /></a><img id="upshrinkTemp" src="', $settings['images_url'], '/blank.gif" alt="" style="margin-right: 2ex;" />';  // Show the menu here, according to the menu sub template.  template_menu();	echo '

i'm very newbie, so maybe it's my fault :D. pls check my modified code ;)

THX for the quick reply man! u're great!

Share this post


Link to post
Share on other sites

You're missing a closing quote.

 

CODE

==============================================================================

</div>

</div>';

 

echo '

</td>

</tr>';

// The "shoutbox" box.

 

echo '

<tr>

<td align="left">

 

<!-- // Shout Box Script Start-->

 

==============================================================================

 

This should do it for you.

 

Good luck to you.

Once you get it to work, you'll be able to more easily see how you can customized the template to suit your needs.

 

Happy Shouting, :D

vujsa

Share this post


Link to post
Share on other sites

Thanks vujsa! I just remembered that I was using a different theme.So I carried out those commands and got a fatal error, so then I couldn't open any of the forum pages so i went and reinstalled the Subs file and now my shop is giving me problems...so fustrating.On a related note, the Shop MOD is really interesting and it is really simple to deploy new items that can annoy your members but also let them have so much fun. I created my own STEAL item which randomly guessed whether the steal was successful and if it wasn't the person trying to steal money lost theirs. And I was creating a button on the profile that you could click to steal their money, but now I can't...I just hope I dont have to reinstall the whole thing again!!

Share this post


Link to post
Share on other sites

Your mods will probably be screwed if you upload subs.php again, its one of the core files along with load.php. If you can go into your admin panel and remove the mod using the uninstaller and then install again, yeah the shop mod is a weird shop alright.

Share this post


Link to post
Share on other sites

We're happy to help. Glad to hear that everything is working for you now.Now you can try to customize the script further for you specific needs.Alway backup the file you're going to work of first.Let us know if you run into further problems.[hr=][/hr]vujsa

Share this post


Link to post
Share on other sites

BBCode in the Shoutbox?

 

We all want bbcode in the shoutbox. The shoutbox will parse bbcode correctly but the user has to insert the bbcode by hand.

 

I posted a request for help on the SMF - Shoutbox forum, but only got one responce. An email from some guy that needed help with something kind of simple.

 

The bbcode helper uses JavaScript to insert bbcode correctly in the text box.

I haven't had a chance to get far enough into the code to figure out how to create a bbcode helper for the Shoutbox. The regular bbcode helper on the forum won't work well because it is too big and contains a lot of codes not suitable for the shoutbox.

 

So, a new bbcode helper will need to be written based on the original.

 

I'll keep you in mind and let you know if I find a solution or create a BBC helper.

 

good luck, :)

vujsa

Share this post


Link to post
Share on other sites

BBCode in the Shoutbox?

 

 

I'll keep you in mind and let you know if I find a solution or create a BBC helper.

 

good luck,  :)

vujsa

<{POST_SNAPBACK}>


thanks man! i hope u find a solution 'cause i'm very bad programmer :( so if u'll find a solution i'll be there for listen how i can use bbcode ;)

Share this post


Link to post
Share on other sites

Hey SpaceWaste,

 

I'll install the template on my test site so I can figure out exactly where to insert what code.

 

I guess you meant that you wanted the Shoutbox box just above the News box. I also assume that you want the Shoutbox to look like the News Box?

 

If you'll check My Test Forum you will see my progress. (Page Down Currently)

 

It may take a day or two. But I'll get you a working code.

 

Helios is the theme you are using, correct? Well, I'll get to work on it tomarrow. Got to go to bed soon. :P

 

vujsa

 

 

Notice from vujsa:

 

 

I think that I have what you need. Check out my website and let me know if that's what you wanted.

If so, I can either give you Mod Directions or Replacement Files.

The replacement files are ready to go but include modifications made for my own site. Additionally, you may just want the directions because it will show you how to do further modification to the Shoutbox templates.

 

Let me know.

 

vujsa

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.