Ohio Bronies - Forums

Peanut Bucker is best pony.

You are not logged in.

#1 2012-12-20 20:52:12

DarklyCute
Moderator
PB Trotter

test A

TEST A

Offline

#2 2012-12-20 20:52:31

DarklyCute
Moderator
PB Trotter

Re: test A

test b

Offline

#3 2012-12-20 22:42:22

edinpony
Life is an adventure!

Re: test A

hooray?

Offline

#4 2012-12-20 23:50:44

Drax
Vinyl Scratch

Re: test A

Oh we getting fancy now

Offline

#5 2012-12-21 01:26:12

surfwaxamerica
Four String

Re: test A

TeSt C


Ko7yR.gif

Offline

#6 2012-12-21 03:48:23

Arcane Flame
I LOVE THEM!!!
Arcane Trotter

Re: test A

Check one! Check Two! Sibilance! Sibilance!


BfG_SmButton.png

SG_Sig.png

"Magicam operare non est aliud quam maritare mundum."  ~Pico della Mirandola, Conclusiones Magicae

Offline

#7 2013-03-28 23:55:22

Mkanke
Peanut Buckering ALL the things!
Mkanke Trotter

Re: test A

Hi, [you]!

Just testing something I saw on another forum

Annnnnd it didnt work


yZVDO6p.gifD4LwTWC.gifulgdssl.gifLi4qREa.gifUyOaK2h.gif

Offline

#8 2013-04-02 07:50:48

Sarteck
Best Pony

Re: test A

Mkanke wrote:

Hi, [you]!

Just testing something I saw on another forum

Annnnnd it didnt work

I actually programmed that into my own forum, back when it was vBulletin 3.6, heh.

Nowadays, many forum platforms have a post cache, though, where the message is already completely (or at least mostly) parsed, so it's somewhat problematic to include dynamic content without the use of client-side coding (like JavaScript).

I actually think FluxBB (which is the engine this forum runs on) is one of the few who do NOT use cached posts--a very stupid idea for large forums, but doesn't matter much for a forum of this size.  ("Stupid" because not caching it would put a lot of strain on the webserver having to parse the BB Code for each and every post every time it's viewed, for larger forums, heh.)

Not quite sure where/how FluxBB parses the BB Code, nor what variables it uses to store "current user" data, but it wouldn't be an enourmous task to find out and make a plugin for a [you] BB Code, honestly.


I see you...
watching2.png

Offline

#9 2013-04-03 05:20:00

Sarteck
Best Pony

Re: test A

Heh, in fact, here ya go:

In includes/parser.php, add the following function, anywhere:

function do_you_tag($text)
{
  global $pun_user;
  $username = ($pun_user['is_guest']) ? 'Guest' : $pun_user['username'];
  $text = str_ireplace('[you]',$username,$text);
  return $text;
}

In the same file, look for the function do_bbcode().  (On an unmodified FluxBB isntallation, this will start at line 757.)

Inside taht function (pretty much anywhere before the "return" statement), put the following:

$text = do_you_tag($text);

Bam, insta [you code. :3

'Course, you could modify it however ya want...  Make it bolded, make it a link to the profile, etc.


I see you...
watching2.png

Offline

Quick reply

Write your message and submit

Board footer

Powdered by FluxBB