WP-Print - Version 2.30

Version Description

Download this release

Release Info

Developer GamerZ
Plugin Icon WP-Print
Version 2.30
Comparing to
See all releases

Code changes from version 2.20 to 2.30

{print/images → images}/print.gif RENAMED
File without changes
{print/images → images}/printer_famfamfam.gif RENAMED
File without changes
print/wp-print-comments.php → print-comments.php RENAMED
@@ -2,8 +2,8 @@
2
  /*
3
  +----------------------------------------------------------------+
4
  | |
5
- | WordPress 2.1 Plugin: WP-Print 2.20 |
6
- | Copyright (c) 2007 Lester "GaMerZ" Chan |
7
  | |
8
  | File Written By: |
9
  | - Lester "GaMerZ" Chan |
@@ -11,7 +11,7 @@
11
  | |
12
  | File Information: |
13
  | - Printer Friendly Page For Comments |
14
- | - wp-print-comments.php |
15
  | |
16
  +----------------------------------------------------------------+
17
  */
@@ -23,7 +23,7 @@
23
  <p id="CommentTitle"><?php print_comments_number(); ?> <?php _e('To', 'wp-print'); ?> "<?php the_title(); ?>"</p>
24
  <?php foreach ($comments as $comment) : ?>
25
  <p class="CommentDate">
26
- <strong>#<?php echo $comment_count; ?> <?php comment_type(); ?></strong> <?php _e('By', 'wp-print'); ?> <u><?php comment_author(); ?></u> <?php _e('On', 'wp-print'); ?> <?php comment_date(sprintf(__('%s @ %s', 'wp-print'), get_option('date_format'), get_option('time_format'))); ?>
27
  </p>
28
  <div class="CommentContent">
29
  <?php if ($comment->comment_approved == '0') : ?>
2
  /*
3
  +----------------------------------------------------------------+
4
  | |
5
+ | WordPress 2.5 Plugin: WP-Print 2.30 |
6
+ | Copyright (c) 2008 Lester "GaMerZ" Chan |
7
  | |
8
  | File Written By: |
9
  | - Lester "GaMerZ" Chan |
11
  | |
12
  | File Information: |
13
  | - Printer Friendly Page For Comments |
14
+ | - wp-content/plugins/wp-print/print-comments.php |
15
  | |
16
  +----------------------------------------------------------------+
17
  */
23
  <p id="CommentTitle"><?php print_comments_number(); ?> <?php _e('To', 'wp-print'); ?> "<?php the_title(); ?>"</p>
24
  <?php foreach ($comments as $comment) : ?>
25
  <p class="CommentDate">
26
+ <strong>#<?php echo $comment_count; ?> <?php comment_type(__('Comment', 'wp-print'), __('Trackback', 'wp-print'), __('Pingback', 'wp-print')); ?></strong> <?php _e('By', 'wp-print'); ?> <u><?php comment_author(); ?></u> <?php _e('On', 'wp-print'); ?> <?php comment_date(sprintf(__('%s @ %s', 'wp-print'), get_option('date_format'), get_option('time_format'))); ?>
27
  </p>
28
  <div class="CommentContent">
29
  <?php if ($comment->comment_approved == '0') : ?>
print/wp-print-css.css → print-css.css RENAMED
@@ -1,8 +1,8 @@
1
  /*
2
  +----------------------------------------------------------------+
3
  | |
4
- | WordPress 2.1 Plugin: WP-Print 2.20 |
5
- | Copyright (c) 2007 Lester "GaMerZ" Chan |
6
  | |
7
  | File Written By: |
8
  | - Lester "GaMerZ" Chan |
@@ -10,7 +10,7 @@
10
  | |
11
  | File Information: |
12
  | - CSS Style For Printer Friendly Page |
13
- | - wp-print-css.css |
14
  | |
15
  +----------------------------------------------------------------+
16
  */
@@ -20,8 +20,6 @@ Body {
20
  font-family: Verdana, Arial, Tahoma;
21
  font-size: 12px;
22
  color: #000000;
23
- direction: ltr;
24
- text-align: left;
25
  }
26
  #Outline {
27
  width: 90%;
@@ -29,8 +27,6 @@ Body {
29
  margin-right: auto;
30
  padding: 10px;
31
  border: 1px solid #000000;
32
- direction: ltr;
33
- text-align: left;
34
  }
35
  #BlogTitle {
36
  font-weight: bold;
1
  /*
2
  +----------------------------------------------------------------+
3
  | |
4
+ | WordPress 2.5 Plugin: WP-Print 2.30 |
5
+ | Copyright (c) 2008 Lester "GaMerZ" Chan |
6
  | |
7
  | File Written By: |
8
  | - Lester "GaMerZ" Chan |
10
  | |
11
  | File Information: |
12
  | - CSS Style For Printer Friendly Page |
13
+ | - wp-content/plugins/wp-print/print-css.css |
14
  | |
15
  +----------------------------------------------------------------+
16
  */
20
  font-family: Verdana, Arial, Tahoma;
21
  font-size: 12px;
22
  color: #000000;
 
 
23
  }
24
  #Outline {
25
  width: 90%;
27
  margin-right: auto;
28
  padding: 10px;
29
  border: 1px solid #000000;
 
 
30
  }
31
  #BlogTitle {
32
  font-weight: bold;
