Solved

getUrl : reload window not at top of page

Posted on 2009-04-15
7
686 Views
Last Modified: 2012-05-06
Hi
I have the following code on a button which causes the page to reload.
getURL("javascript:window.location.reload()")
The button is positioned way down the page.
When the page reloads in IE I'm at the top .. great.
When it reloads in FF it goes to where the button is (way down the page) .. not great.

I can't find a way of adding an anchor to the link ..

Any help please ..

E.
getURL("javascript:window.location.reload()")

Open in new window

0
Comment
Question by:eppyfone
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
7 Comments
 
LVL 75

Accepted Solution

by:
Michel Plungjan earned 500 total points
ID: 24155071
getURL("javascript:window.location.reload(1)")

or

getURL("javascript:window.location='someurl#top")

where the page has

near the top


0
 
LVL 75

Assisted Solution

by:Michel Plungjan
Michel Plungjan earned 500 total points
ID: 24155075
If you are really desperate do this
getURL("javascript:window.location.reload(1); setTimeout('window.scrollTo(0,0)',10)")

Open in new window

0
 

Author Closing Comment

by:eppyfone
ID: 31570514
Hi
The number(1) instead of the empty brackets works.
Excellent

Thanks
0
Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

 

Author Comment

by:eppyfone
ID: 24155792
Hi
version with (1) instead of () works
version with url doesn't
version with (1) and settimeout works .. but could just be the (1) ?
Thanks anyway .. SOLVED
E.
0
 
LVL 75

Expert Comment

by:Michel Plungjan
ID: 24157188
The (1) means "from server"
0
 

Author Comment

by:eppyfone
ID: 24157701
I'm noticing that Safari isn't behaving the same .. any reason it doesn't like a forced refresh ?
 
E>
0
 
LVL 75

Expert Comment

by:Michel Plungjan
ID: 24158004
Not that I know of... Should work too.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

I've been trying to accomplish this for a while and it just struck me yesterday how to accomplish this task. I have done searches all over the internet looking for ways to email pages from my applications and finally I have done it!!! Every single s…
This article discusses how to create an extensible mechanism for linked drop downs.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

740 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