0

There is a Unity WebGL application on the page. You need to call a certain function when a page parameter changes, but not to update it, so that the changes only affect the application. Is this even possible?

I was trying to find information on this and came across ajax, but it didn't seem to me to be quite what I needed. I couldn't find any more information.

Femidis
  • 1
  • 2

1 Answers1

1

The user entering an address into their browser and loading a new page (even if is the same page) is an operation that happens outside of the web application. You cannot prevent it.

The closest you could come would be to warn the user that they are leaving your app and offer them the opportunity to cancel navigation. They do not have to take it.

Quentin
  • 914,110
  • 126
  • 1,211
  • 1,335
  • if i do server, that get queries and will handle it as I need to, it wil solve problem? – Femidis May 23 '23 at 07:34
  • Your stated problem is that the page reloads if the user reloads the page. You can't prevent the user from doing that. – Quentin May 23 '23 at 19:01