print-options.php ADDED
@@ -0,0 +1,301 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /*
3
+ +----------------------------------------------------------------+
4
+ | |
5
+ | WordPress 2.5 Plugin: WP-Print 2.30 |
6
+ | Copyright (c) 2008 Lester "GaMerZ" Chan |
7
+ | |
8
+ | File Written By: |
9
+ | - Lester "GaMerZ" Chan |
10
+ | - http://lesterchan.net |
11
+ | |
12
+ | File Information: |
13
+ | - Print Options Page |
14
+ | - wp-content/plugins/wp-print/print-options.php |
15
+ | |
16
+ +----------------------------------------------------------------+
17
+ */
18
+
19
+
20
+ ### Variables Variables Variables
21
+ $base_name = plugin_basename('wp-print/print-options.php');
22
+ $base_page = 'admin.php?page='.$base_name;
23
+ $id = intval($_GET['id']);
24
+ $mode = trim($_GET['mode']);
25
+ $print_settings = array('print_options');
26
+
27
+
28
+ ### Form Processing
29
+ // Update Options
30
+ if(!empty($_POST['Submit'])) {
31
+ $print_options = array();
32
+ $print_options['post_text'] = addslashes(trim($_POST['print_post_text']));
33
+ $print_options['page_text'] = addslashes(trim($_POST['print_page_text']));
34
+ $print_options['print_icon'] = trim($_POST['print_icon']);
35
+ $print_options['print_style'] = intval($_POST['print_style']);
36
+ $print_options['print_html'] = trim($_POST['print_html']);
37
+ $print_options['comments'] = intval($_POST['print_comments']);
38
+ $print_options['links'] = intval($_POST['print_links']);
39
+ $print_options['images'] = intval($_POST['print_images']);
40
+ $print_options['videos'] = intval($_POST['print_videos']);
41
+ $print_options['text_direction'] = trim($_POST['print_text_direction']);
42
+ $print_options['disclaimer'] = trim($_POST['print_disclaimer']);
43
+ $update_print_queries = array();
44
+ $update_print_text = array();
45
+ $update_print_queries[] = update_option('print_options', $print_options);
46
+ $update_print_text[] = __('Print Options', 'wp-print');
47
+ $i=0;
48
+ $text = '';
49
+ foreach($update_print_queries as $update_print_query) {
50
+ if($update_print_query) {
51
+ $text .= '<font color="green">'.$update_print_text[$i].' '.__('Updated', 'wp-print').'</font><br />';
52
+ }
53
+ $i++;
54
+ }
55
+ if(empty($text)) {
56
+ $text = '<font color="red">'.__('No Print Option Updated', 'wp-print').'</font>';
57
+ }
58
+ }
59
+ // Uninstall WP-Print
60
+ if(!empty($_POST['do'])) {
61
+ switch($_POST['do']) {
62
+ case __('UNINSTALL WP-Print', 'wp-print') :
63
+ if(trim($_POST['uninstall_print_yes']) == 'yes') {
64
+ echo '<div id="message" class="updated fade">';
65
+ echo '<p>';
66
+ foreach($print_settings as $setting) {
67
+ $delete_setting = delete_option($setting);
68
+ if($delete_setting) {
69
+ echo '<font color="green">';
70
+ printf(__('Setting Key \'%s\' has been deleted.', 'wp-print'), "<strong><em>{$setting}</em></strong>");
71
+ echo '</font><br />';
72
+ } else {
73
+ echo '<font color="red">';
74
+ printf(__('Error deleting Setting Key \'%s\'.', 'wp-print'), "<strong><em>{$setting}</em></strong>");
75
+ echo '</font><br />';
76
+ }
77
+ }
78
+ echo '</p>';
79
+ echo '</div>';
80
+ $mode = 'end-UNINSTALL';
81
+ }
82
+ break;
83
+ }
84
+ }
85
+
86
+ ### Determines Which Mode It Is
87
+ switch($mode) {
88
+ // Deactivating WP-Print
89
+ case 'end-UNINSTALL':
90
+ $deactivate_url = 'plugins.php?action=deactivate&amp;plugin=wp-print/wp-print.php';
91
+ if(function_exists('wp_nonce_url')) {
92
+ $deactivate_url = wp_nonce_url($deactivate_url, 'deactivate-plugin_wp-print/wp-print.php');
93
+ }
94
+ echo '<div class="wrap">';
95
+ echo '<h2>'.__('Uninstall WP-Print', 'wp-print').'</h2>';
96
+ echo '<p><strong>'.sprintf(__('<a href="%s">Click Here</a> To Finish The Uninstallation And WP-Print Will Be Deactivated Automatically.', 'wp-print'), $deactivate_url).'</strong></p>';
97
+ echo '</div>';
98
+ break;
99
+ // Main Page
100
+ default:
101
+ $print_options = get_option('print_options');
102
+ ?>
103
+ <script type="text/javascript">
104
+ /* <![CDATA[*/
105
+ function check_print_style() {
106
+ print_style_options = document.getElementById("print_style").value;
107
+ if (print_style_options == 4) {
108
+ document.getElementById("print_style_custom").style.display = 'block';
109
+ } else {
110
+ if(document.getElementById("print_style_custom").style.display == 'block') {
111
+ document.getElementById("print_style_custom").style.display = 'none';
112
+ }
113
+ }
114
+ }
115
+ function print_default_templates(template) {
116
+ var default_template;
117
+ switch(template) {
118
+ case 'html':
119
+ default_template = '<a href="%PRINT_URL%" rel="nofollow" title="%PRINT_TEXT%">%PRINT_TEXT%</a>';
120
+ break;
121
+ case 'disclaimer':
122
+ default_template = '<?php printf(__('Copyright &copy; %s %s. All rights reserved.', 'wp-print'), date('Y'), get_option('blogname')); ?>';
123
+ break;
124
+ }
125
+ document.getElementById("print_template_" + template).value = default_template;
126
+ }
127
+ /* ]]> */
128
+ </script>
129
+ <?php if(!empty($text)) { echo '<!-- Last Action --><div id="message" class="updated fade"><p>'.$text.'</p></div>'; } ?>
130
+ <form method="post" action="<?php echo $_SERVER['REQUEST_URI']; ?>">
131
+ <div class="wrap">
132
+ <h2><?php _e('Print Options', 'wp-print'); ?></h2>
133
+ <h3><?php _e('Print Styles', 'wp-print'); ?></h3>
134
+ <table class="form-table">
135
+ <tr>
136
+ <th scope="row" valign="top"><?php _e('Print Text Link For Post', 'wp-print'); ?></th>
137
+ <td>
138
+ <input type="text" name="print_post_text" value="<?php echo stripslashes($print_options['post_text']); ?>" size="30" />
139
+ </td>
140
+ </tr>
141
+ <tr>
142
+ <th scope="row" valign="top"><?php _e('Print Text Link For Page', 'wp-print'); ?></th>
143
+ <td>
144
+ <input type="text" name="print_page_text" value="<?php echo stripslashes($print_options['page_text']); ?>" size="30" />
145
+ </td>
146
+ </tr>
147
+ <tr>
148
+ <th scope="row" valign="top"><?php _e('Print Icon', 'wp-print'); ?></th>
149
+ <td>
150
+ <?php
151
+ $print_icon = $print_options['print_icon'];
152
+ $print_icon_url = get_option('siteurl').'/wp-content/plugins/wp-print/images';
153
+ $print_icon_path = ABSPATH.'/wp-content/plugins/wp-print/images';
154
+ if($handle = @opendir($print_icon_path)) {
155
+ while (false !== ($filename = readdir($handle))) {
156
+ if ($filename != '.' && $filename != '..') {
157
+ if(is_file($print_icon_path.'/'.$filename)) {
158
+ if($print_icon == $filename) {
159
+ echo '<input type="radio" name="print_icon" value="'.$filename.'" checked="checked" />'."\n";
160
+ } else {
161
+ echo '<input type="radio" name="print_icon" value="'.$filename.'" />'."\n";
162
+ }
163
+ echo '&nbsp;&nbsp;&nbsp;';
164
+ echo '<img src="'.$print_icon_url.'/'.$filename.'" alt="'.$filename.'" />'."\n";
165
+ echo '&nbsp;&nbsp;&nbsp;('.$filename.')';
166
+ echo '<br /><br />'."\n";
167
+ }
168
+ }
169
+ }
170
+ closedir($handle);
171
+ }
172
+ ?>
173
+ </td>
174
+ </tr>
175
+ <tr>
176
+ <th scope="row" valign="top"><?php _e('Print Text Link Style', 'wp-print'); ?></th>
177
+ <td>
178
+ <select name="print_style" id="print_style" size="1" onchange="check_print_style();">
179
+ <option value="1"<?php selected('1', $print_options['print_style']); ?>><?php _e('Print Icon With Text Link', 'wp-print'); ?></option>
180
+ <option value="2"<?php selected('2', $print_options['print_style']); ?>><?php _e('Print Icon Only', 'wp-print'); ?></option>
181
+ <option value="3"<?php selected('3', $print_options['print_style']); ?>><?php _e('Print Text Link Only', 'wp-print'); ?></option>
182
+ <option value="4"<?php selected('4', $print_options['print_style']); ?>><?php _e('Custom', 'wp-print'); ?></option>
183
+ </select>
184
+ <div id="print_style_custom" style="display: <?php if(intval($print_options['print_style']) == 4) { echo 'block'; } else { echo 'none'; } ?>; margin-top: 20px;">
185
+ <textarea rows="2" cols="80" name="print_html" id="print_template_html"><?php echo htmlspecialchars(stripslashes($print_options['print_html'])); ?></textarea><br />
186
+ <?php _e('HTML is allowed.', 'wp-print'); ?><br />
187
+ %PRINT_URL% - <?php _e('URL to the printable post/page.', 'wp-print'); ?><br />
188
+ %PRINT_TEXT% - <?php _e('Print text link of the post/page that you have typed in above.', 'wp-print'); ?><br />
189
+ %PRINT_ICON_URL% - <?php _e('URL to the print icon you have chosen above.', 'wp-print'); ?><br />
190
+ <input type="button" name="RestoreDefault" value="<?php _e('Restore Default Template', 'wp-print'); ?>" onclick="print_default_templates('html');" class="button" />
191
+ </div>
192
+ </td>
193
+ </tr>
194
+ </table>
195
+ <h3><?php _e('Print Options', 'wp-print'); ?></h3>
196
+ <table class="form-table">
197
+ <tr>
198
+ <th scope="row" valign="top"><?php _e('Print Comments?', 'wp-print'); ?></th>
199
+ <td>
200
+ <select name="print_comments" size="1">
201
+ <option value="1"<?php selected('1', $print_options['comments']); ?>><?php _e('Yes', 'wp-print'); ?></option>
202
+ <option value="0"<?php selected('0', $print_options['comments']); ?>><?php _e('No', 'wp-print'); ?></option>
203
+ </select>
204
+ </td>
205
+ </tr>
206
+ <tr>
207
+ <th scope="row" valign="top"><?php _e('Print Links?', 'wp-print'); ?></th>
208
+ <td>
209
+ <select name="print_links" size="1">
210
+ <option value="1"<?php selected('1', $print_options['links']); ?>><?php _e('Yes', 'wp-print'); ?></option>
211
+ <option value="0"<?php selected('0', $print_options['links']); ?>><?php _e('No', 'wp-print'); ?></option>
212
+ </select>
213
+ </td>
214
+ </tr>
215
+ <tr>
216
+ <th scope="row" valign="top"><?php _e('Print Images?', 'wp-print'); ?></th>
217
+ <td>
218
+ <select name="print_images" size="1">
219
+ <option value="1"<?php selected('1', $print_options['images']); ?>><?php _e('Yes', 'wp-print'); ?></option>
220
+ <option value="0"<?php selected('0', $print_options['images']); ?>><?php _e('No', 'wp-print'); ?></option>
221
+ </select>
222
+ </td>
223
+ </tr>
224
+ <tr>
225
+ <th scope="row" valign="top"><?php _e('Print Videos?', 'wp-print'); ?></th>
226
+ <td>
227
+ <select name="print_videos" size="1">
228
+ <option value="1"<?php selected('1', $print_options['videos']); ?>><?php _e('Yes', 'wp-print'); ?></option>
229
+ <option value="0"<?php selected('0', $print_options['videos']); ?>><?php _e('No', 'wp-print'); ?></option>
230
+ </select>
231
+ </td>
232
+ </tr>
233
+ <tr>
234
+ <th scope="row" valign="top"><?php _e('Text Direction?', 'wp-print'); ?></th>
235
+ <td>
236
+ <select name="print_text_direction" size="1">
237
+ <option value="ltr"<?php selected('ltr', $print_options['text_direction']); ?>><?php _e('Left To Right', 'wp-print'); ?></option>
238
+ <option value="rtl"<?php selected('rtl', $print_options['text_direction']); ?>><?php _e('Right To Left', 'wp-print'); ?></option>
239
+ </select>
240
+ </td>
241
+ </tr>
242
+ <tr>
243
+ <th scope="row" valign="top">
244
+ <?php _e('Disclaimer/Copyright Text?', 'wp-print'); ?>
245
+ <br /><br />
246
+ <input type="button" name="RestoreDefault" value="<?php _e('Restore Default Template', 'wp-print'); ?>" onclick="print_default_templates('disclaimer');" class="button" />
247
+ </th>
248
+ <td>
249
+ <textarea rows="2" cols="80" name="print_disclaimer" id="print_template_disclaimer"><?php echo htmlspecialchars(stripslashes($print_options['disclaimer'])); ?></textarea><br /><?php _e('HTML is allowed.', 'wp-print'); ?><br />
250
+ </td>
251
+ </tr>
252
+ </table>
253
+ <p class="submit">
254
+ <input type="submit" name="Submit" class="button" value="<?php _e('Save Changes', 'wp-print'); ?>" />
255
+ </p>
256
+ </div>
257
+ </form>
258
+ <p>&nbsp;</p>
259
+
260
+ <!-- Uninstall WP-Print -->
261
+ <form method="post" action="<?php echo $_SERVER['REQUEST_URI']; ?>">
262
+ <div class="wrap">
263
+ <h2><?php _e('Uninstall WP-Print', 'wp-print'); ?></h2>
264
+ <p style="text-align: left;">
265
+ <?php _e('Deactivating WP-Print plugin does not remove any data that may have been created, such as the print options. To completely remove this plugin, you can uninstall it here.', 'wp-print'); ?>
266
+ </p>
267
+ <p style="text-align: left; color: red">
268
+ <strong><?php _e('WARNING:', 'wp-print'); ?></strong><br />
269
+ <?php _e('Once uninstalled, this cannot be undone. You should use a Database Backup plugin of WordPress to back up all the data first.', 'wp-print'); ?>
270
+ </p>
271
+ <p style="text-align: left; color: red">
272
+ <strong><?php _e('The following WordPress Options will be DELETED:', 'wp-print'); ?></strong><br />
273
+ </p>
274
+ <table class="widefat">
275
+ <thead>
276
+ <tr>
277
+ <th><?php _e('WordPress Options', 'wp-print'); ?></th>
278
+ </tr>
279
+ </thead>
280
+ <tr>
281
+ <td valign="top">
282
+ <ol>
283
+ <?php
284
+ foreach($print_settings as $settings) {
285
+ echo '<li>'.$settings.'</li>'."\n";
286
+ }
287
+ ?>
288
+ </ol>
289
+ </td>
290
+ </tr>
291
+ </table>
292
+ <p>&nbsp;</p>
293
+ <p style="text-align: center;">
294
+ <input type="checkbox" name="uninstall_print_yes" value="yes" />&nbsp;<?php _e('Yes', 'wp-print'); ?><br /><br />
295
+ <input type="submit" name="do" value="<?php _e('UNINSTALL WP-Print', 'wp-print'); ?>" class="button" onclick="return confirm('<?php _e('You Are About To Uninstall WP-Print From WordPress.\nThis Action Is Not Reversible.\n\n Choose [Cancel] To Stop, [OK] To Uninstall.', 'wp-print'); ?>')" />
296
+ </p>
297
+ </div>
298
+ </form>
299
+ <?php
300
+ } // End switch($mode)
301
+ ?>
print/wp-print.php → print-posts.php RENAMED
@@ -2,8 +2,8 @@
2
  /*
3
  +----------------------------------------------------------------+
4
  | |
5
- | WordPress 2.1 Plugin: WP-Print 2.20 |
6
- | Copyright (c) 2007 Lester "GaMerZ" Chan |
7
  | |
8
  | File Written By: |
9
  | - Lester "GaMerZ" Chan |
@@ -11,7 +11,7 @@
11
  | |
12
  | File Information: |
13
  | - Printer Friendly Page |
14
- | - wp-print.php |
15
  | |
16
  +----------------------------------------------------------------+
17
  */
@@ -29,6 +29,16 @@ add_filter('comments_template', 'print_template_comments');
29
 
30
  ### Print Options
31
  $print_options = get_option('print_options');
 
 
 
 
 
 
 
 
 
 
32
  ?>
33
  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
34
  <html xmlns="http://www.w3.org/1999/xhtml">
@@ -36,7 +46,21 @@ $print_options = get_option('print_options');
36
  <title><?php bloginfo('name'); ?> <?php wp_title(); ?></title>
37
  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
38
  <meta name="Robots" content="noindex, nofollow" />
39
- <link rel="stylesheet" href="<?php bloginfo('wpurl'); ?>/wp-content/plugins/print/wp-print-css.css" type="text/css" media="screen, print" />
 
 
 
 
 
 
 
 
 
 
 
 
 
 
40
  </head>
41
  <body>
42
  <p style="text-align: center;"><strong>- <?php bloginfo('name'); ?> - <?php bloginfo('url')?> -</strong></p>
@@ -52,14 +76,14 @@ $print_options = get_option('print_options');
52
  <?php if(print_can('comments')): ?>
53
  <?php comments_template(); ?>
54
  <?php endif; ?>
55
- <p style="text-align: left;"><?php _e('Article printed from', 'wp-print'); ?> <?php bloginfo('name'); ?>: <strong><?php bloginfo('url'); ?></strong></p>
56
- <p style="text-align: left;"><?php _e('URL to article', 'wp-print'); ?>: <strong><?php the_permalink(); ?></strong></p>
57
  <?php if(print_can('links')): ?>
58
- <p style="text-align: left;"><?php print_links(); ?></p>
59
  <?php endif; ?>
60
- <p style="text-align: right;" id="print-link"><?php _e('Click', 'wp-print'); ?> <a href="#Print" onclick="window.print(); return false;" title="<?php _e('Click here to print.', 'wp-print'); ?>"><?php _e('here', 'wp-print'); ?></a> <?php _e('to print.', 'wp-print'); ?></p>
61
  <?php else: ?>
62
- <p style="text-align: left;"><?php _e('No posts matched your criteria.', 'wp-print'); ?></p>
63
  <?php endif; ?>
64
  </div>
65
  </center>
