Create other html pages & theme #1525
-
|
So, this project has a lot of potential. How can I create other html pages? In the base.html file I would like to add an href that leads to a folder always inside the main searxng folder, I tried to do it but it gives me the 404 how can I do it? Also, I want to create another theme I just need to know how do I import it into searxng. Thank you |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
|
Hi @Shad0wGlitch , The dynamic part you partially already found (the HTML): Its the templates folder here: https://github.com/searxng/searxng/tree/master/searx/templates/simple . We use a template engine called jinja2 so weird stuff inside those files that are not looking like HTML are going to be parsed and build into HTML on runtime. You can not just add files to that directory to create new pages. For that you would need to create a new route here: https://github.com/searxng/searxng/blob/master/searx/webapp.py We dont plan to add new themes in the form of complete new CSS/JS/HTML/IMG and so on, but rather forms of the simple theme. So at least the HTML will always stay the same FYI... |
Beta Was this translation helpful? Give feedback.
Hi @Shad0wGlitch ,
The site (so the HTML/CSS/JS) is made up of static content and the dynamic content. The static content (the JS/CSS/IMG and so on) can be found here: https://github.com/searxng/searxng/tree/master/searx/static/themes/simple/src and here is a quickstart on how to change it: https://docs.searxng.org/dev/quickstart.html
The dynamic part you partially already found (the HTML): Its the templates folder here: https://github.com/searxng/searxng/tree/master/searx/templates/simple . We use a template engine called jinja2 so weird stuff inside those files that are not looking like HTML are going to be parsed and build into HTML on runtime. You can not just add files to that direct…