News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Tagging System For Topics

Started by SMFHacks.com Team, December 19, 2006, 10:59:20 AM

Previous topic - Next topic

deep16


vbgamer45

Admin -> permissions -> modify the membergroup and find the permission for tags
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

deep16


vbgamer45

There should be. It adds a whole section in SMF permissions called SMF Tags
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

deep16


vbgamer45

You are not in the right area. Go to admin then find the permissions area for your entire forum. Under Permissions in the sidebar
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

deep16


vbgamer45

Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

iain sherriff

#1168
Hi.
I have this mod working fine  :)

I have a Tiny Portal side block that lists all tags. It picks up new tags and all details as I would expect. BUT the tags all link to the main tags page rather than to individual tags. Do I need to change the bit as indicated in Red ?

Thanks

global $scripturl, $smcFunc;

$result = $smcFunc['db_query']('', '
SELECT t.tag AS tag, l.id_tag, COUNT(l.id_tag) AS quantity
FROM {db_prefix}tags as t, {db_prefix}tags_log as l WHERE t.id_tag= l.id_tag
GROUP BY l.id_tag
ORDER BY t.tag LIMIT {int:limit}',
array('limit' => 100)
);

$tags = array();
$tags2 = array();

while ($row = $smcFunc['db_fetch_assoc']($result))
{
$tags[$row['tag']] = $row['quantity'];
$tags2[$row['tag']] = $row['id_tag'];
}

$smcFunc['db_free_result']($result);

if(count($tags2) > 0)
{
// change these font sizes if you will
$max_size = 100; // max font size in %
$min_size = 100; // min font size in %

// get the largest and smallest array values
$max_qty = max(array_values($tags));
$min_qty = min(array_values($tags));

// find the range of values
$spread = $max_qty - $min_qty;
if (0 == $spread)
{ // we don't want to divide by zero
$spread = 1;
}

// determine the font-size increment
// this is the increase per tag quantity (times used)
$step = ($max_size - $min_size)/($spread);

// loop through our tag array
$poptags = '';
$row_count = 1;
foreach ($tags as $key => $value)
{
$row_count++;
// calculate CSS font-size
// find the $value in excess of $min_qty
// multiply by the font-size increment ($size)
// and add the $min_size set above
$size = $min_size + (($value - $min_qty) * $step);
// uncomment if you want sizes in whole %:
// $size = ceil($size);

[color=red]// you'll need to put the link destination in place of the #
// (assuming your tag links to some sort of details page)[/color]
$poptags .= '<a href="' . $scripturl . '?action=tags;id=' . $tags2[$key] . '" style="font-size: '.$size.'%"';
// perhaps adjust this title attribute for the things that are tagged
$poptags .= ' title="'.$value.' things tagged with '.$key.'"';
$poptags .= '>'.$key.'</a> ';
               
if ($row_count > 1)
{
$poptags .= '<br />';
$row_count =1;
}
}
}
echo  $poptags;
   

(except of course it is not red in the code box!  )
SMF 2.0.12

420Connect.co.uk

Using this for a while now and really like the features it provides, although I do have 2 Ideas/Suggestions for this Mod..

1) Portal Block Integration
(small version of tag cloud)
can be added to portal block by adding {}show_tagcloud to a PHP block or something similar..

.. I'd personally use this in place of having the whole page for tags.

2) #hashtag feature
- any use of #wordhere gets added to the tag cloud

alike the hashtag feature used in popular social media sites..


Kind Regards
www.420Connect.co.uk ~ A Social Network For The #CannabisCommunity ~ Come say "High" ;)

vbgamer45

Check out this post on a portal block I have one built into ezportal but here is one for tinyportal that may work for others as well
http://www.smfhacks.com/index.php/topic,8601.msg37056.html#msg37056


hashtag would be harder would have to scan the post at creation time but it a nice idea to do one day.
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro


immigrants.ie

I have installed the mod ""Tagging System For Topics" - http://custom.simplemachines.org/mods/index.php?mod=579

But this feature seems to be only available for admin and not for ordinary members of the forum. They doesnt get the feature when they try to post a new thread1

Any way I could enable it for all members?

vbgamer45

You have to set permissions for all membergroups under admin -> permissions then modify the membergroups
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

immigrants.ie


vbgamer45

Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

gorbi

When can we expect support for #hashtags and trends? As twitter

vbgamer45

Never as it is not really what this mod is about.
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Bob Perry of Web Presence Consulting

Quote from: gorbi on April 28, 2015, 03:11:49 AM
When can we expect support for #hashtags and trends? As twitter

Yall, ya know I have not been monitoring support very closely, but I did quite a while back have an idea and really haven't followed thru very well with studying the results of what i did, but at one point i had my system set up with twitter "outgoing" and just manually used the hash tag feature for posts that got imported from my system "out" to twitter (and will do so again when the new 2.1 release of SMF is finally out there to use), but anyway, what i did was just use smftags with "manually" done Twitter hashtags?? Like i said, never studied what the results of that did or how effective it was, but what the hell, it won't hurt a damn thing to do it anyway right, a hash tag is just a hash tag, yes?

Best Regards,
Bob Perry



"The world is moving so fast these days that the man who says it can't be done is generally interrupted by someone doing it." Elbert Hubbard

lomaalta

Installed this mod fine, but when trying to modify an old topic, and add tags, the tags are not added (saved), what gives? 

Tags are saved, and everything seems to work fine on new topics...  I believe someone else has been having the same problem.

Advertisement: