C07025 - Colored Tripcodes

identicon
C07025 - Colored Tripcodes
hmmy Monday 28th August 2017, 01:08:06

Hi All, 

This will allow trips to be colored by the trip combination. Feel free to tweak, edit or create plugin -- I am not familiar with programming or php.  

Open file /lib/HTMLFORM.lib.php
Replace public static function trip($name, $id) starting on line 55 with:

public static function trip($name, $id)
{
global $config;
if ($name === '')
{
return '<span style="color:#'.substr($id, -6).'">'.substr($id, -6).'</span>';
}
else
{
$parts = explode('#', $name, 2);
$salt = md5($config['salt'].$parts[1]);
return  $parts[0].(isset($parts[1])? '<span style="color:#'.substr(md5($parts[1]), -6).';">' .substr(md5($parts[1]), -6)  : '<span>');
return '</span>';
}
}


Picture of it in action on heavily modified goobbs script.
image
Last modified: Sunday 24th September 2017, 18:45:29

Replies 4
Fred_4346f29d
Fred  Monday 28th August 2017, 08:05:00

Hi hmmy,
Did you download the latest version of Flatboard?
Because you can now denominate a user 'verified' is therefore modify the complete aspect.
Furthermore we already uses a class for guests, moderators and administrator.
Your idea is not bad, but there may be similarities colors, hardly distinguishable
Last modified: Monday 28th August 2017, 08:07:14

Before ask a question, read the documentation.
Sorry I'm busy right now
Please like in alternativeto.net 👍🏻
╰☆╮Flatboard╰☆╮ is a open source and community contributions are essential to project success!

Prétendre que votre droit à une sphère privée n'est pas important parce que vous n'avez rien à cacher n'est rien d'autre que dire que la liberté d'expression n'est pas essentielle car vous n'avez rien à dire.
-- E. Snowden

identicon
hmmy  Monday 28th August 2017, 08:54:28

i use this in a blog posting projects (goo, not flatboard).   I post as anon and have it set to admin only posting.  

Always thoufht colores trips trips were neat so decided to. Share.  

Fred_4346f29d
Fred  Monday 28th August 2017, 13:39:34

Ok but why do not you use Flatboard, goo is obsolete...
Thanks for sharing, but the modification of the core remains risky if you update your forum.

Before ask a question, read the documentation.
Sorry I'm busy right now
Please like in alternativeto.net 👍🏻
╰☆╮Flatboard╰☆╮ is a open source and community contributions are essential to project success!

Prétendre que votre droit à une sphère privée n'est pas important parce que vous n'avez rien à cacher n'est rien d'autre que dire que la liberté d'expression n'est pas essentielle car vous n'avez rien à dire.
-- E. Snowden

identicon
hmmy 🐝  Monday 28th August 2017, 16:08:55

Main reason would be ratings. I post photos of projects and have commented out replies so I rely on rating for feedback. I thought about changing the report feature to a meathod of feedback, but still perfer rating.

I'm a huge fan of FB though... Been around before v0.7.1
Last modified: Monday 28th August 2017, 20:27:44

Suggested Topics
identicon
317 5
Fred_3c4613
Fred#3c4613 started plugin Google Tools
Resources
670 10
Want to read more? Browse all categories or view latest topics.