Hi there!
Is there a way to refresh the page to all users when one of them clicks on a button like in Cent Auctions ?
For example:
There is a button refresh and when I click it the page refreshes to all...

Recommended Answers

All 4 Replies

I really don't understand what you are trying to achieve here!
But you can refresh the page with this bits of code:

<input type="button" value="refresh" onclick="window.location.reload();" />

I'll try to explain it.
We have a button "Refresh" (For example), when someone clicks that button the page refreshes but not only to him, but to all users on that page. Is that more cler ?

Try this one instead

<input type="button" value="refresh" onclick="window.opener.refresh();" />

to note that this will only work with windows that are in the same domain...

Member Avatar for fatihpiristine

try to send a http request to server periodically and check the version number. if the version on client side less then the server side, refresh the page... dont forget to increase the version each time.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.