Off-Topic BBC Tag

Started by Nick Whetstone, October 19, 2008, 04:23:34 AM

Previous topic - Next topic

Nick Whetstone



Off-Topic BBC Tag v1.1.2
Orgininally by Nas, now developed by Ha2
(For SMF 1.1.x and SMF 2.0 RC1+)



Introduction
This adds a new BBC tag, which allow users to use [off-topic][/off-topic], to mark parts of their posts as off-topic.

Tested
Tested on fresh installations of 1.1.7 and 2.0 Beta 4.

Languages
o English
o Swedish
I welcome new translation. Post them in the mods topic.

Supported themes
o Default
If you want support for other themes, write in the mods topic.
Your theme will only need to be edited if it uses a custom Post.template.php.

Support
If you need support, use the modification thread.


Changelog
1.1 22 February 2010
o Updated for 2.0 RC2
1.1 17 July 2009
o Edited package-infox.ml to make installation work on SMF 2.0 RC1.2.
1.1.1.1 23rd May
o Edited package-infox.ml to make installation work on SMF 2.0 RC1-1.
1.1.1 17th Mars
o Edited package-infox.ml to make installation work on SMF 2.0 RC1.
1.1 21st January
o Added support for SMF 2.0 Beta 4. (Charter members: It will work on RC1, just update package-info.xml)
1.0 11th October 2008
o Mod was submitted to the SMF Mod Site.
The artist formerly known as (Ha)²

Former Support Specialist

Please do not solicit support via PM. Here's why!

Costa

Thanks for the mod

but... in brazilian...

// Start Off-Topic BBC by Nascar
$txt['off-topic'] = 'Off-Topic:';
$txt['off-topic_desc'] = 'Tag BBC Off-Topic';
// End Off-Topic BBC by Nascar


hehe, congrats for the mod

Farewell
Hugo "Costa" Fernandes - PT SMF
Todas as MP's a pedir ajuda são sujeitas a radioactividade, microondas, queimadas e atiradas borda fora.

"At least someone appreciates the fact that I am doing and not thinking..."
"Laziness is counter-revolutionary."

Marcus Forsberg

Thank's for the translation, Costa!
It will be added to the package soon.

Costa

the funny thing: Don't change to much in the translation ,huahua

Congrats one more time
Hugo "Costa" Fernandes - PT SMF
Todas as MP's a pedir ajuda são sujeitas a radioactividade, microondas, queimadas e atiradas borda fora.

"At least someone appreciates the fact that I am doing and not thinking..."
"Laziness is counter-revolutionary."

The Saviour

#4
This would be even more nice, if you can get it to display just like the Modbreak tag...

Oh...one more thing...

You have to refresh the page after using this BBCode in order for the background highlight to work.

Just a heads up...

Marcus Forsberg

Thanks for the comment.

You should olny have to refresh it the first time you use the BBC, just to notify the broswer about the CSS update.

The Saviour


Burke ♞ Knight

Any chance of a SMF 2.0 Beta 4 version any time soon? :)

Marcus Forsberg

Probably.
I just have to get back in business whit my new computer :)

Burke ♞ Knight

New computer!!!!

You lucky devil!
I'm stuck with a computer that has an attitude. I think it's trying to shop for a less busy owner...LOL

villasg

Thanks .
i think need a little better icon like

Marcus Forsberg

I agree. I just made a simple icon fast.
Did you create that off-smiley? If so, may I use it for the mod? (Creds to you, ofcourse)

Burke ♞ Knight

Nascar, I believe that is a free smiley available just about all over the net.
I've seen it on a lot of forums, including a web host's support forum I'm staff at. :)

The Saviour


The Saviour


Burke ♞ Knight

Personally, I love the first one, Saviour. :)

The Saviour

Thanks...but I can't take credit for the images...only the text...and I believe the font is owned by Microsoft.

Emoticons are courtesy of vbimageworks.com.

Anyone looking for some f-a-n-t-a-s-t-i-c forum images...should give them a look.

