SimplePortal

Customization => Custom Coding => Topic started by: goten22 on August 30, 2015, 01:35:27 PM

Title: highlight topics on homepage
Post by: goten22 on August 30, 2015, 01:35:27 PM
I'm looking for a way to display, on homepage, topics which are highlighted by moderators. Moderator will be able to highlight every topic. I'm wondering how to do this. I don't know if it's possible to add some kind of mark/state other than "sticked" and then check which topics have this state and display them?

I'll be grateful for any help.
Title: Re: highlight topics on homepage
Post by: ♦ Ninja ZX-10RR ♦ on August 30, 2015, 01:51:38 PM
This would require a very major overhaul in the code (new queries, db edits, template edits, language edits, buttons, add buttons to template, new permissions etc). I don't see it happening to be honest. You could have a look at the Global topic mod by margarett though, I'm in a hurry and can't provide a link atm.

Regards
Title: Re: highlight topics on homepage
Post by: goten22 on August 30, 2015, 02:00:01 PM
Hm, maybe some harsh way. I mean, if it's not built-in feature I'm forced to use dirty tricks. Maybe it could be done by searching specific characters in topics name. For example if topic name is "[highlighted] topic name" then show it.

I'll check this mod, thanks.

Or I've got another idea. Add a button that will copy thread name and first post content and add link to itself and move it to another, non visible for users, category. Then script on homepage will get first link that was added to first post and leads to real topic. It's really confusing and messy, but... no other idea.

Next clue - after installing "solved" mod $context['topic_solved'] displays "1" or "0" so there is added some variable. I could use it somehow.
Title: Re: highlight topics on homepage
Post by: ♦ Ninja ZX-10RR ♦ on August 31, 2015, 01:33:43 AM
Somehow, but it would kill the chance to use that mod for its real purpose.
Title: Re: highlight topics on homepage
Post by: goten22 on September 01, 2015, 04:25:02 AM
I found so called "articles" in simpleportal. But is there any syntax that I could paste to simpleportal block and edit a bit? The default one is a bit poor. No comments no image thumbnail etc.

(http://i.imgur.com/3qEZwPg.jpg)

To sum all this: you can use articles build in simpleportal - here about styling it: http://simpleportal.net/index.php?board=56.0
SimplePortal 2.3.8 © 2008-2024, SimplePortal