I'm trying to add a link to my staff bar, that has a badge with a counter on it. I've created an add-on and have modified the templates, but I'm unsure of where I can write the PHP/SQL code to retrieve the count I want to display in the badge. I know I can extend controllers, but I'm not sure...
Might be some performance benefits since it implements directly with php-http. Also means you can shrink the dependency list since no need for an adapter anymore. (y)
Also I know this isn't "supported" but when extending XF into custom applications (e.g Laravel) and requiring XF.php, since...
Hey @robdog ,
Thanks for the detailed reply. My current way of doing it has been to use something similar to this (https://github.com/swede2k/xf2bridge) but I wrote most of it myself, only found this one AFTER I'd already made my own. 🤦♂️
Also quickly to clarify my app and the forum will be...
I've been working on a project the past few months where I've wanted to integrate XenForo with an external app, a Laravel app to be specific. I'm not trying to do anything too complicated, just basically have it so that if a user is logged into the forum, then they can access the app. If they...
Actually just discovered that it seems to be removing usergroups that is then blocking adding usergroups to the user again.
Basically the way I was testing was;
Catch Webhook
Add usergroup
Remove usergroup
catch webhook
(doesnt add forumgroup anymore for some duration of time)
So I think...
In regards to $groups->toArray(), that's actually just an array of group ids. I just put them inside of a Laravel collection so that I can use their nifty helper functions and then at the end I called toArray() to make sure it was just an array and none of the other collection stuff.
While...
That is the one I used and updated.
https://gist.github.com/marbuser/c3e4d16609a579bb0808f333b691cd5e
Really the only file that changed the most was this one. https://gist.github.com/marbuser/c3e4d16609a579bb0808f333b691cd5e#file-xenforo-php
Like I said, for everything else works fine for me...
I'm using a simplified and updated version of this that I did myself; https://github.com/UnderRatedBrilliance/XenforoBridge
By "updated" I mean for the latest version of Laravel and XF. I didn't add any new features, so it's 99.9% same as that one.
For my specific application, the bridge was the best option. The things I can't do with the API are restrictions on XF's end, not mine.
I don't want to sound like a jerk, but if you aren't going to help please refrain from posting on here. Even IF XF fixed the restrictions I mentioned above...
Because there are other parts of the forum I need to access in my application that AREN'T available in the API.
Also at this point since I've already included XF.php etc... into my application, it seems a bit foolish to then rely on sending web requests to the forum to change just usergroups and...
I'm in the process of building an app with Laravel that works in-hand with XenForo.
The issue is that in my use-case, I have a webhook that communicates with my server and I create a Job and run it with a worker. When that webhook is processed, I want it to give the context user a certain...
Back in XF 1, I remember there was a plugin you could install that allowed you to edit the XF templates and styles via WebDav. However, I've tried to get something similar working with XF 2 but have been unsuccessful.
Can anyone provide any advice on how I could get this working so I can work...