Adding custom settings page #2022

Closed
opened 2025-11-02 04:21:29 -06:00 by GiteaMirror · 5 comments
Owner

Originally created by @ghost on GitHub (Jul 7, 2018).

  • Gitea version (or commit ref): 1.4.1
  • Git version: 2.17.0
  • Operating system: W10
  • Database (use [x]):
    • PostgreSQL
    • [X ] MySQL
    • MSSQL
    • SQLite
  • Can you reproduce the bug at https://try.gitea.io:
    • Yes (provide example URL)
    • No
    • [ X] Not relevant
  • Log gist:

Description

I customize the navbar.tmpl in 'custom\templates\user\settings' to include a link to my own, new settings tab page. But when I add the matching file with the same name in 'custom\public\user\settings' it does not work. Am I doing it wrong?
...

Screenshots

ISettings page with my new tab "Theme"
IError

Originally created by @ghost on GitHub (Jul 7, 2018). <!-- 1. Please speak English, this is the language all of us can speak and write. 2. Please ask questions or configuration/deploy problems on our Discord server (https://discord.gg/NsatcWJ) or forum (https://discourse.gitea.io). 3. Please take a moment to check that your issue doesn't already exist. 4. Please give all relevant information below for bug reports, because incomplete details will be handled as an invalid report. --> - Gitea version (or commit ref): 1.4.1 - Git version: 2.17.0 - Operating system: W10 - Database (use `[x]`): - [ ] PostgreSQL - [X ] MySQL - [ ] MSSQL - [ ] SQLite - Can you reproduce the bug at https://try.gitea.io: - [ ] Yes (provide example URL) - [ ] No - [ X] Not relevant - Log gist: ## Description I customize the navbar.tmpl in 'custom\templates\user\settings' to include a link to my own, new settings tab page. But when I add the matching file with the same name in 'custom\public\user\settings' it does not work. Am I doing it wrong? ... ## Screenshots ![ISettings page with my new tab "Theme"](https://i.imgur.com/GCLX4x4.png) ![IError](https://i.imgur.com/obEr58e.png) <!-- **If this issue involves the Web Interface, please include a screenshot** -->
GiteaMirror added the reviewed/wontfix label 2025-11-02 04:21:29 -06:00
Author
Owner

@daviian commented on GitHub (Jul 7, 2018):

@DavidGTorner That's simply not possible, since there is no route handler available for the new route. That's the reason why you get a 404 error code.
You can only customize existing templates and not add additional ones.

@daviian commented on GitHub (Jul 7, 2018): @DavidGTorner That's simply not possible, since there is no route handler available for the new route. That's the reason why you get a 404 error code. You can only customize existing templates and not add additional ones.
Author
Owner

@gsantner commented on GitHub (Jul 7, 2018):

would it be possible to get some "default unused" custom routes, where the admin could place some custom logic in a file while still being able to use normal release binaries? Like /custom/1/, /custom/2 ?

@gsantner commented on GitHub (Jul 7, 2018): would it be possible to get some "default unused" custom routes, where the admin could place some custom logic in a file while still being able to use normal release binaries? Like `/custom/1/`, `/custom/2` ?
Author
Owner

@daviian commented on GitHub (Jul 7, 2018):

This would be some kind of plugin system.
There's already an issue about that (https://github.com/go-gitea/gitea/issues/661), however since go doesn't support it natively on every platform there is currently no way to support that.

@daviian commented on GitHub (Jul 7, 2018): This would be some kind of plugin system. There's already an issue about that (https://github.com/go-gitea/gitea/issues/661), however since go doesn't support it natively on every platform there is currently no way to support that.
Author
Owner

@lafriks commented on GitHub (Jul 10, 2018):

As @daviian noted that this should be done as part of #661

@lafriks commented on GitHub (Jul 10, 2018): As @daviian noted that this should be done as part of #661
Author
Owner

@techknowlogick commented on GitHub (Jul 10, 2018):

Closed as this is marked as won't fix. Another slightly related ticket is #2012

@techknowlogick commented on GitHub (Jul 10, 2018): Closed as this is marked as won't fix. Another slightly related ticket is #2012
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#2022