[Phpmyadmin-devel] Regarding RFE #701

Isaac Bennetch bennetch at gmail.com
Thu May 28 20:41:32 CEST 2015

Hi Deven,

On 5/25/15 11:25 AM, Deven Bansod wrote:
> ​Hi, 
>> ​Thanks for the reply.​
> On Mon, May 25, 2015 at 6:31 PM, Isaac Bennetch <bennetch at gmail.com
> <mailto:bennetch at gmail.com>> wrote:
>     Hi,
>     Sorry for my delayed response; it's a holiday weekend here and I was
>     away from the internet all day yesterday.
>     On 5/23/15 6:29 AM, Deven Bansod wrote:
>     > Hi,
>     >
>     > RFE #701 proposes that we should replace the 'Print View' and 'Print
>     > View (with Full Texts)' with a 'Print View' Option which should print
>     > out the CSS of the page only (i.e. whatever exactly is currently
>     > displayed on the page itself).
>     >
>     > /I had something in mind about the implementation, but am not able to
>     > figure some details. Any help in this regard would be appreciated. /
>     My first thought when I saw the initial feature request years ago was to
>     make a print view stylesheet (such as [0])that hides the navigation
>     frame, menu bar, etc. At the time, that wasn't a viable option because
>     of the frameset, but with the move to a single page for display it might
>     be possible now. I did not test whether this would actually work for us,
>     but if it does the "Print" button can simply become a javascript
>     function to tell the browser to print rather than opening a whole new
>     plain-formatted page with different rendering. For me, this certainly
>     would be the preferred method if it works.
> ​Thanks for the link. I will look into it and explore.​

I've done some exploring with the CSS solution, and thought I'd share my
thoughts, although they're incomplete at this time.

I had some success so far with making the following changes to CSS
(which I would expect to be reflected in a print stylesheet, which
should be loaded after the other stylesheets to override any duplicated
directives). There are obviously some unwanted elements remaining, but
this looks like the beginnings of a decent print view.

Note that for development purposes, I like to leave the "print"
stylesheet set for screen display, that way I can view what it will look
like without constantly going to the print preview feature of my
browser. Once it looks good on my screen, I set the stylesheet to @media
print{} and check it in the actual print preview. It's not a sure thing
of how it will look when rendered for printing, but helps me get close
without wasting a lot of time in the print dialog.

Here are the changes I made so far:

  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  float: none;
/* float:none is a work around for a Gecko-based bug when printing
  more than one page; see
  http://bugzilla.mozilla.org/show_bug.cgi?id=104040 and
  https://bugzilla.mozilla.org/show_bug.cgi?id=129941 -- this may
  actually be resolved, finally, but doesn't seem to hurt anything and
  old habits die hard

  display: hidden;

  display: hidden;

  display: hidden;

  display: hidden;

More information about the Developers mailing list