Im trying to print off a site that has no print.css so when it comes out all you get is an unformatted page, is there away to somehow use the normal screen css for the print out ?
Related
I am trying to create a PDF using HTML content. Everything is fine but i have one problem where the page breaks on PDF get inserted between content and cause it to divide between pages.
Example:
A portrait image with height>width get a page break half way in between and causes half image to be on page 1 and the other half to be on page 2. This is just an example, the content on my PDF is dynamic, meaning the user has control over generating amount of content. Therefore its not necessary that image be always on page 1 it could be anywhere on the document.
I have tried to search for some libraries also but as per my understanding of how PDF files are rendered in iOS, I don't have any clue how to manage content that gets divided due to the page breaks.
Platform: iOS 10, xcode 8, Objective-C
Try to add something like the following to your css.
img {
page-break-inside:avoid
}
See also:
Print styles: How to ensure image doesn't span a page break
i had used pdf.js in one of my projects. It is loading in the example. But, In an HTML page, It shows loading. If i try to see in full screen, it loads the pdf and then shows the pdf in html page for about 10 seconds after exiting full screen view. After that it will shows blank page with loading.
Whenever I try to see the pdf in full screen the same happens.
If anyone got the solution or any idea why it is so, then please do reply ASAP.Thanks in advance
Somehow my iPad mini is doing some weird caching.
I made a web page and inserted html code with a wrong src path. I tried to load the page on the mobile web app (after adding it to home screen) and it didn't work (as expected). I fixed the path and the image now shows on all browsers, including the Safari web browser, but not if I open the web app from home screen.
My HTML is simply this:
<img src="images/games/oplossing.png" alt="de oplossing"/>
The surrounding div is set to 'display: none' but gets set to 'display: block' after clicking a button.
I also tried to:
link to absolute path
Delete the app from homescreen and add to homescreen
If I alter the HTML, save change some text, it shows me the change. This means the page is not cached but somehow the broken image link is..
I have created a print button on my site which launches the print dialogue box. I also have a print.css file which is used to layout the print document. In this print.css file I have discarded everything I don't need. Only the logo of the company, title of the page, the header image and the relevant content will print.
All looks dandy when I view it with the web developer toolbar in FF. When testing in Internet Explorer I get random text and my logo image decides it is going to sit anywhere it likes.
Is there a resource of best print practices to follow for printing, specifically in IE?
I want to enable printing a picture from my web page so that the picture will be previewed and printed twice on the same page i.e. 1 A4 with the image printed 2 or 4 times on the same A4.
Is it possible with the FF and IE browsers interface?
Thanks,
Yuval.
I dont see why not?
Better to brush up on print stylesheets in order to hide non-relevant items on the page.
Make a print link below the picture or wherever you like. Make it point to another HTML site on which you have placed the pictures as you like (with CSS or plain HTML).
Finally, use javascript (at page load) on that site with the pictures to open the printing dialog in the browser.
Good luck.