Skip to content

Commit 2693bb1

Browse files
authored
Merge pull request #91 from jasonday/footer
1.8.0 - Added "footers"
2 parents 3b7007e + 60bc9d7 commit 2693bb1

File tree

4 files changed

+13
-4
lines changed

4 files changed

+13
-4
lines changed

changelog.txt

+5-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
1-
10/15/2017 Added quoting around values to correct behavior of complex values
1+
01/16/2017 Added footer as proposed in 2015 by @RomainGehrig
2+
Bumped version to 1.8.0 for new feature
3+
Corrected 1.7.1 changelog date to 01/15/2017
4+
5+
01/15/2017 Added quoting around values to correct behavior of complex values
26
Bumped to 1.7.1
37

48
12/14/2016 Added support for arbitrary BASE urls.

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "print-this",
3-
"version": "1.7.1",
3+
"version": "1.8.0",
44
"description": "Printing plug-in for jQuery",
55
"main": "printThis.js",
66
"dependencies": {

printThis.jquery.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "printThis",
3-
"version": "1.7.1",
3+
"version": "1.8.0",
44
"title": "printThis",
55
"description": "Printing plug-in for jQuery. Print specific page elements, add print options, maintain or add new styling using jQuery.",
66
"author": {

printThis.js

+6-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* printThis v1.7.1
2+
* printThis v1.8.0
33
* @desc Printing plug-in for jQuery
44
* @author Jason Day
55
*
@@ -25,6 +25,7 @@
2525
* removeInline: false, * remove all inline styles from print elements
2626
* printDelay: 333, * variable print delay
2727
* header: null, * prefix to html
28+
* footer: null, * postfix to html
2829
* base: false, * preserve the BASE tag, or accept a string for the URL
2930
* formValues: true * preserve input/form values
3031
* });
@@ -206,6 +207,9 @@
206207
}
207208
}
208209

210+
// print "footer"
211+
if (opt.footer) $body.append(opt.footer);
212+
209213
setTimeout(function() {
210214
if ($iframe.hasClass("MSIE")) {
211215
// check if the iframe was created with the ugly hack
@@ -246,6 +250,7 @@
246250
removeInline: false, // remove all inline styles
247251
printDelay: 333, // variable print delay
248252
header: null, // prefix to html
253+
footer: null, // postfix to html
249254
formValues: true, // preserve input/form values
250255
base: false, // preserve the BASE tag, or accept a string for the URL
251256
doctypeString: '<!DOCTYPE html>' // html doctype

0 commit comments

Comments
 (0)