2
  /*
3
  +----------------------------------------------------------------+
4
  | |
5
+ | WordPress 2.5 Plugin: WP-Print 2.30 |
6
+ | Copyright (c) 2008 Lester "GaMerZ" Chan |
7
  | |
8
  | File Written By: |
9
  | - Lester "GaMerZ" Chan |
11
  | |
12
  | File Information: |
13
  | - Printer Friendly Page |
14
+ | - wp-content/plugins/wp-print/print-posts.php |
15
  | |
16
  +----------------------------------------------------------------+
17
  */
29
 
30
  ### Print Options
31
  $print_options = get_option('print_options');
32
+
33
+ ### Determine Text Direction
34
+ $text_direction = 'ltr';
35
+ $text_align = 'left';
36
+ $text_align_opposite = 'right';
37
+ if($print_options['text_direction'] == 'rtl') {
38
+ $text_direction = 'rtl';
39
+ $text_align = 'right';
40
+ $text_align_opposite = 'left';
41
+ }
42
  ?>
43
  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
44
  <html xmlns="http://www.w3.org/1999/xhtml">
46
  <title><?php bloginfo('name'); ?> <?php wp_title(); ?></title>
47
  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
48
  <meta name="Robots" content="noindex, nofollow" />
49
+ <style type="text/css" media="screen, print">
50
+ BODY {
51
+ direction: <?php echo $text_direction; ?>;
52
+ text-align: <?php echo $text_align; ?>;
53
+ }
54
+ #Outline {
55
+ direction: <?php echo $text_direction; ?>;
56
+ text-align: <?php echo $text_align; ?>;
57
+ }
58
+ </style>
59
+ <?php if(@file_exists(TEMPLATEPATH.'/print-css.css')): ?>
60
+ <link rel="stylesheet" href="<?php echo get_stylesheet_directory_uri(); ?>/print-css.css" type="text/css" media="screen, print" />
61
+ <?php else: ?>
62
+ <link rel="stylesheet" href="<?php bloginfo('wpurl'); ?>/wp-content/plugins/wp-print/print-css.css" type="text/css" media="screen, print" />
63
+ <?php endif; ?>
64
  </head>
65
  <body>
66
  <p style="text-align: center;"><strong>- <?php bloginfo('name'); ?> - <?php bloginfo('url')?> -</strong></p>
76
  <?php if(print_can('comments')): ?>
77
  <?php comments_template(); ?>
78
  <?php endif; ?>
79
+ <p style="text-align: <?php echo $text_direction; ?>;"><?php _e('Article printed from', 'wp-print'); ?> <?php bloginfo('name'); ?>: <strong><?php bloginfo('url'); ?></strong></p>
80
+ <p style="text-align: <?php echo $text_direction; ?>;"><?php _e('URL to article', 'wp-print'); ?>: <strong><?php the_permalink(); ?></strong></p>
81
  <?php if(print_can('links')): ?>
82
+ <p style="text-align: <?php echo $text_direction; ?>;"><?php print_links(); ?></p>
83
  <?php endif; ?>
84
+ <p style="text-align: <?php echo $text_align_opposite; ?>;" id="print-link"><?php _e('Click', 'wp-print'); ?> <a href="#Print" onclick="window.print(); return false;" title="<?php _e('Click here to print.', 'wp-print'); ?>"><?php _e('here', 'wp-print'); ?></a> <?php _e('to print.', 'wp-print'); ?></p>
85
  <?php else: ?>
86
+ <p style="text-align: <?php echo $text_direction; ?>;"><?php _e('No posts matched your criteria.', 'wp-print'); ?></p>
87
  <?php endif; ?>
88
  </div>
89
  </center>
print/print-options.php DELETED
@@ -1,283 +0,0 @@
1
- <?php
2
- /*
3
- +----------------------------------------------------------------+
4
- | |
5
- | WordPress 2.1 Plugin: WP-Print 2.20 |
6
- | Copyright (c) 2007 Lester "GaMerZ" Chan |
7
- | |
8
- | File Written By: |
9
- | - Lester "GaMerZ" Chan |
10
- | - http://lesterchan.net |
11
- | |
12
- | File Information: |
13
- | - Print Options Page |
14
- | - wp-content/plugins/print/print-options.php |
15
- | |
16
- +----------------------------------------------------------------+
17
- */
18
-
19
-
20
- ### Variables Variables Variables
21
- $base_name = plugin_basename('print/print-options.php');
22
- $base_page = 'admin.php?page='.$base_name;
23
- $id = intval($_GET['id']);
24
- $mode = trim($_GET['mode']);
25
- $print_settings = array('print_options');
26
-
27
-
28
- ### Form Processing
29
- if(!empty($_POST['do'])) {
30
- // Decide What To Do
31
- switch($_POST['do']) {
32
- case __('Update Options', 'wp-print'):
33
- $print_options = array();
34
- $print_options['post_text'] = addslashes(trim($_POST['print_post_text']));
35
- $print_options['page_text'] = addslashes(trim($_POST['print_page_text']));
36
- $print_options['print_icon'] = trim($_POST['print_icon']);
37
- $print_options['print_style'] = intval($_POST['print_style']);
38
- $print_options['print_html'] = trim($_POST['print_html']);
39
- $print_options['comments'] = intval($_POST['print_comments']);
40
- $print_options['links'] = intval($_POST['print_links']);
41
- $print_options['images'] = intval($_POST['print_images']);
42
- $print_options['disclaimer'] = trim($_POST['print_disclaimer']);
43
- $update_print_queries = array();
44
- $update_print_text = array();
45
- $update_print_queries[] = update_option('print_options', $print_options);
46
- $update_print_text[] = __('Print Options', 'wp-print');
47
- $i=0;
48
- $text = '';
49
- foreach($update_print_queries as $update_print_query) {
50
- if($update_print_query) {
51
- $text .= '<font color="green">'.$update_print_text[$i].' '.__('Updated', 'wp-print').'</font><br />';
52
- }
53
- $i++;
54
- }
55
- if(empty($text)) {
56
- $text = '<font color="red">'.__('No Print Option Updated', 'wp-print').'</font>';
57
- }
58
- break;
59
- // Uninstall WP-Print
60
- case __('UNINSTALL WP-Print', 'wp-print') :
61
- if(trim($_POST['uninstall_print_yes']) == 'yes') {
62
- echo '<div id="message" class="updated fade">';
63
- echo '<p>';
64
- foreach($print_settings as $setting) {
65
- $delete_setting = delete_option($setting);
66
- if($delete_setting) {
67
- echo '<font color="green">';
68
- printf(__('Setting Key \'%s\' has been deleted.', 'wp-print'), "<strong><em>{$setting}</em></strong>");
69
- echo '</font><br />';
70
- } else {
71
- echo '<font color="red">';
72
- printf(__('Error deleting Setting Key \'%s\'.', 'wp-print'), "<strong><em>{$setting}</em></strong>");
73
- echo '</font><br />';
74
- }
75
- }
76
- echo '</p>';
77
- echo '</div>';
78
- $mode = 'end-UNINSTALL';
79
- }
80
- break;
81
- }
82
- }
83
-
84
-
85
- ### Determines Which Mode It Is
86
- switch($mode) {
87
- // Deactivating WP-Print
88
- case 'end-UNINSTALL':
89
- $deactivate_url = 'plugins.php?action=deactivate&amp;plugin=print/print.php';
90
- if(function_exists('wp_nonce_url')) {
91
- $deactivate_url = wp_nonce_url($deactivate_url, 'deactivate-plugin_print/print.php');
92
- }
93
- echo '<div class="wrap">';
94
- echo '<h2>'.__('Uninstall WP-Print', 'wp-print').'</h2>';
95
- echo '<p><strong>'.sprintf(__('<a href="%s">Click Here</a> To Finish The Uninstallation And WP-Print Will Be Deactivated Automatically.', 'wp-print'), $deactivate_url).'</strong></p>';
96
- echo '</div>';
97
- break;
98
- // Main Page
99
- default:
100
- $print_options = get_option('print_options');
101
- ?>
102
- <script type="text/javascript">
103
- /* <![CDATA[*/
104
- function check_print_style() {
105
- print_style_options = document.getElementById("print_style").value;
106
- if (print_style_options == 4) {
107
- document.getElementById("print_style_custom").style.display = 'block';
108
- } else {
109
- if(document.getElementById("print_style_custom").style.display == 'block') {
110
- document.getElementById("print_style_custom").style.display = 'none';
111
- }
112
- }
113
- }
114
- function print_default_templates(template) {
115
- var default_template;
116
- switch(template) {
117
- case 'html':
118
- default_template = '<a href="%PRINT_URL%" rel="nofollow" title="%PRINT_TEXT%">%PRINT_TEXT%</a>';
119
- break;
120
- case 'disclaimer':
121
- default_template = '<?php printf(__('Copyright &copy; %s %s. All rights reserved.', 'wp-print'), date('Y'), get_option('blogname')); ?>';
122
- break;
123
- }
124
- document.getElementById("print_template_" + template).value = default_template;
125
- }
126
- /* ]]> */
127
- </script>
128
- <?php if(!empty($text)) { echo '<!-- Last Action --><div id="message" class="updated fade"><p>'.$text.'</p></div>'; } ?>
129
- <form method="post" action="<?php echo $_SERVER['REQUEST_URI']; ?>">
130
- <div class="wrap">
131
- <h2><?php _e('Print Options', 'wp-print'); ?></h2>
132
- <fieldset class="options">
133
- <legend><?php _e('Print Styles', 'wp-print'); ?></legend>
134
- <table width="100%" border="0" cellspacing="3" cellpadding="3">
135
- <tr valign="top">
136
- <th align="left" width="30%"><?php _e('Print Text Link For Post', 'wp-print'); ?></th>
137
- <td align="left">
138
- <input type="text" name="print_post_text" value="<?php echo stripslashes($print_options['post_text']); ?>" size="30" />
139
- </td>
140
- </tr>
141
- <tr valign="top">
142
- <th align="left" width="30%"><?php _e('Print Text Link For Page', 'wp-print'); ?></th>
143
- <td align="left">
144
- <input type="text" name="print_page_text" value="<?php echo stripslashes($print_options['page_text']); ?>" size="30" />
145
- </td>
146
- </tr>
147
- <tr valign="top">
148
- <th align="left" width="30%"><?php _e('Print Icon', 'wp-print'); ?></th>
149
- <td align="left">
150
- <?php
151
- $print_icon = $print_options['print_icon'];
152
- $print_icon_url = get_option('siteurl').'/wp-content/plugins/print/images';
153
- $print_icon_path = ABSPATH.'/wp-content/plugins/print/images';
154
- if($handle = @opendir($print_icon_path)) {
155
- while (false !== ($filename = readdir($handle))) {
156
- if ($filename != '.' && $filename != '..') {
157
- if(is_file($print_icon_path.'/'.$filename)) {
158
- if($print_icon == $filename) {
159
- echo '<input type="radio" name="print_icon" value="'.$filename.'" checked="checked" />'."\n";
160
- } else {
161
- echo '<input type="radio" name="print_icon" value="'.$filename.'" />'."\n";
162
- }
163
- echo '&nbsp;&nbsp;&nbsp;';
164
- echo '<img src="'.$print_icon_url.'/'.$filename.'" alt="'.$filename.'" />'."\n";
165
- echo '&nbsp;&nbsp;&nbsp;('.$filename.')';
166
- echo '<br /><br />'."\n";
167
- }
168
- }
169
- }
170
- closedir($handle);
171
- }
172
- ?>
173
- </td>
174
- </tr>
175
- <tr valign="top">
176
- <th align="left" width="30%"><?php _e('Print Text Link Style', 'wp-print'); ?></th>
177
- <td align="left">
178
- <select name="print_style" id="print_style" size="1" onchange="check_print_style();">
179
- <option value="1"<?php selected('1', $print_options['print_style']); ?>><?php _e('Print Icon With Text Link', 'wp-print'); ?></option>
180
- <option value="2"<?php selected('2', $print_options['print_style']); ?>><?php _e('Print Icon Only', 'wp-print'); ?></option>
181
- <option value="3"<?php selected('3', $print_options['print_style']); ?>><?php _e('Print Text Link Only', 'wp-print'); ?></option>
182
- <option value="4"<?php selected('4', $print_options['print_style']); ?>><?php _e('Custom', 'wp-print'); ?></option>
183
- </select>
184
- <div id="print_style_custom" style="display: <?php if(intval($print_options['print_style']) == 4) { echo 'block'; } else { echo 'none'; } ?>; margin-top: 20px;">
185
- <textarea rows="2" cols="80" name="print_html" id="print_template_html"><?php echo htmlspecialchars(stripslashes($print_options['print_html'])); ?></textarea><br />
186
- <?php _e('HTML is allowed.', 'wp-print'); ?><br />
187
- %PRINT_URL% - <?php _e('URL to the printable post/page.', 'wp-print'); ?><br />
188
- %PRINT_TEXT% - <?php _e('Print text link of the post/page that you have typed in above.', 'wp-print'); ?><br />
189
- %PRINT_ICON_URL% - <?php _e('URL to the print icon you have chosen above.', 'wp-print'); ?><br />
190
- <input type="button" name="RestoreDefault" value="<?php _e('Restore Default Template', 'wp-print'); ?>" onclick="print_default_templates('html');" class="button" />
191
- </div>
192
- </td>
193
- </tr>
194
- </table>
195
- </fieldset>
196
- <fieldset class="options">
197
- <legend><?php _e('Print Options', 'wp-print'); ?></legend>
198
- <table width="100%" border="0" cellspacing="3" cellpadding="3">
199
- <tr valign="top">
200
- <th align="left" width="30%"><?php _e('Print Comments?', 'wp-print'); ?></th>
201
- <td align="left">
202
- <select name="print_comments" size="1">
203
- <option value="1"<?php selected('1', $print_options['comments']); ?>><?php _e('Yes', 'wp-print'); ?></option>
204
- <option value="0"<?php selected('0', $print_options['comments']); ?>><?php _e('No', 'wp-print'); ?></option>
205
- </select>
206
- </td>
207
- </tr>
208
- <tr valign="top">
209
- <th align="left" width="30%"><?php _e('Print Links?', 'wp-print'); ?></th>
210
- <td align="left">
211
- <select name="print_links" size="1">
212
- <option value="1"<?php selected('1', $print_options['links']); ?>><?php _e('Yes', 'wp-print'); ?></option>
213
- <option value="0"<?php selected('0', $print_options['links']); ?>><?php _e('No', 'wp-print'); ?></option>
214
- </select>
215
- </td>
216
- </tr>
217
- <tr valign="top">
218
- <th align="left" width="30%"><?php _e('Print Images?', 'wp-print'); ?></th>
219
- <td align="left">
220
- <select name="print_images" size="1">
221
- <option value="1"<?php selected('1', $print_options['images']); ?>><?php _e('Yes', 'wp-print'); ?></option>
222
- <option value="0"<?php selected('0', $print_options['images']); ?>><?php _e('No', 'wp-print'); ?></option>
223
- </select>
224
- </td>
225
- </tr>
226
- <tr valign="top">
227
- <th align="left" width="30%">
228
- <?php _e('Disclaimer/Copyright Text?', 'wp-print'); ?>
229
- <br /><br />
230
- <input type="button" name="RestoreDefault" value="<?php _e('Restore Default Template', 'wp-print'); ?>" onclick="print_default_templates('disclaimer');" class="button" />
231
- </th>
232
- <td align="left">
233
- <textarea rows="2" cols="80" name="print_disclaimer" id="print_template_disclaimer"><?php echo htmlspecialchars(stripslashes($print_options['disclaimer'])); ?></textarea><br /><?php _e('HTML is allowed.', 'wp-print'); ?><br />
234
- </td>
235
- </tr>
236
- </table>
237
- </fieldset>
238
- <div align="center">
239
- <input type="submit" name="do" class="button" value="<?php _e('Update Options', 'wp-print'); ?>" />&nbsp;&nbsp;<input type="button" name="cancel" value="<?php _e('Cancel', 'wp-print'); ?>" class="button" onclick="javascript:history.go(-1)" />
240
- </div>
241
- </div>
242
- </form>
243
-
244
- <!-- Uninstall WP-Print -->
245
- <form method="post" action="<?php echo $_SERVER['REQUEST_URI']; ?>">
246
- <div class="wrap">
247
- <h2><?php _e('Uninstall WP-Print', 'wp-print'); ?></h2>
248
- <p style="text-align: left;">
249
- <?php _e('Deactivating WP-Print plugin does not remove any data that may have been created, such as the print options. To completely remove this plugin, you can uninstall it here.', 'wp-print'); ?>
250
- </p>
251
- <p style="text-align: left; color: red">
252
- <strong><?php _e('WARNING:', 'wp-print'); ?></strong><br />
253
- <?php _e('Once uninstalled, this cannot be undone. You should use a Database Backup plugin of WordPress to back up all the data first.', 'wp-print'); ?>
254
- </p>
255
- <p style="text-align: left; color: red">
256
- <strong><?php _e('The following WordPress Options will be DELETED:', 'wp-print'); ?></strong><br />
257
- </p>
258
- <table width="70%" border="0" cellspacing="3" cellpadding="3">
259
- <tr class="thead">
260
- <td align="center"><strong><?php _e('WordPress Options', 'wp-print'); ?></strong></td>
261
- </tr>
262
- <tr>
263
- <td valign="top" style="background-color: #eee;">
264
- <ol>
265
- <?php
266
- foreach($print_settings as $settings) {
267
- echo '<li>'.$settings.'</li>'."\n";
268
- }
269
- ?>
270
- </ol>
271
- </td>
272
- </tr>
273
- </table>
274
- <p>&nbsp;</p>
275
- <p style="text-align: center;">
276
- <input type="checkbox" name="uninstall_print_yes" value="yes" />&nbsp;<?php _e('Yes', 'wp-print'); ?><br /><br />
277
- <input type="submit" name="do" value="<?php _e('UNINSTALL WP-Print', 'wp-print'); ?>" class="button" onclick="return confirm('<?php _e('You Are About To Uninstall WP-Print From WordPress.\nThis Action Is Not Reversible.\n\n Choose [Cancel] To Stop, [OK] To Uninstall.', 'wp-print'); ?>')" />
278
- </p>
279
- </div>
280
- </form>
281
- <?php
282
- } // End switch($mode)
283
- ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
print/wp-print.mo DELETED
Binary file
readme.html CHANGED
@@ -2,7 +2,7 @@
2
  <html>
3
  <head>
4
  <meta http-equiv="content-type" content="text/html; charset=utf-8" />
5
- <title>WP-Print 2.20 Readme</title>
6
  <style type="text/css" media="screen">
7
  /* Default Style */
8
  BODY {
@@ -203,7 +203,7 @@
203
  <body>
204
  <div id="Container">
205
  <!-- Title -->
206
- <div id="Title">WP-Print 2.20&nbsp;&nbsp;&nbsp;<span style="color: #aaaaaa;">Readme</span></div>
207
 
208
  <!-- Tabs -->
209
  <ul id="Tabs">
@@ -224,15 +224,6 @@
224
  <strong>Author:</strong><br />
225
  <strong>&raquo;</strong> Lester 'GaMerZ' Chan
226
  </p>
227
- <p>
228
- <strong>EMail:</strong><br />
229
- <strong>&raquo;</strong>
230
- <script type="text/javascript">
231
- /* <![CDATA[*/
232
- document.write(' <a href="mailto:gamerz84@hotmail.com?Subject=WP-Print%202.20%20Support" title="EMail To gamerz84@hotmail.com">gamerz84@hotmail.com</a>');
233
- /* ]]> */
234
- </script>
235
- </p>
236
  <p>
237
  <strong>Website:</strong><br />
238
  <strong>&raquo;</strong> <a href="http://lesterchan.net/" title="http://lesterchan.net/">http://lesterchan.net/</a>
@@ -243,9 +234,10 @@
243
  </p>
244
  <p>
245
  <strong>Download:</strong><br />
246
- <strong>&raquo;</strong> <a href="http://lesterchan.net/others/downloads.php?id=12" title="http://lesterchan.net/others/downloads.php?id=12">WP-Print 2.20 For WordPress 2.1.x And Above</a><br />
247
- <strong>&raquo;</strong> <a href="http://lesterchan.net/others/downloads/wp-print206.zip" title="http://lesterchan.net/others/downloads/wp-print206.zip">WP-Print 2.06 For WordPress 2.0.x</a><br />
248
- <strong>&raquo;</strong> <a href="http://lesterchan.net/others/downloads/wp-print200a.zip" title="http://lesterchan.net/others/downloads/wp-print200a.zip">WP-Print 2.00a For WordPress 1.5.2</a>
 
249
  </p>
250
  <p>
251
  <strong>Screenshots:</strong><br />
@@ -268,20 +260,19 @@
268
  <strong>&raquo;</strong> <a href="http://forums.lesterchan.net/index.php?board=18.0" title="http://forums.lesterchan.net/index.php?board=18.0">http://forums.lesterchan.net/index.php?board=18.0</a>
269
  </p>
270
  <p>
271
- <strong>Updated:</strong><br />
272
- <strong>&raquo;</strong> 1st June 2007
273
  </p>
274
  <p>
275
  <strong>Note:</strong><br />
276
  <strong>&raquo;</strong> The <strong>Changelog</strong>, <strong>Installation</strong>, <strong>Upgrade</strong>, <strong>Usage</strong> Tab at the top of the page.<br />
277
- <strong>&raquo;</strong> Please go to '<strong>WP-Admin -> Options -> Print</strong>' to configure the print text link style.
278
  </p>
279
  <p>
280
  <strong>Donations:</strong><br />
281
  <strong>&raquo;</strong> I spent most of my free time creating, updating, maintaining and supporting these plugins, if you really love my plugins and could spare me a couple of bucks as my school allowance, I will really appericiate it. If not feel free to use it without any obligations. Thank You. My Paypal account is
282
  <script type="text/javascript">
283
  /* <![CDATA[*/
284
- document.write(' <strong>gamerz84@hotmail.com</strong>.');
285
  /* ]]> */
286
  </script>
287
  </p>
@@ -291,6 +282,24 @@
291
  <div id="Changelog" style="display: none;">
292
  <div class="SubTitle">&raquo; Changelog</div>
293
  <ul>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
294
  <li>
295
  <strong>Version 2.20 (01-10-2007)</strong>
296
  <ul>
@@ -400,13 +409,13 @@
400
  </li>
401
  <li>
402
  Put:
403
- <blockquote>Folder: print</blockquote>
404
  </li>
405
  <li>
406
  <strong>Activate</strong> WP-Print Plugin
407
  </li>
408
  <li>
409
- You Need To Re-Generate The Permalink (<strong>WP-Admin -> Options -> Permalinks -> Update Permalink Structure</strong>)
410
  </li>
411
  <li>
412
  Refer To <strong>Usage</strong> For Further Instructions
@@ -417,7 +426,7 @@
417
  <!-- Upgrade Instructions -->
418
  <div id="Upgrade" style="display: none;">
419
  <div class="SubTitle">&raquo; Upgrade Instructions</div>
420
- <div class="SubSubTitle">From v1.0x To v2.20</div>
421
  <ol>
422
  <li>
423
  <strong>Deactivate</strong> WP-Print Plugin
@@ -427,20 +436,19 @@
427
  </li>
428
  <li>
429
  Put/Overwrite:
430
- <blockquote>Folder: print</blockquote>
431
  </li>
432
  <li>
433
- Delete these files if exists:
434
  <blockquote>
435
- File: wp-print.php<br />
436
- File: wp-content/plugins/print.php
437
  </blockquote>
438
  </li>
439
  <li>
440
  <strong>Activate</strong> WP-Print Plugin
441
  </li>
442
  <li>
443
- You Need To Re-Generate The Permalink (<strong>WP-Admin -> Options -> Permalinks -> Update Permalink Structure</strong>)
444
  </li>
445
  <li>
446
  Refer To <strong>Usage</strong> For Further Instructions
@@ -469,14 +477,28 @@
469
  &lt;?php if(function_exists('wp_print')) { print_link(); } ?&gt;
470
  </blockquote>
471
  <p>If you DO NOT want the print link to appear in every post/page, DO NOT use the code above. Just type in <strong>[print_link]</strong> into the selected post/page content and it will embed the print link into that post/page only.</p>
 
 
 
 
472
  </li>
473
  <li>
474
- Go to <strong>'WP-Admin -> Options -> Print'</strong> to configure the style of the print text link.
475
  </li>
476
  </ol>
 
 
 
 
 
 
 
 
 
 
477
  </div>
478
  </div>
479
  </div>
480
- <p id="Copyright">WP-Print 2.20<br />Copyright &copy; 2007 Lester 'GaMerZ' Chan. All Rights Reserved.</p>
481
  </body>
482
  </html>
2
  <html>
3
  <head>
4
  <meta http-equiv="content-type" content="text/html; charset=utf-8" />
5
+ <title>WP-Print 2.30 Readme</title>
6
  <style type="text/css" media="screen">
7
  /* Default Style */
8
  BODY {
203
  <body>
204
  <div id="Container">
205
  <!-- Title -->
206
+ <div id="Title">WP-Print 2.30&nbsp;&nbsp;&nbsp;<span style="color: #aaaaaa;">Readme</span></div>
207
 
208
  <!-- Tabs -->
209
  <ul id="Tabs">
224
  <strong>Author:</strong><br />
225
  <strong>&raquo;</strong> Lester 'GaMerZ' Chan
226
  </p>
 
 
 
 
 
 
 
 
 
227
  <p>
228
  <strong>Website:</strong><br />
229
  <strong>&raquo;</strong> <a href="http://lesterchan.net/" title="http://lesterchan.net/">http://lesterchan.net/</a>
234
  </p>
235
  <p>
236
  <strong>Download:</strong><br />
237
+ <strong>&raquo;</strong> <a href="http://downloads.wordpress.org/plugin/wp-print.2.30.zip" title="http://downloads.wordpress.org/plugin/wp-print.2.30.zip">WP-Print 2.30 For WordPress 2.5.x</a><br />
238
+ <strong>&raquo;</strong> <a href="http://downloads.wordpress.org/plugin/wp-print.2.20.zip" title="http://downloads.wordpress.org/plugin/wp-print.2.20.zip">WP-Print 2.20 For WordPress 2.1.x, 2.2.x And 2.3.x</a><br />
239
+ <strong>&raquo;</strong> <a href="http://downloads.wordpress.org/plugin/wp-print.2.06.zip" title="http://downloads.wordpress.org/plugin/wp-print.2.06.zip">WP-Print 2.06 For WordPress 2.0.x</a><br />
240
+ <strong>&raquo;</strong> <a href="http://downloads.wordpress.org/plugin/wp-print.2.00.zip" title="http://downloads.wordpress.org/plugin/wp-print.2.00.zip">WP-Print 2.00 For WordPress 1.5.2</a>
241
  </p>
242
  <p>
243
  <strong>Screenshots:</strong><br />
260
  <strong>&raquo;</strong> <a href="http://forums.lesterchan.net/index.php?board=18.0" title="http://forums.lesterchan.net/index.php?board=18.0">http://forums.lesterchan.net/index.php?board=18.0</a>
261
  </p>
262
  <p>
263
+ <strong>Credits:</strong><br />
264
+ <strong>&raquo;</strong> Icons courtesy of <a href="http://www.famfamfam.com/">FamFamFam</a>.
265
  </p>
266
  <p>
267
  <strong>Note:</strong><br />
268
  <strong>&raquo;</strong> The <strong>Changelog</strong>, <strong>Installation</strong>, <strong>Upgrade</strong>, <strong>Usage</strong> Tab at the top of the page.<br />
 
269
  </p>
270
  <p>
271
  <strong>Donations:</strong><br />
272
  <strong>&raquo;</strong> I spent most of my free time creating, updating, maintaining and supporting these plugins, if you really love my plugins and could spare me a couple of bucks as my school allowance, I will really appericiate it. If not feel free to use it without any obligations. Thank You. My Paypal account is
273
  <script type="text/javascript">
274
  /* <![CDATA[*/
275
+ document.write(' <strong>lesterchan@gmail.com</strong>.');
276
  /* ]]> */
277
  </script>
278
  </p>
282
  <div id="Changelog" style="display: none;">
283
  <div class="SubTitle">&raquo; Changelog</div>
284
  <ul>
285
+ <li>
286
+ <strong>Version 2.30 (01-06-2008)</strong>
287
+ <ul>
288
+ <li>NEW: Works For WordPress 2.5 Only</li>
289
+ <li>NEW: WP-Print Will Load 'print-css.css' Inside Your Theme Directory If It Exists. If Not, It Will Just Load The Default 'print-css.css' By WP-Print</li>
290
+ <li>NEW: Uses Shortcode API</li>
291
+ <li>NEW: Added "Right To Left" And "Left To Right Text" Direction Option</li>
292
+ <li>NEW: Option To Remove Videos From Post</li>
293
+ <li>NEW: Duplicate Links Now Uses A Single Number And Printed Only Once By <a href="http://www.cneophytou.com/">Constantinos Neophytou</a></li>
294
+ <li>NEW: &lt;IMG&gt; And &lt;A&gt; Tag Now Matches Single Quotes By <a href="http://www.cneophytou.com/">Constantinos Neophytou</a></li>
295
+ <li>NEW: Uses /wp-print/ Folder Instead Of /print/</li>
296
+ <li>NEW: Uses wp-print.php Instead Of print.php</li>
297
+ <li>NEW: Changed wp-print.php To print-posts.php</li>
298
+ <li>NEW: Changed wp-print-comments.php To print-comments.php</li>
299
+ <li>NEW: Changed wp-print-css.css To print-css.css</li>
300
+ <li>FIXED: Comment Type Not Translated</li>
301
+ </ul>
302
+ </li>
303
  <li>
304
  <strong>Version 2.20 (01-10-2007)</strong>
305
  <ul>
409
  </li>
410
  <li>
411
  Put:
412
+ <blockquote>Folder: wp-print</blockquote>
413
  </li>
414
  <li>
415
  <strong>Activate</strong> WP-Print Plugin
416
  </li>
417
  <li>
418
+ You Need To Re-Generate The Permalink (<strong>WP-Admin -> Settings -> Permalinks -> Save Changes</strong>)
419
  </li>
420
  <li>
421
  Refer To <strong>Usage</strong> For Further Instructions
426
  <!-- Upgrade Instructions -->
427
  <div id="Upgrade" style="display: none;">
428
  <div class="SubTitle">&raquo; Upgrade Instructions</div>
429
+ <div class="SubSubTitle">From v2.0x To v2.30</div>
430
  <ol>
431
  <li>
432
  <strong>Deactivate</strong> WP-Print Plugin
436
  </li>
437
  <li>
438
  Put/Overwrite:
439
+ <blockquote>Folder: wp-print</blockquote>
440
  </li>
441
  <li>
442
+ Delete this folder if exists:
443
  <blockquote>
444
+ Folder: print
 
445
  </blockquote>
446
  </li>
447
  <li>
448
  <strong>Activate</strong> WP-Print Plugin
449
  </li>
450
  <li>
451
+ You Need To Re-Generate The Permalink (<strong>WP-Admin -> Settings -> Permalinks -> Save Changes</strong>)
452
  </li>
453
  <li>
454
  Refer To <strong>Usage</strong> For Further Instructions
477
  &lt;?php if(function_exists('wp_print')) { print_link(); } ?&gt;
478
  </blockquote>
479
  <p>If you DO NOT want the print link to appear in every post/page, DO NOT use the code above. Just type in <strong>[print_link]</strong> into the selected post/page content and it will embed the print link into that post/page only.</p>
480
+ <p>The <b>first value</b> is the text for printing post.</p>
481
+ <p>The <b>second value</b> is the text for printing page.</p>
482
+ <p>Default: print_link('', '')</p>
483
+ <p>Alternatively, you can set the text in 'WP-Admin -> Settings -> Print'.</p>
484
  </li>
485
  <li>
486
+ Go to <strong>'WP-Admin -> Settings -> Print'</strong> to configure the style of the print text link.
487
  </li>
488
  </ol>
489
+ <div class="SubSubTitle">Note</div>
490
+ <ul>
491
+ <li>
492
+ WP-Print will load '<strong>print-css.css</strong>' from your theme's directory if it exists.
493
+ <ul>
494
+ <li>If it doesn't exists, it will just load the default 'print-css.css' that comes with WP-Print.</li>
495
+ <li>This will allow you to upgrade WP-Print without worrying about overwriting your printing styles that you have created.</li>
496
+ </ul>
497
+ </li>
498
+ </ul>
499
  </div>
500
  </div>
501
  </div>
502
+ <p id="Copyright">WP-Print 2.30<br />Copyright &copy; 2008 Lester 'GaMerZ' Chan. All Rights Reserved.</p>
503
  </body>
504
  </html>
readme.txt CHANGED
@@ -2,8 +2,8 @@
2
  Contributors: GamerZ
3
  Donate link: http://lesterchan.net/wordpress
4
  Tags: print, printer, wp-print
5
- Requires at least: 2.3.0
6
- Stable tag: 2.20
7
 
8
  Displays a printable version of your WordPress blog's post/page.
9
 
2
  Contributors: GamerZ
3
  Donate link: http://lesterchan.net/wordpress
4
  Tags: print, printer, wp-print
5
+ Requires at least: 2.5.0
6
+ Stable tag: 2.30
7
 
8
  Displays a printable version of your WordPress blog's post/page.
9
 
wp-print.mo ADDED
Binary file
print/print.php → wp-print.php RENAMED
@@ -1,16 +1,16 @@
1
  <?php
2
  /*
3
  Plugin Name: WP-Print
4
- Plugin URI: http://lesterchan.net/portfolio/programming.php
5
  Description: Displays a printable version of your WordPress blog's post/page.
6
- Version: 2.20
7
  Author: Lester 'GaMerZ' Chan
8
  Author URI: http://lesterchan.net
9
  */
10
 
11
 
12
  /*
13
- Copyright 2007 Lester Chan (email : gamerz84@hotmail.com)
14
 
15
  This program is free software; you can redistribute it and/or modify
16
  it under the terms of the GNU General Public License as published by
@@ -31,7 +31,7 @@ Author URI: http://lesterchan.net
31
  ### Create Text Domain For Translations
32
  add_action('init', 'print_textdomain');
33
  function print_textdomain() {
34
- load_plugin_textdomain('wp-print', 'wp-content/plugins/print');
35
  }
36
 
37
 
@@ -39,7 +39,7 @@ function print_textdomain() {
39
  add_action('admin_menu', 'print_menu');
40
  function print_menu() {
41
  if (function_exists('add_options_page')) {
42
- add_options_page(__('Print', 'wp-print'), __('Print', 'wp-print'), 'manage_options', 'print/print-options.php') ;
43
  }
44
  }
45
 
@@ -47,6 +47,7 @@ function print_menu() {
47
  ### Function: Print htaccess ReWrite Rules
48
  add_filter('generate_rewrite_rules', 'print_rewrite');
49
  function print_rewrite($wp_rewrite) {
 
50
  $r_rule = '';
51
  $r_link = '';
52
  $print_link = get_permalink();
@@ -55,16 +56,34 @@ function print_rewrite($wp_rewrite) {
55
  } else {
56
  $print_link_text = 'print';
57
  }
58
- $rewrite_rules2 = $wp_rewrite->generate_rewrite_rule($wp_rewrite->permalink_structure.$print_link_text);
59
- array_splice($rewrite_rules2, 1);
60
- $r_rule = array_keys($rewrite_rules2);
61
  $r_rule = array_shift($r_rule);
62
  $r_rule = str_replace('/trackback', '',$r_rule);
63
- $r_link = array_values($rewrite_rules2);
64
  $r_link = array_shift($r_link);
65
- $r_link = str_replace('tb=1', 'print=1', $r_link);
66
- $print_rules = array($r_rule => $r_link, '(.+)/printpage/?$' => 'index.php?pagename='.$wp_rewrite->preg_index(1).'&print=1');
67
- $wp_rewrite->rules = $print_rules + $wp_rewrite->rules;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
68
  }
69
 
70
 
@@ -72,12 +91,13 @@ function print_rewrite($wp_rewrite) {
72
  add_filter('query_vars', 'print_variables');
73
  function print_variables($public_query_vars) {
74
  $public_query_vars[] = 'print';
 
75
  return $public_query_vars;
76
  }
77
 
78
 
79
  ### Function: Display Print Link
80
- function print_link($deprecated = '', $deprecated2 ='', $echo = true) {
81
  global $id;
82
  if (function_exists('polyglot_get_lang')){
83
  global $polyglot_settings;
@@ -87,8 +107,12 @@ function print_link($deprecated = '', $deprecated2 ='', $echo = true) {
87
  $using_permalink = get_option('permalink_structure');
88
  $print_options = get_option('print_options');
89
  $print_style = intval($print_options['print_style']);
90
- $print_text = stripslashes($print_options['post_text']);
91
- $print_icon = get_option('siteurl').'/wp-content/plugins/print/images/'.$print_options['print_icon'];
 
 
 
 
92
  $print_link = get_permalink();
93
  $print_html = stripslashes($print_options['print_html']);
94
  // Fix For Static Page
@@ -102,14 +126,22 @@ function print_link($deprecated = '', $deprecated2 ='', $echo = true) {
102
  $print_link = $print_link.'/';
103
  }
104
  if(is_page()) {
105
- $print_text = stripslashes($print_options['page_text']);
 
 
 
 
106
  $print_link = $print_link.'printpage/'.$polyglot_append;
107
  } else {
108
  $print_link = $print_link.'print/'.$polyglot_append;
109
  }
110
  } else {
111
  if(is_page()) {
112
- $print_text = stripslashes($print_options['page_text']);
 
 
 
 
113
  }
114
  $print_link = $print_link.'&amp;print=1';
115
  }
@@ -142,29 +174,24 @@ function print_link($deprecated = '', $deprecated2 ='', $echo = true) {
142
  }
143
 
144
 
145
- ### Function: Display Print Image Link (Deprecated)
146
- function print_link_image() {
147
- print_link();
148
- }
149
-
150
-
151
- ### Function: Place Print Link
152
- add_filter('the_content', 'place_printlink', 7);
153
- add_filter('the_excerpt', 'place_printlink', 7);
154
- function place_printlink($content){
155
  if(!is_feed()) {
156
- $content = str_replace("[print_link]", print_link('', '', false), $content);
157
  } else {
158
- $content = str_replace("[print_link]", __('Note: There is a print link embedded within this post, please visit this post to print it.', 'wp-print'), $content);
159
- }
160
- return $content;
161
  }
162
 
163
 
164
  ### Function: Print Content
165
  function print_content($display = true) {
166
- global $links_text, $link_number, $pages, $multipage, $numpages, $post;
167
  $max_url_char = 80;
 
 
 
168
  if(!empty($post->post_password) && stripslashes($_COOKIE['wp-postpass_'.COOKIEHASH]) != $post->post_password) {
169
  $content = get_the_password_form();
170
  } else {
@@ -180,11 +207,13 @@ function print_content($display = true) {
180
  if(!print_can('images')) {
181
  $content = remove_image($content);
182
  }
 
 
 
183
  if(print_can('links')) {
184
- preg_match_all('/<a(.+?)href=\"(.+?)\"(.*?)>(.+?)<\/a>/', $content, $matches);
185
  for ($i=0; $i < count($matches[0]); $i++) {
186
  $link_match = $matches[0][$i];
187
- $link_number++;
188
  $link_url = $matches[2][$i];
189
  if(stristr($link_url, 'https://')) {
190
  $link_url =(strtolower(substr($link_url,0,8)) != 'https://') ?get_option('home') . $link_url : $link_url;
@@ -195,15 +224,26 @@ function print_content($display = true) {
195
  } else {
196
  $link_url =(strtolower(substr($link_url,0,7)) != 'http://') ?get_option('home') . $link_url : $link_url;
197
  }
198
- $link_text = $matches[4][$i];
199
- $content = str_replace_one($link_match, '['.$link_number."] <a href=\"$link_url\" rel=\"external\">".$link_text.'</a>', $content);
200
- if(strlen($link_url) > 100) {
201
- $link_url = chunk_split($link_url, 100, "<br />\n");
202
- }
203
- if(preg_match('/<img(.+?)src=\"(.+?)\"(.*?)>/',$link_text)) {
204
- $links_text .= '<br />['.$link_number.'] '.__('Image', 'wp-print').': <b>'.$link_url.'</b>';
205
  } else {
206
- $links_text .= '<br />['.$link_number.'] '.$link_text.': <b>'.$link_url.'</b>';
 
 
 
 
 
 
 
 
 
 
 
 
207
  }
208
  }
209
  }
@@ -227,17 +267,22 @@ function print_categories($before = '', $after = '') {
227
 
228
  ### Function: Print Comments Content
229
  function print_comments_content($display = true) {
230
- global $links_text, $link_number;
 
 
 
231
  $content = get_comment_text();
232
  $content = apply_filters('comment_text', $content);
233
  if(!print_can('images')) {
234
  $content = remove_image($content);
235
  }
 
 
 
236
  if(print_can('links')) {
237
- preg_match_all('/<a(.+?)href=\"(.+?)\"(.*?)>(.+?)<\/a>/', $content, $matches);
238
  for ($i=0; $i < count($matches[0]); $i++) {
239
  $link_match = $matches[0][$i];
240
- $link_number++;
241
  $link_url = $matches[2][$i];
242
  if(stristr($link_url, 'https://')) {
243
  $link_url =(strtolower(substr($link_url,0,8)) != 'https://') ?get_option('home') . $link_url : $link_url;
@@ -248,15 +293,25 @@ function print_comments_content($display = true) {
248
  } else {
249
  $link_url =(strtolower(substr($link_url,0,7)) != 'http://') ?get_option('home') . $link_url : $link_url;
250
  }
251
- $link_text = $matches[4][$i];
252
- $content = str_replace_one($link_match, '['.$link_number."] <a href=\"$link_url\" rel=\"external\">".$link_text.'</a>', $content);
253
- if(strlen($link_url) > 100) {
254
- $link_url = chunk_split($link_url, 100, "<br />\n");
255
- }
256
- if(preg_match('/<img(.+?)src=\"(.+?)\"(.*?)>/',$link_text)) {
257
- $links_text .= '<br />['.$link_number.'] '.__('Image', 'wp-print').': <b>'.$link_url.'</b>';
258
  } else {
259
- $links_text .= '<br />['.$link_number.'] '.$link_text.': <b>'.$link_url.'</b>';
 
 
 
 
 
 
 
 
 
 
 
 
260
  }
261
  }
262
  }
@@ -308,8 +363,8 @@ function print_links($text_links = '') {
308
  ### Function: Load WP-Print
309
  add_action('template_redirect', 'wp_print');
310
  function wp_print() {
311
- if(intval(get_query_var('print')) == 1) {
312
- include(ABSPATH.'wp-content/plugins/print/wp-print.php');
313
  exit;
314
  }
315
  }
@@ -317,7 +372,7 @@ function wp_print() {
317
 
318
  ### Function: Add Print Comments Template
319
  function print_template_comments($file = '') {
320
- $file = ABSPATH.'wp-content/plugins/print/wp-print-comments.php';
321
  return $file;
322
  }
323
 
@@ -337,7 +392,14 @@ function print_can($type) {
337
 
338
  ### Function: Remove Image From Text
339
  function remove_image($content) {
340
- $content= preg_replace('/<img(.+?)src=\"(.+?)\"(.*?)>/', '',$content);
 
 
 
 
 
 
 
341
  return $content;
342
  }
343
 
@@ -353,7 +415,7 @@ function str_replace_one($search, $replace, $content){
353
 
354
 
355
  ### Function: Print Options
356
- add_action('activate_print/print.php', 'print_init');
357
  function print_init() {
358
  // Add Options
359
  $print_options = array();
@@ -365,7 +427,9 @@ function print_init() {
365
  $print_options['comments'] = 0;
366
  $print_options['links'] = 1;
367
  $print_options['images'] = 1;
 
368
  $print_options['disclaimer'] = sprintf(__('Copyright &copy; %s %s. All rights reserved.', 'wp-print'), date('Y'), get_option('blogname'));
 
369
  add_option('print_options', $print_options, 'Print Options');
370
  }
371
  ?>
1
  <?php
2
  /*
3
  Plugin Name: WP-Print
4
+ Plugin URI: http://lesterchan.net/portfolio/programming/php/
5
  Description: Displays a printable version of your WordPress blog's post/page.
6
+ Version: 2.30
7
  Author: Lester 'GaMerZ' Chan
8
  Author URI: http://lesterchan.net
9
  */
10
 
11
 
12
  /*
13
+ Copyright 2008 Lester Chan (email : lesterchan@gmail.com)
14
 
15
  This program is free software; you can redistribute it and/or modify
16
  it under the terms of the GNU General Public License as published by
31
  ### Create Text Domain For Translations
32
  add_action('init', 'print_textdomain');
33
  function print_textdomain() {
34
+ load_plugin_textdomain('wp-print', 'wp-content/plugins/wp-print');
35
  }
36
 
37
 
39
  add_action('admin_menu', 'print_menu');
40
  function print_menu() {
41
  if (function_exists('add_options_page')) {
42
+ add_options_page(__('Print', 'wp-print'), __('Print', 'wp-print'), 'manage_options', 'wp-print/print-options.php') ;
43
  }
44
  }
45
 
47
  ### Function: Print htaccess ReWrite Rules
48
  add_filter('generate_rewrite_rules', 'print_rewrite');
49
  function print_rewrite($wp_rewrite) {
50
+ // Print Rules For Posts
51
  $r_rule = '';
52
  $r_link = '';
53
  $print_link = get_permalink();
56
  } else {
57
  $print_link_text = 'print';
58
  }
59
+ $rewrite_rules = $wp_rewrite->generate_rewrite_rule($wp_rewrite->permalink_structure.$print_link_text, EP_PERMALINK);
60
+ $rewrite_rules = array_slice($rewrite_rules, 4, 1);
61
+ $r_rule = array_keys($rewrite_rules);
62
  $r_rule = array_shift($r_rule);
63
  $r_rule = str_replace('/trackback', '',$r_rule);
64
+ $r_link = array_values($rewrite_rules);
65
  $r_link = array_shift($r_link);
66
+ $r_link = str_replace('tb=1', 'print=1', $r_link);
67
+ $wp_rewrite->rules = array_merge(array($r_rule => $r_link), $wp_rewrite->rules);
68
+ // Print Rules For Pages
69
+ $page_uris = $wp_rewrite->page_uri_index();
70
+ $uris = $page_uris[0];
71
+ if(is_array($uris)) {
72
+ $print_page_rules = array();
73
+ foreach ($uris as $uri => $pagename) {
74
+ $wp_rewrite->add_rewrite_tag('%pagename%', "($uri)", 'pagename=');
75
+ $rewrite_rules = $wp_rewrite->generate_rewrite_rules($wp_rewrite->get_page_permastruct().'/printpage', EP_PAGES);
76
+ $rewrite_rules = array_slice($rewrite_rules, 4, 1);
77
+ $r_rule = array_keys($rewrite_rules);
78
+ $r_rule = array_shift($r_rule);
79
+ $r_rule = str_replace('/trackback', '',$r_rule);
80
+ $r_link = array_values($rewrite_rules);
81
+ $r_link = array_shift($r_link);
82
+ $r_link = str_replace('tb=1', 'print=1', $r_link);
83
+ $print_page_rules = array_merge($print_page_rules, array($r_rule => $r_link));
84
+ }
85
+ $wp_rewrite->rules = array_merge($print_page_rules, $wp_rewrite->rules);
86
+ }
87
  }
88
 
89
 
91
  add_filter('query_vars', 'print_variables');
92
  function print_variables($public_query_vars) {
93
  $public_query_vars[] = 'print';
94
+ $public_query_vars[] = 'printpage';
95
  return $public_query_vars;
96
  }
97
 
98
 
99
  ### Function: Display Print Link
100
+ function print_link($print_post_text = '', $print_page_text = '', $echo = true) {
101
  global $id;
102
  if (function_exists('polyglot_get_lang')){
103
  global $polyglot_settings;
107
  $using_permalink = get_option('permalink_structure');
108
  $print_options = get_option('print_options');
109
  $print_style = intval($print_options['print_style']);
110
+ if(empty($print_post_text)) {
111
+ $print_text = stripslashes($print_options['post_text']);
112
+ } else {
113
+ $print_text = $print_post_text;
114
+ }
115
+ $print_icon = get_option('siteurl').'/wp-content/plugins/wp-print/images/'.$print_options['print_icon'];
116
  $print_link = get_permalink();
117
  $print_html = stripslashes($print_options['print_html']);
118
  // Fix For Static Page
126
  $print_link = $print_link.'/';
127
  }
128
  if(is_page()) {
129
+ if(empty($print_page_text)) {
130
+ $print_text = stripslashes($print_options['page_text']);
131
+ } else {
132
+ $print_text = $print_page_text;
133
+ }
134
  $print_link = $print_link.'printpage/'.$polyglot_append;
135
  } else {
136
  $print_link = $print_link.'print/'.$polyglot_append;
137
  }
138
  } else {
139
  if(is_page()) {
140
+ if(empty($print_page_text)) {
141
+ $print_text = stripslashes($print_options['page_text']);
142
+ } else {
143
+ $print_text = $print_page_text;
144
+ }
145
  }
146
  $print_link = $print_link.'&amp;print=1';
147
  }
174
  }
175
 
176
 
177
+ ### Function: Short Code For Inserting Prink Links Into Posts/Pages
178
+ add_shortcode('print_link', 'print_link_shortcode');
179
+ function print_link_shortcode($atts) {
 
 
 
 
 
 
 
180
  if(!is_feed()) {
181
+ return print_link('', '', false);
182
  } else {
183
+ return __('Note: There is a print link embedded within this post, please visit this post to print it.', 'wp-print');
184
+ }
 
185
  }
186
 
187
 
188
  ### Function: Print Content
189
  function print_content($display = true) {
190
+ global $links_text, $link_number, $max_link_number, $matched_links, $pages, $multipage, $numpages, $post;
191
  $max_url_char = 80;
192
+ if (!isset($matched_links)) {
193
+ $matched_links = array();
194
+ }
195
  if(!empty($post->post_password) && stripslashes($_COOKIE['wp-postpass_'.COOKIEHASH]) != $post->post_password) {
196
  $content = get_the_password_form();
197
  } else {
207
  if(!print_can('images')) {
208
  $content = remove_image($content);
209
  }
210
+ if(!print_can('videos')) {
211
+ $content = remove_video($content);
212
+ }
213
  if(print_can('links')) {
214
+ preg_match_all('/<a(.+?)href=[\"\'](.+?)[\"\'](.*?)>(.+?)<\/a>/', $content, $matches);
215
  for ($i=0; $i < count($matches[0]); $i++) {
216
  $link_match = $matches[0][$i];
 
217
  $link_url = $matches[2][$i];
218
  if(stristr($link_url, 'https://')) {
219
  $link_url =(strtolower(substr($link_url,0,8)) != 'https://') ?get_option('home') . $link_url : $link_url;
224
  } else {
225
  $link_url =(strtolower(substr($link_url,0,7)) != 'http://') ?get_option('home') . $link_url : $link_url;
226
  }
227
+ $link_text = $matches[4][$i];+
228
+ $new_link = true;
229
+ $link_url_hash = md5($link_url);
230
+ if (!isset($matched_links[$link_url_hash])) {
231
+ $link_number = ++$max_link_number;
232
+ $matched_links[$link_url_hash] = $link_number;
 
233
  } else {
234
+ $new_link = false;
235
+ $link_number = $matched_links[$link_url_hash];
236
+ }
237
+ $content = str_replace_one($link_match, '['.$link_number."] <a href=\"$link_url\" rel=\"external\">".$link_text.'</a>', $content);
238
+ if ($new_link) {
239
+ if(strlen($link_url) > 100) {
240
+ $link_url = chunk_split($link_url, 100, "<br />\n");
241
+ }
242
+ if(preg_match('/<img(.+?)src=[\"\'](.+?)[\"\'](.*?)>/',$link_text)) {
243
+ $links_text .= '<br />['.$link_number.'] '.__('Image', 'wp-print').': <b>'.$link_url.'</b>';
244
+ } else {
245
+ $links_text .= '<br />['.$link_number.'] '.$link_text.': <b>'.$link_url.'</b>';
246
+ }
247
  }
248
  }
249
  }
267
 
268
  ### Function: Print Comments Content
269
  function print_comments_content($display = true) {
270
+ global $links_text, $link_number, $max_link_number, $matched_links;
271
+ if (!isset($matched_links)) {
272
+ $matched_links = array();
273
+ }
274
  $content = get_comment_text();
275
  $content = apply_filters('comment_text', $content);
276
  if(!print_can('images')) {
277
  $content = remove_image($content);
278
  }
279
+ if(!print_can('videos')) {
280
+ $content = remove_video($content);
281
+ }
282
  if(print_can('links')) {
283
+ preg_match_all('/<a(.+?)href=[\"\'](.+?)[\"\'](.*?)>(.+?)<\/a>/', $content, $matches);
284
  for ($i=0; $i < count($matches[0]); $i++) {
285
  $link_match = $matches[0][$i];
 
286
  $link_url = $matches[2][$i];
287
  if(stristr($link_url, 'https://')) {
288
  $link_url =(strtolower(substr($link_url,0,8)) != 'https://') ?get_option('home') . $link_url : $link_url;
293
  } else {
294
  $link_url =(strtolower(substr($link_url,0,7)) != 'http://') ?get_option('home') . $link_url : $link_url;
295
  }
296
+ $new_link = true;
297
+ $link_url_hash = md5($link_url);
298
+ if (!isset($matched_links[$link_url_hash])) {
299
+ $link_number = ++$max_link_number;
300
+ $matched_links[$link_url_hash] = $link_number;
 
 
301
  } else {
302
+ $new_link = false;
303
+ $link_number = $matched_links[$link_url_hash];
304
+ }
305
+ $content = str_replace_one($link_match, '['.$link_number."] <a href=\"$link_url\" rel=\"external\">".$link_text.'</a>', $content);
306
+ if ($new_link) {
307
+ if(strlen($link_url) > 100) {
308
+ $link_url = chunk_split($link_url, 100, "<br />\n");
309
+ }
310
+ if(preg_match('/<img(.+?)src=[\"\'](.+?)[\"\'](.*?)>/',$link_text)) {
311
+ $links_text .= '<br />['.$link_number.'] '.__('Image', 'wp-print').': <b>'.$link_url.'</b>';
312
+ } else {
313
+ $links_text .= '<br />['.$link_number.'] '.$link_text.': <b>'.$link_url.'</b>';
314
+ }
315
  }
316
  }
317
  }
363
  ### Function: Load WP-Print
364
  add_action('template_redirect', 'wp_print');
365
  function wp_print() {
366
+ if(intval(get_query_var('print')) == 1 || intval(get_query_var('printpage')) == 1) {
367
+ include(ABSPATH.'wp-content/plugins/wp-print/print-posts.php');
368
  exit;
369
  }
370
  }
372
 
373
  ### Function: Add Print Comments Template
374
  function print_template_comments($file = '') {
375
+ $file = ABSPATH.'wp-content/plugins/wp-print/print-comments.php';
376
  return $file;
377
  }
378
 
392
 
393
  ### Function: Remove Image From Text
394
  function remove_image($content) {
395
+ $content= preg_replace('/<img(.+?)src=[\"\'](.+?)[\"\'](.*?)>/', '',$content);
396
+ return $content;
397
+ }
398
+
399
+
400
+ ### Function: Remove Video From Text
401
+ function remove_video($content) {
402
+ $content= preg_replace('/<object[^>]*?>.*?<\/object>/', '',$content);
403
  return $content;
404
  }
405
 
415
 
416
 
417
  ### Function: Print Options
418
+ add_action('activate_wp-print/wp-print.php', 'print_init');
419
  function print_init() {
420
  // Add Options
421
  $print_options = array();
427
  $print_options['comments'] = 0;
428
  $print_options['links'] = 1;
429
  $print_options['images'] = 1;
430
+ $print_options['videos'] = 0;
431
  $print_options['disclaimer'] = sprintf(__('Copyright &copy; %s %s. All rights reserved.', 'wp-print'), date('Y'), get_option('blogname'));
432
+ $print_options['text_direction'] = 'ltr';
433
  add_option('print_options', $print_options, 'Print Options');
434
  }
435
  ?>
print/wp-print.pot → wp-print.pot RENAMED
@@ -1,12 +1,13 @@
1
  msgid ""
2
  msgstr ""
3
- "Project-Id-Version: WP-Print 2.20\n"
4
- "POT-Creation-Date: \n"
5
- "PO-Revision-Date: 2007-09-30 16:07+0800\n"
6
- "Last-Translator: Lester 'GaMerZ' Chan <gamerz84@hotmail.com>\n"
7
- "Language-Team: Lester Chan <gamerz84@hotmail.com>\n"
 
8
  "MIME-Version: 1.0\n"
9
- "Content-Type: text/plain; charset=utf-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
11
  "X-Poedit-Language: English\n"
12
  "X-Poedit-Country: SINGAPORE\n"
@@ -14,14 +15,52 @@ msgstr ""
14
  "X-Poedit-Basepath: .\n"
15
  "X-Poedit-SearchPath-0: .\n"
16
 
17
- #: print-options.php:32
18
- #: print-options.php:239
19
- msgid "Update Options"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
20
  msgstr ""
21
 
22
  #: print-options.php:46
23
- #: print-options.php:131
24
- #: print-options.php:197
25
  msgid "Print Options"
26
  msgstr ""
27
 
@@ -33,33 +72,33 @@ msgstr ""
33
  msgid "No Print Option Updated"
34
  msgstr ""
35
 
36
- #: print-options.php:60
37
- #: print-options.php:277
38
  msgid "UNINSTALL WP-Print"
39
  msgstr ""
40
 
41
- #: print-options.php:68
42
  #, php-format
43
  msgid "Setting Key '%s' has been deleted."
44
  msgstr ""
45
 
46
- #: print-options.php:72
47
  #, php-format
48
  msgid "Error deleting Setting Key '%s'."
49
  msgstr ""
50
 
51
- #: print-options.php:94
52
- #: print-options.php:247
53
  msgid "Uninstall WP-Print"
54
  msgstr ""
55
 
56
- #: print-options.php:95
57
  #, php-format
58
  msgid "<a href=\"%s\">Click Here</a> To Finish The Uninstallation And WP-Print Will Be Deactivated Automatically."
59
  msgstr ""
60
 
61
- #: print-options.php:121
62
- #: print.php:368
63
  #, php-format
64
  msgid "Copyright &copy; %s %s. All rights reserved."
65
  msgstr ""
@@ -101,7 +140,7 @@ msgid "Custom"
101
  msgstr ""
102
 
103
  #: print-options.php:186
104
- #: print-options.php:233
105
  msgid "HTML is allowed."
106
  msgstr ""
107
 
@@ -118,64 +157,82 @@ msgid "URL to the print icon you have chosen above."
118
  msgstr ""
119
 
120
  #: print-options.php:190
121
- #: print-options.php:230
122
  msgid "Restore Default Template"
123
  msgstr ""
124
 
125
- #: print-options.php:200
126
  msgid "Print Comments?"
127
  msgstr ""
128
 
129
- #: print-options.php:203
130
- #: print-options.php:212
131
- #: print-options.php:221
132
- #: print-options.php:276
 
133
  msgid "Yes"
134
  msgstr ""
135
 
136
- #: print-options.php:204
137
- #: print-options.php:213
138
- #: print-options.php:222
 
139
  msgid "No"
140
  msgstr ""
141
 
142
- #: print-options.php:209
143
  msgid "Print Links?"
144
  msgstr ""
145
 
146
- #: print-options.php:218
147
  msgid "Print Images?"
148
  msgstr ""
149
 
150
- #: print-options.php:228
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
151
  msgid "Disclaimer/Copyright Text?"
152
  msgstr ""
153
 
154
- #: print-options.php:239
155
- msgid "Cancel"
156
  msgstr ""
157
 
158
- #: print-options.php:249
159
  msgid "Deactivating WP-Print plugin does not remove any data that may have been created, such as the print options. To completely remove this plugin, you can uninstall it here."
160
  msgstr ""
161
 
162
- #: print-options.php:252
163
  msgid "WARNING:"
164
  msgstr ""
165
 
166
- #: print-options.php:253
167
  msgid "Once uninstalled, this cannot be undone. You should use a Database Backup plugin of WordPress to back up all the data first."
168
  msgstr ""
169
 
170
- #: print-options.php:256
171
  msgid "The following WordPress Options will be DELETED:"
172
  msgstr ""
173
 
174
- #: print-options.php:260
175
  msgid "WordPress Options"
176
  msgstr ""
177
 
178
- #: print-options.php:277
179
  msgid ""
180
  "You Are About To Uninstall WP-Print From WordPress.\\n"
181
  "This Action Is Not Reversible.\\n"
@@ -183,116 +240,85 @@ msgid ""
183
  " Choose [Cancel] To Stop, [OK] To Uninstall."
184
  msgstr ""
185
 
186
- #: print.php:42
187
- msgid "Print"
188
- msgstr ""
189
-
190
- #: print.php:158
191
- msgid "Note: There is a print link embedded within this post, please visit this post to print it."
192
- msgstr ""
193
-
194
- #: print.php:204
195
- #: print.php:257
196
- msgid "Image"
197
  msgstr ""
198
 
199
- #: print.php:279
200
- msgid "No Comments"
201
  msgstr ""
202
 
203
- #: print.php:281
204
- msgid "1 Comment"
205
  msgstr ""
206
 
207
- #: print.php:283
208
- #, php-format
209
- msgid "%s Comments"
210
  msgstr ""
211
 
212
- #: print.php:286
213
- msgid "Comments Disabled"
214
  msgstr ""
215
 
216
- #: print.php:289
217
- msgid "Comments Hidden"
218
  msgstr ""
219
 
220
- #: print.php:300
221
- msgid "URLs in this post:"
222
  msgstr ""
223
 
224
- #: print.php:360
225
- msgid "Print This Post"
226
  msgstr ""
227
 
228
- #: print.php:361
229
- msgid "Print This Page"
230
  msgstr ""
231
 
232
- #: wp-print-comments.php:21
233
- msgid "Open"
234
  msgstr ""
235
 
236
- #: wp-print-comments.php:21
237
- msgid "Close"
238
  msgstr ""
239
 
240
- #: wp-print-comments.php:23
241
- msgid "To"
 
242
  msgstr ""
243
 
244
- #: wp-print-comments.php:26
245
- msgid "By"
246
  msgstr ""
247
 
248
- #: wp-print-comments.php:26
249
- #: wp-print.php:48
250
- msgid "On"
251
  msgstr ""
252
 
253
- #: wp-print-comments.php:26
254
- #: wp-print.php:48
255
  #, php-format
256
- msgid "%s @ %s"
257
- msgstr ""
258
-
259
- #: wp-print-comments.php:30
260
- msgid "Your comment is awaiting moderation."
261
- msgstr ""
262
-
263
- #: wp-print.php:48
264
- msgid "Posted By"
265
- msgstr ""
266
-
267
- #: wp-print.php:48
268
- msgid "In"
269
- msgstr ""
270
-
271
- #: wp-print.php:55
272
- msgid "Article printed from"
273
- msgstr ""
274
-
275
- #: wp-print.php:56
276
- msgid "URL to article"
277
  msgstr ""
278
 
279
- #: wp-print.php:60
280
- msgid "Click"
281
  msgstr ""
282
 
283
- #: wp-print.php:60
284
- msgid "Click here to print."
285
  msgstr ""
286
 
287
- #: wp-print.php:60
288
- msgid "here"
289
  msgstr ""
290
 
291
- #: wp-print.php:60
292
- msgid "to print."
293
  msgstr ""
294
 
295
- #: wp-print.php:62
296
- msgid "No posts matched your criteria."
297
  msgstr ""
298
 
1
  msgid ""
2
  msgstr ""
3
+ "Project-Id-Version: WP-Print 2.30\n"
4
+ "Report-Msgid-Bugs-To: \n"
5
+ "POT-Creation-Date: 2008-05-13 00:46+0800\n"
6
+ "PO-Revision-Date: 2008-05-13 00:46+0800\n"
7
+ "Last-Translator: Lester Chan <lesterchan@gmail.com>\n"
8
+ "Language-Team: Lester Chan <lesterchan@gmail.com>\n"
9
  "MIME-Version: 1.0\n"
10
+ "Content-Type: text/plain; charset=UTF-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
12
  "X-Poedit-Language: English\n"
13
  "X-Poedit-Country: SINGAPORE\n"
15
  "X-Poedit-Basepath: .\n"
16
  "X-Poedit-SearchPath-0: .\n"
17
 
18
+ #: print-comments.php:21
19
+ msgid "Open"
20
+ msgstr ""
21
+
22
+ #: print-comments.php:21
23
+ msgid "Close"
24
+ msgstr ""
25
+
26
+ #: print-comments.php:23
27
+ msgid "To"
28
+ msgstr ""
29
+
30
+ #: print-comments.php:26
31
+ msgid "Comment"
32
+ msgstr ""
33
+
34
+ #: print-comments.php:26
35
+ msgid "Trackback"
36
+ msgstr ""
37
+
38
+ #: print-comments.php:26
39
+ msgid "Pingback"
40
+ msgstr ""
41
+
42
+ #: print-comments.php:26
43
+ msgid "By"
44
+ msgstr ""
45
+
46
+ #: print-comments.php:26
47
+ #: print-posts.php:72
48
+ msgid "On"
49
+ msgstr ""
50
+
51
+ #: print-comments.php:26
52
+ #: print-posts.php:72
53
+ #, php-format
54
+ msgid "%s @ %s"
55
+ msgstr ""
56
+
57
+ #: print-comments.php:30
58
+ msgid "Your comment is awaiting moderation."
59
  msgstr ""
60
 
61
  #: print-options.php:46
62
+ #: print-options.php:132
63
+ #: print-options.php:195
64
  msgid "Print Options"
65
  msgstr ""
66
 
72
  msgid "No Print Option Updated"
73
  msgstr ""
74
 
75
+ #: print-options.php:62
76
+ #: print-options.php:295
77
  msgid "UNINSTALL WP-Print"
78
  msgstr ""
79
 
80
+ #: print-options.php:70
81
  #, php-format
82
  msgid "Setting Key '%s' has been deleted."
83
  msgstr ""
84
 
85
+ #: print-options.php:74
86
  #, php-format
87
  msgid "Error deleting Setting Key '%s'."
88
  msgstr ""
89
 
90
+ #: print-options.php:95
91
+ #: print-options.php:263
92
  msgid "Uninstall WP-Print"
93
  msgstr ""
94
 
95
+ #: print-options.php:96
96
  #, php-format
97
  msgid "<a href=\"%s\">Click Here</a> To Finish The Uninstallation And WP-Print Will Be Deactivated Automatically."
98
  msgstr ""
99
 
100
+ #: print-options.php:122
101
+ #: wp-print.php:431
102
  #, php-format
103
  msgid "Copyright &copy; %s %s. All rights reserved."
104
  msgstr ""
140
  msgstr ""
141
 
142
  #: print-options.php:186
143
+ #: print-options.php:249
144
  msgid "HTML is allowed."
145
  msgstr ""
146
 
157
  msgstr ""
158
 
159
  #: print-options.php:190
160
+ #: print-options.php:246
161
  msgid "Restore Default Template"
162
  msgstr ""
163
 
164
+ #: print-options.php:198
165
  msgid "Print Comments?"
166
  msgstr ""
167
 
168
+ #: print-options.php:201
169
+ #: print-options.php:210
170
+ #: print-options.php:219
171
+ #: print-options.php:228
172
+ #: print-options.php:294
173
  msgid "Yes"
174
  msgstr ""
175
 
176
+ #: print-options.php:202
177
+ #: print-options.php:211
178
+ #: print-options.php:220
179
+ #: print-options.php:229
180
  msgid "No"
181
  msgstr ""
182
 
183
+ #: print-options.php:207
184
  msgid "Print Links?"
185
  msgstr ""
186
 
187
+ #: print-options.php:216
188
  msgid "Print Images?"
189
  msgstr ""
190
 
191
+ #: print-options.php:225
192
+ msgid "Print Videos?"
193
+ msgstr ""
194
+
195
+ #: print-options.php:234
196
+ msgid "Text Direction?"
197
+ msgstr ""
198
+
199
+ #: print-options.php:237
200
+ msgid "Left To Right"
201
+ msgstr ""
202
+
203
+ #: print-options.php:238
204
+ msgid "Right To Left"
205
+ msgstr ""
206
+
207
+ #: print-options.php:244
208
  msgid "Disclaimer/Copyright Text?"
209
  msgstr ""
210
 
211
+ #: print-options.php:254
212
+ msgid "Save Changes"
213
  msgstr ""
214
 
215
+ #: print-options.php:265
216
  msgid "Deactivating WP-Print plugin does not remove any data that may have been created, such as the print options. To completely remove this plugin, you can uninstall it here."
217
  msgstr ""
218
 
219
+ #: print-options.php:268
220
  msgid "WARNING:"
221
  msgstr ""
222
 
223
+ #: print-options.php:269
224
  msgid "Once uninstalled, this cannot be undone. You should use a Database Backup plugin of WordPress to back up all the data first."
225
  msgstr ""
226
 
227
+ #: print-options.php:272
228
  msgid "The following WordPress Options will be DELETED:"
229
  msgstr ""
230
 
231
+ #: print-options.php:277
232
  msgid "WordPress Options"
233
  msgstr ""
234
 
235
+ #: print-options.php:295
236
  msgid ""
237
  "You Are About To Uninstall WP-Print From WordPress.\\n"
238
  "This Action Is Not Reversible.\\n"
240
  " Choose [Cancel] To Stop, [OK] To Uninstall."
241
  msgstr ""
242
 
243
+ #: print-posts.php:72
244
+ msgid "Posted By"
 
 
 
 
 
 
 
 
 
245
  msgstr ""
246
 
247
+ #: print-posts.php:72
248
+ msgid "In"
249
  msgstr ""
250
 
251
+ #: print-posts.php:79
252
+ msgid "Article printed from"
253
  msgstr ""
254
 
255
+ #: print-posts.php:80
256
+ msgid "URL to article"
 
257
  msgstr ""
258
 
259
+ #: print-posts.php:84
260
+ msgid "Click"
261
  msgstr ""
262
 
263
+ #: print-posts.php:84
264
+ msgid "Click here to print."
265
  msgstr ""
266
 
267
+ #: print-posts.php:84
268
+ msgid "here"
269
  msgstr ""
270
 
271
+ #: print-posts.php:84
272
+ msgid "to print."
273
  msgstr ""
274
 
275
+ #: print-posts.php:86
276
+ msgid "No posts matched your criteria."
277
  msgstr ""
278
 
279
+ #: wp-print.php:42
280
+ msgid "Print"
281
  msgstr ""
282
 
283
+ #: wp-print.php:183
284
+ msgid "Note: There is a print link embedded within this post, please visit this post to print it."
285
  msgstr ""
286
 
287
+ #: wp-print.php:243
288
+ #: wp-print.php:311
289
+ msgid "Image"
290
  msgstr ""
291
 
292
+ #: wp-print.php:334
293
+ msgid "No Comments"
294
  msgstr ""
295
 
296
+ #: wp-print.php:336
297
+ msgid "1 Comment"
 
298
  msgstr ""
299
 
300
+ #: wp-print.php:338
 
301
  #, php-format
302
+ msgid "%s Comments"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
303
  msgstr ""
304
 
305
+ #: wp-print.php:341
306
+ msgid "Comments Disabled"
307
  msgstr ""
308
 
309
+ #: wp-print.php:344
310
+ msgid "Comments Hidden"
311
  msgstr ""
312
 
313
+ #: wp-print.php:355
314
+ msgid "URLs in this post:"
315
  msgstr ""
316
 
317
+ #: wp-print.php:422
318
+ msgid "Print This Post"
319
  msgstr ""
320
 
321
+ #: wp-print.php:423
322
+ msgid "Print This Page"
323
  msgstr ""
324