Solved

window.location.reload is not working in Chrome

Posted on 2011-09-09
5
4,269 Views
Last Modified: 2012-06-27
I have a popup and when i update the database I need to refresh the page

So use the window.location.reload(true); and it works in ie, firefox

However, does not work in chrome

0
Comment
Question by:erikTsomik
  • 3
  • 2
5 Comments
 
LVL 82

Expert Comment

by:leakim971
ID: 36512446
0
 
LVL 19

Author Comment

by:erikTsomik
ID: 36512450
so is there no solution?
0
 
LVL 82

Expert Comment

by:leakim971
ID: 36512475
check comment 5, you may want to implement a similar solution
0
 
LVL 19

Author Comment

by:erikTsomik
ID: 36512557
is there aNY OTHER alternatives. so i have a page (also a popup) on the page I click the link and it opensup a new popup with the form after update i click the close button and reload the page
0
 
LVL 82

Accepted Solution

by:
leakim971 earned 500 total points
ID: 36512908
you want only refresh the page? or post new data?

IF THERE'S NO LOGIC ON THE SERVER SIDE DOING SOMETHING WHEN POSTING THE DATA (it's most of time not the case)

document.forms[0].submit();
or jQuery equivalent : $("form").submit();

or try : location.href = location.href;
or again : location.href + ((location.href.indexOf("?")>0)?"&rdmtime=":"?rdmtime=") + new Date().getTime();
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
Use these top 10 tips to master the art of email signature design. Create an email signature design that will easily wow recipients, promote your brand and highlight your professionalism.
In this tutorial viewers will learn how add a scalable full-width header using CSS3. Create a new HTML document with an internal stylesheet. Set a tiled background.:  Create a new div and name it Header. Position it with position:absolute at the top…
In this tutorial viewers will learn how to embed videos in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <video> tag to insert a video. Define the src as the URL of your video; this is similar to …

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now