X
Tap here to go to the mobile version of the site.

Fóram Tacaíochta

Cuireadh an snáithe seo sa chartlann. Cuir ceist nua má tá cabhair uait.

Reload button doesnt refresh the page

Postáilte

Hi, so I started learning to develop websites a while ago, and all was good. However, recently I've had an issue. When I make a change and I'd like to refresh the page, to see it how someone visiting for the first time would see it, the page reloads, however it's exactly the same. For example, I've got 2 buttons. When button 1 clicked, button 2 gets disabled. Refresh the page and... button 2 is still disabled. In other browsers, both buttons return to their "default state". Shift-clicking the reload button does in fact refresh the page as expected. But a normal click, even if the webpage was retrieved from cache, should at least refresh the page, right? I've tried refreshing firefox, so add-ons are not the issue, and this hasn't been an issue before, any help is appreciated.

Hi, so I started learning to develop websites a while ago, and all was good. However, recently I've had an issue. When I make a change and I'd like to refresh the page, to see it how someone visiting for the first time would see it, the page reloads, however it's exactly the same. For example, I've got 2 buttons. When button 1 clicked, button 2 gets disabled. Refresh the page and... button 2 is still disabled. In other browsers, both buttons return to their "default state". Shift-clicking the reload button does in fact refresh the page as expected. But a normal click, even if the webpage was retrieved from cache, should at least refresh the page, right? I've tried refreshing firefox, so add-ons are not the issue, and this hasn't been an issue before, any help is appreciated.

Athraithe ag bradp ar

Réiteach roghnaithe

As you have discovered, Firefox may retain and prefill cached form field values and other "page state" when redisplaying a page. I really appreciate that in recent months this site allows that.

If you want a "standard" reload (not holding shift) to default the fields back to their original values and status, you could try preventing Firefox from caching the page -- some developers have said this is difficult because Firefox is rather stubborn about flushing cached pages -- or hook a different event (pageshow) to clear the fields back to default values.

More info in this article: https://developer.mozilla.org/Firefox/Releases/1.5/Using_Firefox_1.5_caching

Read this answer in context 0

Tuilleadh mionsonraí faoin chóras

Breiseáin Shuiteáilte

  • Intel web components updater - Installs and updates the Intel web components
  • Intel web components for Intel® Identity Protection Technology
  • NPRuntime Script Plug-in Library for Java(TM) Deploy
  • Next Generation Java Plug-in 11.45.2 for Mozilla browsers
  • The plugin allows you to have a better experience with Microsoft SharePoint
  • The plugin allows you to have a better experience with Microsoft Lync
  • Shockwave Flash 23.0 r0

Feidhmchlár

  • Firefox 49.0.1
  • User Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:49.0) Gecko/20100101 Firefox/49.0
  • URL Tacaíochta: https://support.mozilla.org/1/firefox/49.0.1/WINNT/en-GB/

Eisínteachtaí

  • Multi-process staged rollout 1.2 (e10srollout@mozilla.org)
  • Pocket 1.0.4 (firefox@getpocket.com)
  • Web Compat 1.0 (webcompat@mozilla.org)

JavaScript

  • incrementalGCEnabled: True

Grafaic

  • adapterDescription: Intel(R) HD Graphics 5500
  • adapterDescription2: AMD Radeon R7 M260
  • adapterDeviceID: 0x1616
  • adapterDeviceID2: 0x6900
  • adapterDrivers: igdumdim64 igd10iumd64 igd10iumd64 igd12umd64 igdumdim32 igd10iumd32 igd10iumd32 igd12umd32
  • adapterDrivers2: aticfx64 aticfx64 aticfx64 amdxc64 aticfx32 aticfx32 aticfx32 amdxc32 atiumd64 atidxx64 atidxx64 atiumdag atidxx32 atidxx32 atiumdva atiumd6a atitmm64
  • adapterRAM: Unknown
  • adapterRAM2: 2048
  • adapterSubsysID: 00000000
  • adapterSubsysID2: 00000000
  • adapterVendorID: 0x8086
  • adapterVendorID2: 0x1002
  • crashGuards: []
  • direct2DEnabled: True
  • directWriteEnabled: True
  • directWriteVersion: 10.0.10586.589
  • driverDate: 6-13-2016
  • driverDate2: 8-6-2015
  • driverVersion: 20.19.15.4474
  • driverVersion2: 15.201.1101.0
  • featureLog: {u'fallbacks': [], u'features': [{u'status': u'available', u'description': u'Compositing', u'name': u'HW_COMPOSITING', u'log': [{u'status': u'available', u'type': u'default'}]}, {u'status': u'available', u'description': u'Direct3D11 Compositing', u'name': u'D3D11_COMPOSITING', u'log': [{u'status': u'available', u'type': u'default'}]}, {u'status': u'available', u'description': u'Direct3D9 Compositing', u'name': u'D3D9_COMPOSITING', u'log': [{u'status': u'available', u'type': u'default'}]}, {u'status': u'available', u'description': u'Direct2D', u'name': u'DIRECT2D', u'log': [{u'status': u'available', u'type': u'default'}]}, {u'status': u'available', u'description': u'Direct3D11 hardware ANGLE', u'name': u'D3D11_HW_ANGLE', u'log': [{u'status': u'available', u'type': u'default'}]}]}
  • info: {u'AzureCanvasAccelerated': 0, u'AzureCanvasBackend': u'direct2d 1.1', u'AzureFallbackCanvasBackend': u'cairo', u'ApzWheelInput': 1, u'AzureContentBackend': u'direct2d 1.1'}
  • isGPU2Active: False
  • numAcceleratedWindows: 2
  • numTotalWindows: 2
  • supportsHardwareH264: No; D3D11 blacklisted with DLL atidxx32.dll (8.17.10.625); D3D9 blacklisted with DLL atiumd64.dll (9.14.10.1128)
  • webglRenderer: Google Inc. -- ANGLE (Intel(R) HD Graphics 5500 Direct3D11 vs_5_0 ps_5_0)
  • windowLayerManagerRemote: True
  • windowLayerManagerType: Direct3D 11

Sainroghanna Athraithe

Éagsúil

  • User JS: No
  • Inrochtaineacht: Níl

Úinéir na ceiste

Any suggestions on this?

Any suggestions on this?

Úinéir na ceiste

Update: Still no response :(

Update: Still no response :(
Noah_SUMO
  • Moderator
98 réiteach 613 freagra

So sorry for the wait! Your thread slipped thru us somehow.

I was thinking this was caused by a addon that added web dev options to help you debug your site. But since you refreshed Firefox that can't be the case. Although you may have enabled a developer tool option that could be causing this problem like the disable cache setting. But I'm going to ask Jscher, a contributor with web dev experience to help us out here. I'm hoping he can help us figure out what's going on here.

You can really help us out by sharing the link to your site or making it publicly accessible so that we can try it out ourselves and see what might be wrong. Thanks! Btw what other browsers did you test your site in?

So sorry for the wait! Your thread slipped thru us somehow. I was thinking this was caused by a addon that added web dev options to help you debug your site. But since you refreshed Firefox that can't be the case. Although you may have enabled a developer tool option that could be causing this problem like the disable cache setting. But I'm going to ask Jscher, a contributor with web dev experience to help us out here. I'm hoping he can help us figure out what's going on here. You can really help us out by sharing the link to your site or making it publicly accessible so that we can try it out ourselves and see what might be wrong. Thanks! Btw what other browsers did you test your site in?
jscher2000
  • Top 10 Contributor
8800 réiteach 71983 freagra

Réiteach Roghnaithe

As you have discovered, Firefox may retain and prefill cached form field values and other "page state" when redisplaying a page. I really appreciate that in recent months this site allows that.

If you want a "standard" reload (not holding shift) to default the fields back to their original values and status, you could try preventing Firefox from caching the page -- some developers have said this is difficult because Firefox is rather stubborn about flushing cached pages -- or hook a different event (pageshow) to clear the fields back to default values.

More info in this article: https://developer.mozilla.org/Firefox/Releases/1.5/Using_Firefox_1.5_caching

As you have discovered, Firefox may retain and prefill cached form field values and other "page state" when redisplaying a page. I really appreciate that in recent months this site allows that. If you want a "standard" reload (not holding shift) to default the fields back to their original values and status, you could try preventing Firefox from caching the page -- some developers have said this is difficult because Firefox is rather stubborn about flushing cached pages -- or hook a different event (pageshow) to clear the fields back to default values. More info in this article: https://developer.mozilla.org/Firefox/Releases/1.5/Using_Firefox_1.5_caching

Úinéir na ceiste

Hi, thanks for the responses https://bradleyphillips.co.uk/uni/example.html Is a basic example of what I'm trying to explain. When the start button is pressed the stop button gets disabled, but on page reload the stop button doesn't get re-enabled. In response to jscher2000, are you saying that I'll have to use javascript to refresh the page state on reload? Unfortunately I don't have time right now to read through the link, but I'll have a look in a few hours. Thanks again for the responses, Brad

Hi, thanks for the responses https://bradleyphillips.co.uk/uni/example.html Is a basic example of what I'm trying to explain. When the start button is pressed the stop button gets disabled, but on page reload the stop button doesn't get re-enabled. In response to jscher2000, are you saying that I'll have to use javascript to refresh the page state on reload? Unfortunately I don't have time right now to read through the link, but I'll have a look in a few hours. Thanks again for the responses, Brad

Úinéir na ceiste

So I've just found some time to look through the link, and it seems to explain everything, thanks again, brad

So I've just found some time to look through the link, and it seems to explain everything, thanks again, brad