[Logo] Enterprise Client Community
  [Search] Search   [Recent Topics] Recent Topics   [Members]  Member Listing   [Groups] Back to home page 
[Register] Register / 
[Login] Login 
disable back button  XML
Forum Index -> Development
Author Message
mreich

Power User
[Avatar]

Joined: 30/01/2009 08:34:23
Messages: 750
Offline

Hi,

I want to disable back navigation.
I found this article
https://bhartee-tech-ror.medium.com/how-to-stop-the-browser-back-button-in-js-5386e078449b#:~:text=Window%20%60onload%60%20Event%3A&text=onload%60%20event%3A-,window.,navigation%20will%20be%20triggered%20again.

where would be the best place to but this snippet?

regards
Markus
[WWW]
CaptainCasa

Power User
[Avatar]

Joined: 21/11/2007 12:23:06
Messages: 5545
Offline

Hi,

you can place any additional JavaScript code, view first chatper of:

https://www.captaincasa.com/docu/eclnt_risc_developersguide_addon/

But to be honest: I do not believe that what is described in the article you mention is working for Single Page Application type of pages: as far as I see, the navigation is executed, but on the same page again: this means the current page should be reloaded... Anyway you may give a try: if you are successful, then we immediately copy from what you do! ;-)

KInd regards! Björn

PS: for interested readers: the common way to avoid unwanted back-navigation is to set CONFIRMEXIT to "true": then the default browser window shows up and the user has to confirm he/she wants to leave the application.

and PPS: another way it to start the dialog as progressive web application, then it runs in an own windows without the browser "surroundings"

Björn Müller, CaptainCasa GmbH
 
Forum Index -> Development
Go to:   
Powered by JForum 2.1.6 © JForum Team