Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unique AppPrefs for different html files #2672

Open
tyctor opened this issue Apr 23, 2024 · 4 comments
Open

Unique AppPrefs for different html files #2672

tyctor opened this issue Apr 23, 2024 · 4 comments

Comments

@tyctor
Copy link

tyctor commented Apr 23, 2024

Hi

I have two html reports, one with all history stats.html and one for today today-stats.html (generated with --keep-last=1)
I want to have different panels displayed on each report byt default, but settings in localStorage use same key name AppPrefs, so i t is common for both reports
Should be possible to add some prefix for localStorage to have AppPrefs separate for each report? but probable there is some more behind, and only separated AppPrefs wont be enough.

@0bi-w6n-K3nobi
Copy link
Contributor

Hi @tyctor

What you means with term AppPrefs ? Is it Preferences from GOAccess run?
Or GOAccess for Panels and layout preferences?

Whatever, you can do this from specify different a goaccess.conf for each case.
I.E... you can have two CONFs, one for stat.html and other for today-stats.html.
For more detail you can read about this in manual page here at File Options section,
specifically at --config-file= option.

So, I hope be clean. Feel free for more asks.

@tyctor
Copy link
Author

tyctor commented Sep 23, 2024

Hi @0bi-w6n-K3nobi
I mean localStorage in browser use same key AppPrefs, so if I change settings on stats.html it also change settings on today-stats.html

thanks for reply

@0bi-w6n-K3nobi
Copy link
Contributor

0bi-w6n-K3nobi commented Sep 23, 2024

Hi @tyctor

Yeah... I understood now. I seems that.
Well, maybe @allinurl can add option for different contexts.
I.E. create the possibility add on suffix, prefix or name for that.
...
For now, on workaround you maybe create different profiles at you browser, one for each.

@tyctor
Copy link
Author

tyctor commented Oct 23, 2024

it seems that as workaround is enough to replace key in created html:

 sed -i s/'AppPrefs'/'AppPrefsToday'/g daily-report.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants