Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7578461
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T17:26:16+00:00 2026-05-30T17:26:16+00:00

The page I am working on has a javascript function executed to print parts

  • 0

The page I am working on has a javascript function executed to print parts of the page.
For some reason, printing in Safari, causes the window to somehow update. I say somehow, because it does not really refresh as in reload the page, but rather it starts the “rendering” of the page from start, i.e. scroll to top, flash animations start from 0, and so forth.

The effect is reproduced by this fiddle: http://jsfiddle.net/fYmnB/

Clicking the print button and finishing or cancelling a print in Safari causes the screen to “go white” for a sec, which in my real website manifests itself as something “like” a reload. While running print button with, let’s say, Firefox, just opens and closes the print dialogue without affecting the fiddle page in any way.

Is there something with my way of calling the browsers print method that causes this, or how can it be explained – and preferably, avoided?

P.S.: On my real site the same occurs with Chrome. In the example fiddle Chrome seems to not show the same behaviour as Safari, though.

Edit: I also tried to have the printing button on a different tag than an a anchor, like span or button, but that didn’t help with the problem.

Edit: I run into this problem with Safari 5.1.2 on Mac OS 10.6.8. In the jsfiddle example, the behavior shows as a white “flicker” that covers the whole browser after having clicked the print button and closing (either printing or aborting) the print dialogue.

Edit: Just started a bounty for this question, as I am still looking for an explanation for this browser behaviour. I am more than willing to give more details on the issue. From my experience on SO it is not adviseable to post links to online pages, however I feel the problem is really hard to reproduce. I think the “flicker & re-render” I experience with the posted jsfiddle is hopefully is result of the same problem.

Edit: As explained in the comments, opening a new window containing the current state of the application, then printing and closing that window, might be a fix, but I don’t consider it a sufficient answer to the problem at hand.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T17:26:18+00:00Added an answer on May 30, 2026 at 5:26 pm

    I’m not sure if this will fix your problem but i recently found a very good Jquery plugin to print only certain part of your webpage.

    You should give it a try 🙂 It has a some very cool parameters to customize it to your needs.

    Take a look here.

    Why does your page refresh? Here’s my answer on that. the window.print() function will print the entire content of your page. So since i read that you only want to print a part of the page, I guess you are using some function to remove all unwanted content from the page for a very short moment, then you call the window.print() function and after that you put all orignal content again on the screen. This results in a very short flash that will look like your page is refreshing and will load all flash parts again.

    I had the same problem yesterday and this jquery plugin really helped me out. I hope it will help you too.

    Have a nice day!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

The ASP.net page I am currently working on has a drop down list that
I'm working on a page has an ol with nested p's, div's, and li's.
I am working on a web page that has a large number of tables.
Currently I am working on a web page that has six ReportViewer controls that
I am currently working on a page that has a date picker for one
I'm working on a PHP dynamic web page that has a <textarea> element that
I am working with php and want to have a page that has a
I'm working with a script in which the postid of the page has been
I have a simple page that has a (non-Prototype) JavaScript pop-up for login. It
I am working with a user control that has set of javascript functions that

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.