[geeklog-cvs] geeklog: Added a print.css stylesheet to be used by the printabl...
geeklog-cvs at lists.geeklog.net
geeklog-cvs at lists.geeklog.net
Sun Nov 23 06:21:04 EST 2008
details: http://project.geeklog.net/cgi-bin/hgweb.cgi/rev/371058dec30a
changeset: 6480:371058dec30a
user: Dirk Haun <dirk at haun-online.de>
date: Sun Nov 23 12:20:53 2008 +0100
description:
Added a print.css stylesheet to be used by the printable template files (feature request #0000766)
diffstat:
6 files changed, 32 insertions(+), 5 deletions(-)
plugins/staticpages/functions.inc | 2 ++
plugins/staticpages/templates/printable.thtml | 10 ++++++----
public_html/docs/history | 4 ++++
public_html/docs/theme.html | 6 ++++++
public_html/layout/professional/article/printable.thtml | 4 +++-
public_html/layout/professional/print.css | 11 +++++++++++
diffs (109 lines):
diff -r 209629e9999f -r 371058dec30a plugins/staticpages/functions.inc
--- a/plugins/staticpages/functions.inc Sun Nov 23 10:47:30 2008 +0100
+++ b/plugins/staticpages/functions.inc Sun Nov 23 12:20:53 2008 +0100
@@ -409,6 +409,8 @@
$print->set_var('site_slogan', $_CONF['site_slogan']);
$print->set_var('direction', $LANG_DIRECTION);
+ $print->set_var('lang_id', ''); // TBD
+ $print->set_var('lang_attribute', ''); // TBD
$print->set_var('xhtml', XHTML);
$print->set_var('page_title', $_CONF['site_name'] . ' - '
. stripslashes($A['sp_title']));
diff -r 209629e9999f -r 371058dec30a plugins/staticpages/templates/printable.thtml
--- a/plugins/staticpages/templates/printable.thtml Sun Nov 23 10:47:30 2008 +0100
+++ b/plugins/staticpages/templates/printable.thtml Sun Nov 23 12:20:53 2008 +0100
@@ -1,7 +1,9 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html>
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
+<html {lang_attribute}>
<head>
- <title>{page_title}</title>
+ <title>{page_title}</title>
+ <link rel="stylesheet" type="text/css" href="{layout_url}/print.css"{xhtml}>
+ <link rel="stylesheet" type="text/css" media="print" href="{layout_url}/print.css"{xhtml}>
</head>
<body dir="{direction}">
<h1>{sp_title}</h1>
@@ -13,6 +15,6 @@
<p>{site_name}<br{xhtml}>
<a href="{sp_url}">{sp_url}</a>
</p>
-({comments_text})
+<p>({comments_text})</p>
</body>
</html>
diff -r 209629e9999f -r 371058dec30a public_html/docs/history
--- a/public_html/docs/history Sun Nov 23 10:47:30 2008 +0100
+++ b/public_html/docs/history Sun Nov 23 12:20:53 2008 +0100
@@ -3,6 +3,8 @@
??? ??, 2008 (1.5.2)
------------
+- Added a print.css stylesheet to be used by the printable template files
+ (feature request #0000766) [Dirk]
- Re-introduced the path hints in the install script when it can't find
db-config.php [Dirk]
- Added a note about the max. dimensions of a userphoto in the About You pane
@@ -78,6 +80,8 @@
Static Pages plugin
-------------------
+- The printable.thtml template file uses the HTML Strict doctype and print.css
+ now [Dirk]
- Fixed call to WS_makeId when sp_id was longer than STATICPAGE_MAX_ID_LENGTH
(found by Marc Maier) [Dirk]
- Display "successfully saved" and "successfully deleted" messages, just like
diff -r 209629e9999f -r 371058dec30a public_html/docs/theme.html
--- a/public_html/docs/theme.html Sun Nov 23 10:47:30 2008 +0100
+++ b/public_html/docs/theme.html Sun Nov 23 12:20:53 2008 +0100
@@ -200,6 +200,9 @@
<ul>
<li>New variable <tt>{photo_max_dimensions}</tt> to inform users about the
max. dimensions of a userphoto: <tt>preferences/userphoto.thtml</tt></li>
+<li>Added a <tt>print.css</tt> stylesheet to be used by the
+ <tt>printable.thtml</tt> template files for articles and the static pages
+ plugin.</li>
</ul>
<h3>Plugins</h3>
@@ -208,6 +211,9 @@
<li>The template file for the Polls editor has been changed to allow up to 40
characters for the poll id (pid):
<tt>plugins/polls/templates/admin/polleditor.thtml</tt></li>
+<li>The <tt>printable.thtml</tt> template file for the static pages plugin now
+ uses <tt>print.css</tt> (see above). It also uses the HTML Strict doctype
+ now.</li>
</ul>
<h2><a name="changes151">Theme changes in Geeklog 1.5.1</a></h2>
diff -r 209629e9999f -r 371058dec30a public_html/layout/professional/article/printable.thtml
--- a/public_html/layout/professional/article/printable.thtml Sun Nov 23 10:47:30 2008 +0100
+++ b/public_html/layout/professional/article/printable.thtml Sun Nov 23 12:20:53 2008 +0100
@@ -1,7 +1,9 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html {lang_attribute}>
<head>
- <title>{page_title}</title>
+ <title>{page_title}</title>
+ <link rel="stylesheet" type="text/css" href="{layout_url}/print.css"{xhtml}>
+ <link rel="stylesheet" type="text/css" media="print" href="{layout_url}/print.css"{xhtml}>
</head>
<body dir="{direction}">
<h1>{story_title}</h1>
diff -r 209629e9999f -r 371058dec30a public_html/layout/professional/print.css
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/public_html/layout/professional/print.css Sun Nov 23 12:20:53 2008 +0100
@@ -0,0 +1,11 @@
+/* STYLESHEET FOR PRINTOUTS ***************************************************
+
+ Minimal stylesheet for printable templates.
+
+*/
+
+body {
+ background:#FFFFFF;
+ color:#000000;
+ font-family: arial,verdana,tahoma,helvetica,sans-serif;
+}
More information about the geeklog-cvs
mailing list