• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Custom Development Guide?

#1
Hi everyone,

I know that there are random tutorials available in the Development Help forums, but I don't know which are out of date, contain best practices, etc. I'd like to develop in a way that ensures things I make don't break when XenForo is updated.

Is there any kind of authoritative guide about leveraging XenForo as a platform, adding custom pages and functionality, tying it back it in with Xenforo users/posts/functionality/etc.?

Thank you!
 

sbj

Well-known member
#2
Honestly, all of those tuts are somehow out of date, but at the same time they still work and teach you the best practices.

I recommend these 3 tuts to understand the groundwork:
1) https://xenforo.com/community/threads/creating-an-addon.5416/
2) https://xenforo.com/community/resources/understanding-the-xenforo-class-proxy-system.2080/
3) https://xenforo.com/community/resources/how-to-read-and-write-into-the-database-with-a-page.328/

And 4th thing to know is that hooks are deprecated, so you should use the TMS (Template Modification System) when you are working on the View part of the MVC structure.
 

James

Well-known member
#4
I'd like to develop in a way that ensures things I make don't break when XenForo is updated.
I dont wish to deter you from developing for XenForo 1.x but it's prudent to know that XenForo 2.0 is nearing release and will almost definitely break anything you produce for the 1.x series.

That being said we don't expect everyone to update on day 1 so I'm sure your addons will have use either personally or in the wider community.
 

Robust

Well-known member
#5
I dont wish to deter you from developing for XenForo 1.x but it's prudent to know that XenForo 2.0 is nearing release and will almost definitely break anything you produce for the 1.x series.

That being said we don't expect everyone to update on day 1 so I'm sure your addons will have use either personally or in the wider community.
For a gold 2.0 release it'll probably be 2017, if the first beta is by the end of fall 2016. I'd add a few months onto that for administrators to familiarise themselves as well as add-ons developers to complete updates to XF2. So I'd say development for XF 1.x is still strong.
 

Steve F

Well-known member
#6
For a gold 2.0 release it'll probably be 2017, if the first beta is by the end of fall 2016. I'd add a few months onto that for administrators to familiarise themselves as well as add-ons developers to complete updates to XF2. So I'd say development for XF 1.x is still strong.
I agree - I see at least 6-8 months before a stable release of XF 2.0 (my opinion only). They've mentioned a demo for everyone to log into and try this quarter (Q4), not a release of XF 2.0. So yeah developing for XF 1.x is still viable.
 

James

Well-known member
#7
For a gold 2.0 release it'll probably be 2017, if the first beta is by the end of fall 2016. I'd add a few months onto that for administrators to familiarise themselves as well as add-ons developers to complete updates to XF2. So I'd say development for XF 1.x is still strong.
Absolutely is still strong I wouldn't anticipate a gold release until late q1 early q2 2017 in all honesty and even then the bigger forums probably won't update until 2018 if at all.

Just letting him know there is a new version coming out with inevitably different syntax and coding practices that he will need to re-familiarise with and then potentially rewrite. I'm not discouraging 1.x development it is important we keep producing for this version because it's by no means end of life!
 
#8
Thanks, everyone, I appreciate the advice. Given the expected timeline, I would rather see if I can get something going and then migrate rather than waiting 8 months or however long to begin.

I'm going to start with the resources sbj suggested. If anyone has any additional thoughts on good practices or resources, please let me know!

I want to create something of a matchmaking site for a particular niche. I was thinking of going with the Symfony framework, but the forum and private messaging component would be such a big part of it that I thought it might be best to try to develop custom pages/functionality in/for Xen Foro rather than try to bridge a Symfony application with Xen Foro. What do you think?
 

James

Well-known member
#9
Those resources are fine. Development forums are also a big help.

Regarding the method I think you'd be better trying to utilise the functionality xenforo has than trying to use another framework. What is your reasoning for using Symfony? Is that a framework you're already familiar with?
 
#10
Exactly, Symfony is just the framework I'm already most familiar with.

The application I have in mind really comes down to having n additional profile fields of various types and a way to allow searching profiles by various combinations of criteria, so I'm hoping it will be straightforward enough to do that with Xen Foro.
 

James

Well-known member
#11
Additional custom user fields you can create via the XenForo interface itself and there's already an addon that allows you to search by those custom fields. You can either use that as-is or use it as a learning tool to create your own. A quick search should reveal one or two I'm sure they exist!
 
#12
Thanks, James, I'll look into it! Hopefully multi select is among the available user field types. If not, hopefully it won't be too difficult to add. Appreciate the guidance!