Tell shelley, Saviour sent ya!

villasg

Thanks but problem in install with pakage manager
The name is  Off-Topic BBC Tag 1.0.zip
and need to make like some Off_Topic_BBC_Tag_1.0.zip

Burke ♞ Knight

What version of SMF are you running?

villasg


Burke ♞ Knight

Then the latest file on the downloads page should work.
I installed it without any problems.

What error are you getting?

villasg

Dont have erors .
Simply dont make anything ( dont install anything )
After change the name all ok
I think the problem is from settings on my server
Run in safe mode .
And maybe have some restrictions

Burke ♞ Knight

Yes, may very well be a server issue, if not allow spaces in file names.

Smoky "Rider" Blue

hey Nascar, update for either the beta or rc?? would be nice ;)
**Take the time to remember friendships and family.. Sometimes it's all we have, and missed very much**

Marcus Forsberg


Smoky "Rider" Blue

lol.. you are a trip!!

thanks!! :P
**Take the time to remember friendships and family.. Sometimes it's all we have, and missed very much**

Marcus Forsberg

Update
Now supporting SMF 2.0 Beta 4.

Charter members
This should work on SMF 2.0 RC1, just open package-info.xml and find:

<install for="2.0 Beta 4">

Change it to:

<install for="2.0 RC1"> (I guess)

Then, find

<uninstall for="2.0 Beta 4">

Change it to:

<uninstall for="2.0 RC1"> (I guess)

Smoky "Rider" Blue

lmao!! thanks very much!!  :)
**Take the time to remember friendships and family.. Sometimes it's all we have, and missed very much**

Chit-Chat ChatterBox Boss

#28
Thanks Works great! ..... Only thing I might want to change the BBC Tag Icon at some point.
Chit-Chat ChatterBox

Our site is open to everyone. It is a resource for anyone and everyone to talk about anything and everything you could possibly think of. It's a great place to come and talk, ask questions, or just simply hang out. We offer many great features. All we ask is that you follow by the site rules. Hope to see you around!
www.chitchatchatterbox.com
Remember in the "Referral" box to put "Caleb" while registering.

SteveW

I've installed and the tag icon when you hover over it displays "Insert Quote" instead of I'm presuming "Off topic" - Where would I fix this :) thanks
Watch the skies!!

Marcus Forsberg

Quote from: Chit-Chat ChatterBox Boss on May 15, 2009, 11:53:45 PM
Thanks Works great! ..... Only thing I might want to change the BBC Tag Icon at some point.

./Themes/defailt/images/bbc

Quote from: SteveW on May 25, 2009, 03:25:56 AM
I've installed and the tag icon when you hover over it displays "Insert Quote" instead of I'm presuming "Off topic" - Where would I fix this :) thanks

Hmm.. Can't tell without a look at Subs.php, Post.template.php (If you are on 1.1.x) and Modifcations.english.php.

SteveW

I'm using 2.0rc1

This is in Modifcations.english.php

// Post History END// Start Off-Topic BBC by Nascar
$txt['off-topic'] = 'Off-Topic:';
$txt['off-topic_desc'] = 'Off-Topic BBC Tag';
// End Off-Topic BBC by Nascar


This is the section of Subs.php it has altered:

