Is there a way to prevent the "navigate away" warning?

Use this board to ask questions or have discussions with other Rich Displays users.
Post Reply
Bryan641
Profound User
Posts: 72
Joined: Fri Oct 01, 2010 5:07 pm
First Name: Bryan
Last Name: Leaman
Company Name: InVue Security
Phone: 704-752-6513 x221
Address 1: 15015 Lancaster Hwy
City: Charlotte
State / Province: North Carolina
Zip / Postal Code: 28277
Contact:

Is there a way to prevent the "navigate away" warning?

Post by Bryan641 »

Can we suppress the "Are you sure you want to navigate away from this page" warning and just always allow it? What are the implications of doing so?

--Bryan
User avatar
Alex
Profound Logic Staff Member
Posts: 233
Joined: Fri Jan 04, 2008 12:10 pm
First Name: Alex
Last Name: Roytman
Company Name: Profound Logic Software
Contact:

Re: Is there a way to prevent the "navigate away" warning?

Post by Alex »

The following line JavaScript code will suppress the warning:

pui.confirmOnClose = false;

After you do this, when the user closes the browser or navigates away from the the page, a signal will be sent to the server to just end the job.
Bryan641
Profound User
Posts: 72
Joined: Fri Oct 01, 2010 5:07 pm
First Name: Bryan
Last Name: Leaman
Company Name: InVue Security
Phone: 704-752-6513 x221
Address 1: 15015 Lancaster Hwy
City: Charlotte
State / Province: North Carolina
Zip / Postal Code: 28277
Contact:

Re: Is there a way to prevent the "navigate away" warning?

Post by Bryan641 »

I tried that several places, and when it didn't work, I searched runtime.js and ended up trying

Code: Select all

pui.skipConfirm=true; 
This worked.
--Bryan

(Note, I would like to allow users to navigate away from the application at will. Are there any negatives associated with allowing this?)
User avatar
Rob
Profound Logic Staff Member
Posts: 135
Joined: Fri Jan 04, 2008 12:12 pm
First Name: Rob
Last Name: Ferguson
Company Name: Profound Logic Software
Contact:

Re: Is there a way to prevent the "navigate away" warning?

Post by Rob »

Once the user navigates away from the page, the session is lost and the Profound UI session controller ends all jobs associated with that session.

It is a little like closing Client access without first signing off.
User avatar
Alex
Profound Logic Staff Member
Posts: 233
Joined: Fri Jan 04, 2008 12:10 pm
First Name: Alex
Last Name: Roytman
Company Name: Profound Logic Software
Contact:

Re: Is there a way to prevent the "navigate away" warning?

Post by Alex »

Bryan, you are correct. pui.skipConfirm=true is the right way to do it.
Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests