Landing Page toggle in admin - Postet den (112 Views)
Forum Moderator
doughnut
Innlegg: 899
899

Landing Page toggle on off in admin; I think maybe some will or some won't like the landing page and would rather go straight to All Forums or would maybe switch it on when there's a lot to say?

I don't know how hard this would be.

 Sortering, for datoer betyr DESC nyeste først  
 Sidestørrelse 
Postet den
Forum Administrator
HuwR
Innlegg: 4750
4750

Possibly not that easy as it is tied into the structure of the breadcrumbs but will take a look.

Postet den
Forum Moderator
doughnut
Innlegg: 899
899

👍🏻

Dough

Postet den
Forum Administrator
HuwR
Innlegg: 4750
4750

Found a fairly simple way to achieve this 😀

Postet den
Forum Administrator
HuwR
Innlegg: 4750
4750

Code added for this

Postet den
Forum Moderator
doughnut
Innlegg: 899
899

👍

Dough

Postet den
Forum Administrator
HuwR
Innlegg: 4750
4750

It was fairly simple to implement, however it comes with a couple of caveats.

  1. t can not be set on the fly, it requres shutting down and restarting the application if a change is required
  2. Once set, changing it may cause weird behaviour from members who still get redirected (browsers cache the redirect url)
Postet den
Forum Moderator
doughnut
Innlegg: 899
899

Yea I wouldn’t want it to cause problems, it’s impressive that you found a way to do it but if it’s gonna cause issues maybe let it be…

Dough

Postet den
Forum Administrator
HuwR
Innlegg: 4750
4750

It will only cause probems if you change it to something else, not sure how long browsers cache it for, but clearing the browsers cache will fix it.

Postet den
Forum Moderator
doughnut
Innlegg: 899
899

Worth a trial then?

Dough

Postet den
Forum Administrator
HuwR
Innlegg: 4750
4750

Worth a trial then?

Originally posted by doughnut

👍

To set the landing page, you can use the new "FileManager" option on the Admin menu, when the file manager loads you should see a file called appsettings.json, select this file and click the edit icon on the filemanager toolbar.
When the file opens, look in the SnitzForums section and you will see a setting for "LandingPage" change it's value from "" to "AllForums" and save the file.

Saving this file will trigger an app pool recycle so there may be a small delay when you try to open a new page while it reloads the application.

If you now try to go to the "home" page it should redirect you to AllForums and hide the "Home" links in the breadcrumb.

Be careful when editing this file, if you make a mistake it may prevent the application from reloading.

Du må legge inn en melding