array(
'tag' => 'quote',
'before' => '<div class="quoteheader">' . $txt['quote'] . '</div><blockquote>',
'after' => '</blockquote>',
'block_level' => true,
),
array(
'tag' => 'quote',
'parameters' => array(
'author' => array('match' => '(.{1,192}?)', 'quoted' => true),
),
'before' => '<div class="quoteheader">' . $txt['quote_from'] . ': {author}</div><blockquote>',
'after' => '</blockquote>',
'block_level' => true,
),
array(
'tag' => 'quote',
'type' => 'unparsed_equals',
'before' => '<div class="quoteheader">' . $txt['quote_from'] . ': $1</div><blockquote>',
'after' => '</blockquote>',
'quoted' => 'optional',
'block_level' => true,
),
array(
'tag' => 'quote',
'parameters' => array(
'author' => array('match' => '([^<>]{1,192}?)'),
'link' => array('match' => '(?:board=\d+;)?((?:topic|threadid)=[\dmsg#\./]{1,40}(?:;start=[\dmsg#\./]{1,40})?|action=profile;u=\d+)'),
'date' => array('match' => '(\d+)', 'validate' => 'timeformat'),
),
'before' => '<div class="quoteheader"><a href="' . $scripturl . '?{link}">' . $txt['quote_from'] . ': {author} ' . $txt['search_on'] . ' {date}</a></div><blockquote>',
'after' => '</blockquote>',
'block_level' => true,
),
array(
'tag' => 'quote',
'parameters' => array(
'author' => array('match' => '(.{1,192}?)'),
),
'before' => '<div class="quoteheader">' . $txt['quote_from'] . ': {author}</div><blockquote>',
'after' => '</blockquote>',
'block_level' => true,
),
        array(
'tag' => 'off-topic',
'before' => '<div class="off-topicheader">' . $txt['off-topic'] . '</div><div class="off-topic">',
'after' => '</div>',
'block_level' => true,
),
array(
'tag' => 'off-topic',
'type' => 'parsed_equals',
'before' => '<div class="off-topicheader">' . $txt['off-topic'] . ' $1</div><div class="off-topic">',
'after' => '</div>',
'quoted' => 'optional',
'block_level' => true,
),

array(
'tag' => 'right',
'before' => '<div style="text-align: right;">',
'after' => '</div>',
'block_level' => true,
),


Thanks :)
Watch the skies!!

PlutoDelic

any help for the Bright Forest theme (smf 2.0 rc1-1)

Electric Hermit

Quote from: SteveW on May 25, 2009, 10:11:33 AM
I'm using 2.0rc1

This is in Modifcations.english.php

// Post History END// Start Off-Topic BBC by Nascar
$txt['off-topic'] = 'Off-Topic:';
$txt['off-topic_desc'] = 'Off-Topic BBC Tag';
// End Off-Topic BBC by Nascar


Thanks :)

./Themes/default/languages/Modifications.english.php

Code (Find) Select
// Post History END// Start Off-Topic BBC by Nascar
$txt['off-topic'] = 'Off-Topic:';
$txt['off-topic_desc'] = 'Off-Topic BBC Tag';
// End Off-Topic BBC by Nascar


Code (Replace With) Select
// Post History END// Start Off-Topic BBC by Nascar
$txt['off-topic'] = 'Off-Topic:';
$txt['off-topic_alt'] = 'Off-Topic';
$txt['off-topic_desc'] = 'Off-Topic BBC Tag';
// End Off-Topic BBC by Nascar


./Sources/Subs-Editor.php


Code (Find) Select
'off-topic' => array('code' => 'off-topic', 'before' => '[off-topic]', 'after' => '[/off-topic]', 'description' => $txt['bbc_quote']),

Code (Replace With) Select
'off-topic' => array('code' => 'off-topic', 'before' => '[off-topic]', 'after' => '[/off-topic]', 'description' => $txt['off-topic_alt']),
And hermits are contented with their cells;
And students with their pensive citadels ...

William Wordsworth

hypercube

Hi can someone help me? I first had trouble installing this mod but finally it worked. But now I f**ked some things up and quotes are showing like this now:

Quote from: Me link=topic=411.msg14296#msg14296 date=1245672069

So it's not a clickable link anymore. I think it's something in subs.php.. Anybody know what could've happened?

mgburks

Using version 1.1.10 this package installs fine, and I see the BBC code, it inserts the code into the post but when the post is submitted there is no change in the post. It just looks normal.  I'm using the default theme BTW.

mforum

smf 1.1.10 - default theme

i see off-topic: , but no colored box ....  ::)

Marcus Forsberg

Try a hard refresh. Hit F5.

mforum

 :-[ yes , it works now
thank you  :)

Marcus Forsberg


