Solved

php to fit when print in paper

Posted on 2008-10-06
6
709 Views
Last Modified: 2012-05-05
Are there any method to make php print fit in the paper Pdf is the only choiice or have another method
please suggest
0
Comment
Question by:teera
  • 3
  • 2
6 Comments
 
LVL 14

Accepted Solution

by:
ali_kayahan earned 250 total points
ID: 22647981
       By changing the media type of your css file you can make special adjusments for print, just add one more css file in addition to your current css and set media as print..

<link rel="stylesheet" href="my_print_css_file.css" type="text/css" media="print" />
0
 

Author Comment

by:teera
ID: 22647990
and it will fit with paper wheter i use Firefox or IE
0
 
LVL 14

Expert Comment

by:ali_kayahan
ID: 22648004
  I just mean that , you can specify a special CSS file just for prints by this way ;

   <link rel="stylesheet" href="my_print_css_file.css" type="text/css" media="print" />

  So if there is some kind of outfit , than you can adjust it on the CSS file that you wrote for print, and it wont effect the browser behaviour...
0
Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

 
LVL 34

Assisted Solution

by:Beverley Portlock
Beverley Portlock earned 200 total points
ID: 22648016
It depends how important accuracy of layout is. If you need the layout to be exact then PDF is the only way. CSS is not good enough (yet!)
0
 
LVL 34

Expert Comment

by:Beverley Portlock
ID: 22648030
Another point that springs to mind is that the browsers often add "headers" and "footers" and these cannot be turned off by CSS, so you will get URLs, dates, times, page numbers etc across the tops and bottoms of the print outs.
0
 
LVL 14

Assisted Solution

by:ali_kayahan
ali_kayahan earned 250 total points
ID: 22648196
 So you should give a try to CSS , and if the result is not good enough than we may try to use a kind of pdf class..
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Introduction HTML checkboxes provide the perfect way for a web developer to receive client input when the client's options might be none, one or many.  But the PHP code for processing the checkboxes can be confusing at first.  What if a checkbox is…
Consider the following scenario: You are working on a website and make something great - something that lets the server work with information submitted by your users. This could be anything, from a simple guestbook to a e-Money solution. But what…
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…

757 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

19 Experts available now in Live!

Get 1:1 Help Now