Custom Paths

Technical Support
  • Hi,

    I would like to know if there is a feature/plugin for custom paths with NodeBB. I would like to reroute /category/1/CATEGORY_NAME to /CATEGORY_NAME. Is this possible?

    Thanks for your help!

  • Not that I've seen. I think you can technically do this in your own plugin.

    You could fetch all of the category names at load time, then define the routes, using the same category controllers used in NodeBB core. It might be too complex if you've never written a plugin before however.

    I would then suggest adding a rewrite rule to your server config, so that requests to /category/1/CATEGORY_NAME are changed to /CATEGORY_NAME before they even reach NodeBB.

  • Thanks, I'll work on it and report here.

Suggested Topics