MyBB Community Forums

Full Version: [DEV] Send information about new posts and threads to Discord channel using WebHooks
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5 6
Yes, tested and works fine now Smile Thanks!

Is there any way (or will be) how to change output? For example "bold" text style for username, clickable username (linked to member account) etc?
For now, plugin purge all of the formatting elements. I will work with that, 'cause I know it's possible
[username](http://link.to.username/profile),
*italic*
**bold**
***bolditalic***
etc.
I've checked, and links like [name](link) doesn't work in info message (but it should works in rich section).
Good stuff Ryczy, +rep for you sir!
(2017-10-17, 07:42 PM)ryczypior Wrote: [ -> ]For now, plugin purge all of the formatting elements. I will work with that, 'cause I know it's possible
[username](http://link.to.username/profile),
*italic*
**bold**
***bolditalic***
etc.
I've checked, and links like [name](link) doesn't work in info message (but it should works in rich section).

Thanks, I use these *** stuff Smile
I've updated the code on github. Please note, that you have to uninstall and reinstall a plugin, so your current settings will be rewritten by default values. I've added some settings you might be interested Big Grin

(2017-10-18, 05:59 PM)rootsrat Wrote: [ -> ]Good stuff Ryczy, +rep for you sir!

Thank you!
Thank you! Great! I added you 2x rep Big Grin

I would like to see new setting how many characters from the message are shown - now you can set only 100 or more (hardcoded).

EDIT: Avatar is not shown in Discord (when the rich setting is used).
@Eldenroot, Thank you very much for reps Big Grin It's very motivating.

I've just added new issues on github plugin's page. I'll work with that tomorrow evening.
Thanks again for your contribution Smile Let's make this plugin useful Big Grin
Happy to help Smile Great plugin, I am looking for your next release and new features Smile
Great plugin, using it for my community's forums to get new staff applications posted in the staff chats on Discord.

Ran into one problem but was able to fix it.
'url' => $discordWebhook->getFullUrl('/showthread.php?tid=' . $entry->post_insert_data['tid']),
This line of code wasn't picking up the fact that we have our forums in a "[site]/forums/" folder, but all I had to do was change it to "/forums/showthread.php?tid=" and yeah. Easy fix. 

The main problem I have now is that this will only work for one server's staff applications. If I add another server's staff applications to be posted by the bot, they'd get sent to one server's staff chat, and not the other since I can't have multiple webhooks, and even if I could, I wouldn't be able to specify that this webhook URL should send posts from this forum, and the other webhook URL should send posts from the other forum. 

However, if I could just duplicate this plugin to be able to have multiple installed, that would fix my problem (at least I think). Do you know if there's any way to do this?
Hi! I'm glad it's useful. I have an idea how to use the plugin many times, but I can't check this until Thursday.
The idea is to add a suffix for plugin directory, and this suffix will be added automatically to plugin functions names and to database entries, so it shouldn't affect other instances of the plugin.
Pages: 1 2 3 4 5 6