Relemar

its just the same as typing

Off-topic, isnt it? :S

@ngel

#41
French Translation :

$txt['off-topic'] = 'Message Hors-Sujet :';
$txt['off-topic_desc'] = 'BBC Tag Message Hors-Sujet';


and a correction for 2.0 RC1.2 :


<add><![CDATA[ 'off-topic' => array('code' => 'off-topic', 'before' => '[off-topic]', 'after' => '[/off-topic]', 'description' => $txt['bbc_quote']),]]></add>



must be ('bbc_quote' replaced by 'off-topic_desc')


<add><![CDATA[ 'off-topic' => array('code' => 'off-topic', 'before' => '[off-topic]', 'after' => '[/off-topic]', 'description' => $txt['off-topic_desc']),]]></add>



Regards,

grafitus

Thanks Nas. And Turkish Translate:

// Start Off-Topic BBC by Nas
$txt['off-topic'] = 'Konu Dışı:';
$txt['off-topic_desc'] = 'Konu Dışı';
// End Off-Topic BBC by Nas

TurtleKicker


Nick Whetstone

The artist formerly known as (Ha)²

Former Support Specialist

Please do not solicit support via PM. Here's why!

Nick Whetstone

Thanks to Nas for letting me take this over.

Updated for 2.0 RC2!
The artist formerly known as (Ha)²

Former Support Specialist

Please do not solicit support via PM. Here's why!

Eclipse16V

Nice Mod

Please update it for SMF 2.0RC3  ;)

Thanks
I worked with:
SMF 2 in German

Shop:
SID Giessen

PlutoDelic

Yes please, this mod caused me headaches cause it changed my normal quotes somehow, please, a proper version for RC3.

JD82

I upgraded the plugin to version RC3 with curve theme, Fixed a bug in the bbcode button and tweaked the css:


The bug was to use the string of the quote button ($txt['bbc_quote']) instead of the button off topic ($txt['off-topic_desc']).
old
array(
'code' => 'off-topic',
'image' => 'off-topic',
'before' => '[off-topic]',
'after' => '[/off-topic]',
'description' => $txt['bbc_quote']
),

new
array(
'code' => 'off-topic',
'image' => 'off-topic',
'before' => '[off-topic]',
'after' => '[/off-topic]',
'description' => $txt['off-topic_desc']


All credit goes to the plugin author.

chinaren

Thanks for that RC3 upgrade!  Does the job!  :)
The Opus Path - The Next Generation of the Written Word

vigoss

Quote from: JD82 on April 19, 2010, 03:01:32 PM
I upgraded the plugin to version RC3 with curve theme, Fixed a bug in the bbcode button and tweaked the css:


The bug was to use the string of the quote button ($txt['bbc_quote']) instead of the button off topic ($txt['off-topic_desc']).
old
array(
'code' => 'off-topic',
'image' => 'off-topic',
'before' => '[off-topic]',
'after' => '[/off-topic]',
'description' => $txt['bbc_quote']
),

new
array(
'code' => 'off-topic',
'image' => 'off-topic',
'before' => '[off-topic]',
'after' => '[/off-topic]',
'description' => $txt['off-topic_desc']


All credit goes to the plugin author.
This version doesnt want to setup on smf rc5 =(

Gryzor


Draffi

update for SMF 2.0.4, plz...

TheListener

Quote from: Draffi on June 28, 2013, 06:49:19 PM
update for SMF 2.0.4, plz...

Have a read of the Mod Emulate link in my signature.

The Mod has not been updated since 2.0 RC2

Strannik64


shadav

Quote from: Strannik64 on February 15, 2022, 12:01:34 AMPlease update to 2.1.1
seeing as this mod was last updated 2010
the last post in the thread was 2013

you're better off using a different mod that has been updated (and most likely will be updated to 2.1.1 somewhat soon, it's been updated to work with 2.1 rc2 so it may work with 2.1.1 already)
https://custom.simplemachines.org/index.php?mod=4166

Advertisement: