XF 1.0 Creating a Simple Modification

Kier

XenForo developer
Staff member
By exposing code events and allowing listeners to attach to them, XenForo makes it easy to alter its default functionality with simple callback classes.

The API for doing this is well-defined and documented, so modifications made in this way stand a very good chance of remaining backward compatible through future version updates.

This video shows me creating a simple add-on that allows us to see how an existing thread would look with over a thousand pages.


As usual, it's a large, HD video, so I suggest you view it at its original size by clicking the full-screen gadget in the bottom-right corner of the video.

Edit: If for whatever reason you can't view the video here, view it directly on Vimeo (but please leave comments here, not there).
 

Tigratrus

Well-known member
Have to go do some lawn type work... But on first brush it looked like a great improvement on prior systems! :)
 

GameR

Active member
Nice try.

The Api i not really like, about static call. But the administration is really nice! God job.
 

AmericanForum.com

Well-known member
" The API for doing this is well-defined and documented, so modifications made in this way stand a very good chance of remaining backward compatible through future version updates."

Nice ... the past, present and future is planned in the same code. :)
 

Cezz

Well-known member
Very nice plugin system I like it...

As for the fon't size decreasing on the navigation so more numbers will fit this is worrying, when we get to forums that have 20k or ever 100k pages of threads how small are those numbers going to look?
 

Been Told

Well-known member
Really impressed. I could actually follow this tutorial and I'm having a strong suspicion, that I will actually be able to create XenForo addons myself! That is what I've really really been hoping for.
The promise of good documentation is also something that really makes me feel better about my chances of writing addons myself.

Thanks so much for this :)
 

Mert

Well-known member
It looks great and i am so excited to get my hands on the code to start modifying things.
 

Been Told

Well-known member
As for the fon't size decreasing on the navigation so more numbers will fit this is worrying, when we get to forums that have 20k or ever 100k pages of threads how small are those numbers going to look?
I'm 99% certain that all it takes is one line of CSS to change that behavior. I highly doubt it's hard-coded.
 

Kier

XenForo developer
Staff member
Very nice plugin system I like it...

As for the fon't size decreasing on the navigation so more numbers will fit this is worrying, when we get to forums that have 20k or ever 100k pages of threads how small are those numbers going to look?
Optimise for the common case. Threads with over 9,999 pages? I don't think I've ever seen one.
 

SneakyDave

Well-known member
The API for doing this is well-defined and documented, so modifications made in this way stand a very good chance of remaining backward compatible through future version updates.
that itself is important, but even if there are changes to the underlying API, it appears that required changes to plug-ins shouldn't be too difficult, unless what you describe as "events" are heavily modified.
 

Brogan

XenForo moderator
Staff member
Very nice plugin system I like it...

As for the fon't size decreasing on the navigation so more numbers will fit this is worrying, when we get to forums that have 20k or ever 100k pages of threads how small are those numbers going to look?
You could always increase the posts per page (ppp) to 30, that would instantly reduce the number of pages by 30%.

So a 20,000 post thread with 20 ppp would have 1,000 pages.
On a 30 ppp thread, that would be just 667 pages.
 

Dean

Well-known member
Really impressed. I could actually follow this tutorial and I'm having a strong suspicion, that I will actually be able to create XenForo addons myself! That is what I've really really been hoping for.
I have the exact same thoughts.

At some point we need a young childs voice in some of these to infer how simple things can be. : )
 

Jeremy

Well-known member
I cannot wait to go back to my dorm and watch this. Looking forward to programming for XenForo.
 

Cezz

Well-known member
Optimise for the common case. Threads with over 9,999 pages? I don't think I've ever seen one.
You won't see a thread with over 9,999 pages but you may see a forum with over 9,999 pages... 20 threads per page 10,000 pages would only be 200,000 threads quite possible.
 

Cezz

Well-known member
You could always increase the posts per page (ppp) to 30, that would instantly reduce the number of pages by 30%.

So a 20,000 post thread with 20 ppp would have 1,000 pages.
On a 30 ppp thread, that would be just 667 pages.
Again I am talking about threads in a forum instead of posts in a thread as the same navigation setup is used there... if you get above 9,999 pages then you would be going into the 10k page mark and that font may become very small then.
 
Top