Revision Control - Version 1.9.1

Version Description

Download this release

Release Info

Developer dd32
Plugin Icon wp plugin Revision Control
Version 1.9.1
Comparing to
See all releases

Code changes from version 1.8 to 1.9.1

inc/class.dd32.php ADDED
@@ -0,0 +1,117 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( 3 >= $GLOBALS['dd32_version'] && !class_exists('DD32') ) {
3
+ class DD32 {
4
+ var $version = 3;
5
+ function DD32() {
6
+
7
+ }
8
+
9
+ //$folder = Full path to folder
10
+ function find_files( $folder, $args = array() ) {
11
+
12
+ $folder = untrailingslashit($folder);
13
+
14
+ $defaults = array( 'pattern' => '', 'levels' => 100, 'relative' => '' );
15
+ $r = wp_parse_args($args, $defaults);
16
+
17
+ extract($r, EXTR_SKIP);
18
+
19
+ //Now for recursive calls, clear relative, we'll handle it, and decrease the levels.
20
+ unset($r['relative']);
21
+ --$r['levels'];
22
+
23
+ if ( ! $levels )
24
+ return array();
25
+
26
+ if ( ! is_readable($folder) )
27
+ return false;
28
+
29
+ $files = array();
30
+ if ( $dir = @opendir( $folder ) ) {
31
+ while ( ( $file = readdir($dir) ) !== false ) {
32
+ if ( in_array($file, array('.', '..') ) )
33
+ continue;
34
+ if ( is_dir( $folder . '/' . $file ) ) {
35
+ $files2 = DD32::find_files( $folder . '/' . $file, $r );
36
+ if( $files2 )
37
+ $files = array_merge($files, $files2 );
38
+ else if ( empty($pattern) || preg_match('|^' . str_replace('\*', '\w+', preg_quote($pattern)) . '$|i', $file) )
39
+ $files[] = $folder . '/' . $file . '/';
40
+ } else {
41
+ if ( empty($pattern) || preg_match('|^' . str_replace('\*', '\w+', preg_quote($pattern)) . '$|i', $file) )
42
+ $files[] = $folder . '/' . $file;
43
+ }
44
+ }
45
+ }
46
+ @closedir( $dir );
47
+
48
+ if ( ! empty($relative) ) {
49
+ $relative = trailingslashit($relative);
50
+ foreach ( $files as $key => $file )
51
+ $files[$key] = preg_replace('!^' . preg_quote($relative) . '!', '', $file);
52
+ }
53
+
54
+ return $files;
55
+ }
56
+
57
+ function add_configure($plugin, $title, $url, $args = array() ) {
58
+ $defaults = array( 'class' => '', 'title' => $title );
59
+ $r = wp_parse_args($args, $defaults);
60
+ $link = "<a href='$url' class='{$r['class']}' title='{$r['title']}'>$title</a>";
61
+ add_action("plugin_action_links_$plugin", create_function('$links', 'return array_merge( array("' . $link . '"), $links);'));
62
+ }
63
+
64
+ //Function adds a list of changes after the plugin in the plugins table.
65
+ function add_changelog($plugin, $url) {
66
+ add_action("after_plugin_row_$plugin", create_function('$data', 'DD32::add_changelog_rows("' . $plugin .'", "' . $url . '", $data);'), 10, 2);
67
+ }
68
+ function add_changelog_rows($plugin, $url, $plugin_data) {
69
+
70
+ if ( false === get_option('dd32_changelogs', false) )
71
+ add_option('dd32_changelogs', array(), '', 'no'); //Add a no-auto-load option.
72
+
73
+ $update = get_option('update_plugins');
74
+ if ( ! isset($update->response[$plugin]) )
75
+ return;
76
+
77
+ $changelogs = get_option('dd32_changelogs', array());
78
+ if ( ! isset($changelogs[$url]) || !isset($changelogs[$url]['time']) || $changelogs[$url]['time'] < time()-24*60*60 ) {
79
+ $log = wp_remote_get($url);
80
+ if ( $log['response']['code'] != 200 )
81
+ return;
82
+ if ( ! preg_match('!== Changelog ==\s+(.*?)\s+(==|$)!is', $log['body'], $mat) )
83
+ return;
84
+ $mat = preg_split('!^=!im', $mat[1]);
85
+ $changes = array();
86
+ foreach ( (array)$mat as $version ) {
87
+ if ( preg_match('!^\s+([\w.]+)\s*=!i', $version, $mat_version) )
88
+ $change_version = $mat_version[1];
89
+ else
90
+ $change_version = 'unknown';
91
+
92
+ if ( preg_match_all('!^\s*[*](.*)$!im', $version, $mat_changes) )
93
+ foreach ( (array)$mat_changes[1] as $change )
94
+ $changes[ $change_version ][] = trim($change);
95
+ }
96
+
97
+ $changelogs[ $url ] = array('time' => time(), 'changes' => $changes);
98
+ update_option('dd32_changelogs', $changelogs);
99
+ } else {
100
+ $changes = $changelogs[ $url ]['changes'];
101
+ }
102
+
103
+ foreach ( (array) $changes as $version => $changelog_item ) {
104
+ if ( version_compare($version, $plugin_data['Version'], '<=') && 'unknown' != $version )
105
+ continue;
106
+ echo '
107
+ <tr>
108
+ <td colspan="2" class="plugin-update">&nbsp;</td>
109
+ <td class="plugin-update">' . $version . '</td>
110
+ <td colspan="2" class="plugin-update" style="text-align: left;"><ol style="list-style:circle"><li>' . implode('</li><li>', $changelog_item) .'</li></ol></td>
111
+ </tr>
112
+ ';
113
+ }
114
+ }
115
+
116
+ }}
117
+ ?>
langs/revision-control-es_ES.mo ADDED
Binary file
langs/revision-control-es_ES.po ADDED
@@ -0,0 +1,207 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ msgid ""
2
+ msgstr ""
3
+ "Project-Id-Version: \n"
4
+ "Report-Msgid-Bugs-To: \n"
5
+ "POT-Creation-Date: 2008-10-01 19:22+1000\n"
6
+ "PO-Revision-Date: 2008-10-01 19:22+1000\n"
7
+ "Last-Translator: Dion Hulse <contact@dd32.id.au>\n"
8
+ "Language-Team: SteAgl <stefano.aglietti@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
+ "Plural-Forms: nplurals=2; plural=n != 1;\n"
13
+ "X-Poedit-Language: Italian\n"
14
+ "X-Poedit-Country: ITALY\n"
15
+ "X-Poedit-SourceCharset: utf-8\n"
16
+ "X-Poedit-KeywordsList: __;_e\n"
17
+ "X-Poedit-Basepath: ../\n"
18
+ "X-Poedit-SearchPath-0: .\n"
19
+
20
+ #: revision-control.php:38
21
+ #: revision-control.php:151
22
+ #: revision-control.php:294
23
+ msgid "Revisions"
24
+ msgstr "Revisiones"
25
+
26
+ #: revision-control.php:41
27
+ #: revision-control.php:337
28
+ msgid "Revision Control"
29
+ msgstr "Control de Revisiones"
30
+
31
+ #: revision-control.php:142
32
+ msgid "Post Revisions"
33
+ msgstr "Revisiones de Entrada"
34
+
35
+ #: revision-control.php:153
36
+ #: revision-control.php:347
37
+ #: revision-control.php:368
38
+ msgid "Enabled"
39
+ msgstr "Activado"
40
+
41
+ #: revision-control.php:154
42
+ #: revision-control.php:157
43
+ #: revision-control.php:165
44
+ msgid " (default)"
45
+ msgstr " (por defecto)"
46
+
47
+ #: revision-control.php:156
48
+ #: revision-control.php:350
49
+ #: revision-control.php:371
50
+ msgid "Disabled"
51
+ msgstr "Desactivado"
52
+
53
+ #: revision-control.php:164
54
+ #: revision-control.php:357
55
+ #: revision-control.php:377
56
+ #, php-format
57
+ msgid "Limit to %d Revisions"
58
+ msgstr "Limitar a %d Revisiones"
59
+
60
+ #: revision-control.php:262
61
+ msgid "Are you sure you wish to delete this Revision?"
62
+ msgstr "¿Estás seguro de querer eliminar esta Revisión?"
63
+
64
+ #: revision-control.php:262
65
+ msgid "(delete)"
66
+ msgstr "(borrar)"
67
+
68
+ #: revision-control.php:329
69
+ msgid "Settings saved."
70
+ msgstr "Preferencias guardadas."
71
+
72
+ #: revision-control.php:334
73
+ msgid "<strong>Error:</strong> You have defined <code>WP_POST_REVISIONS</code> in your <code>wp-config.php</code> file, In order to use this plugin you will need to remove it."
74
+ msgstr "<strong>Error:</strong> Has definido <code>WP_POST_REVISIONS</code> en tu fichero <code>wp-config.php</code>, para usar este plugin debes eliminar la definición del fichero."
75
+
76
+ #: revision-control.php:343
77
+ msgid "Default Revision Status for Posts"
78
+ msgstr "Estado por defecto de las revisiones en las entradas"
79
+
80
+ #: revision-control.php:364
81
+ msgid "Default Revision Status for Pages"
82
+ msgstr "Estado por defecto de las revisiones en las páginas"
83
+
84
+ #: revision-control.php:385
85
+ msgid "Save Changes"
86
+ msgstr "Guardar Cambios"
87
+
88
+ #~ msgid "Revisions:"
89
+ #~ msgstr "Revisioni:"
90
+ #~ msgid "Limit to"
91
+ #~ msgstr "Limitate a"
92
+ #~ msgid "<h1>Add From Server</h1> Sorry, This plugin requires WordPress 2.5+"
93
+ #~ msgstr ""
94
+ #~ "<h1>Aggiungi da server</h1> Questo plugin richiede almeno WordPress 2.5+"
95
+ #~ msgid "Add From Server"
96
+ #~ msgstr "Aggiungi da server"
97
+ #~ msgid "Import"
98
+ #~ msgstr "Importa"
99
+ #~ msgid "Filename"
100
+ #~ msgstr "Nome file"
101
+ #~ msgid "Parent Folder"
102
+ #~ msgstr "Cartella madre"
103
+ #~ msgid "Toggle All"
104
+ #~ msgstr "Cambia tutti"
105
+ #~ msgid ""
106
+ #~ "Note: Will not take effect if selected file is within an upload folder at "
107
+ #~ "present"
108
+ #~ msgstr ""
109
+ #~ "Nota: Non avrà effetto se i file selezionati sono al momento nelal "
110
+ #~ "cartella di upload"
111
+ #~ msgid "Do not add selected files to current post Gallery"
112
+ #~ msgstr ""
113
+ #~ "Non aggiungere i file selezionati alla Galleria dell'articolo corrente"
114
+ #~ msgid "Import selected files"
115
+ #~ msgstr "Importa i file selezionati"
116
+ #~ msgid "<em>%s</em> has been added to Media library"
117
+ #~ msgstr "<em>%s</em> è statp aggiunto alla Libreria media"
118
+ #~ msgid "The uploaded file could not be moved to %s."
119
+ #~ msgstr "I file caricati non possono venir spostati in %s."
120
+ #~ msgid ""
121
+ #~ "Once you have selected files to be imported, Head over to the <a href=\"%s"
122
+ #~ "\">Media Library tab</a> to add them to your post."
123
+ #~ msgstr ""
124
+ #~ "Una volta selezionati i file da importare, andare sulla <a href=\"%s"
125
+ #~ "\">linguetta Libreria media</a> per aggiungerli al proprio articolo."
126
+ #~ msgid "Current Directory"
127
+ #~ msgstr "Directory corrente"
128
+ #~ msgid "Security hash missing."
129
+ #~ msgstr "Has di sicurezza mancante."
130
+ #~ msgid "You don't have enough access rights."
131
+ #~ msgstr "Non disponi dei permessi di accesso."
132
+ #~ msgid "<h2>Set Up Your FeedBurner Feed</h2>"
133
+ #~ msgstr "<h2>Imposta il tuo feed FeedBurner</h2>"
134
+ #~ msgid ""
135
+ #~ "<p>This plugin makes it easy to redirect 100% of traffic for your feeds "
136
+ #~ "to a FeedBurner feed you have created. FeedBurner can then track all of "
137
+ #~ "your feed subscriber traffic and usage and apply a variety of features "
138
+ #~ "you choose to improve and enhance your original WordPress feed.</p>"
139
+ #~ msgstr ""
140
+ #~ "<p>Questo plugin rende semplicissimo reindirizzare il 100% del traffico "
141
+ #~ "dei vostri feed ad un feed FeedBurner da voi creato. FeedBurner può "
142
+ #~ "tenere traccia di tutto il traffico e l'utilizzo effettuato dagli "
143
+ #~ "abbonati al feed ed applicare una serie di funzioni a vostra scelta per "
144
+ #~ "migliorare e incrementare il feed originale WordPress.</p>"
145
+ #~ msgid "To get started,"
146
+ #~ msgstr "Per iniziare,"
147
+ #~ msgid "create a FeedBurner feed for "
148
+ #~ msgstr "crea un feed Feedburner per "
149
+ #~ msgid "This feed will handle all traffic for your posts."
150
+ #~ msgstr "Questo feed gestirà tutto il traffico per gli articoli."
151
+ #~ msgid ""
152
+ #~ "Once you have created your FeedBurner feed, enter its address into the "
153
+ #~ "field below"
154
+ #~ msgstr ""
155
+ #~ "Una volta creato il feed su FeedBurner, inserire il suo indirizzo nel "
156
+ #~ "campo seguente"
157
+ #~ msgid ""
158
+ #~ "Optional: If you also want to handle your WordPress comments feed using "
159
+ #~ "FeedBurner"
160
+ #~ msgstr ""
161
+ #~ "Opzionale: Se si desidera gestire anche il feed dei commenti di WordPress "
162
+ #~ "utilizzando FeedBurner"
163
+ #~ msgid ""
164
+ #~ "create a FeedBurner comments feed</a> and then enter its address below:"
165
+ #~ msgstr ""
166
+ #~ "crea un feed dei commenti su FeedBurner</a> e quindi inserisci "
167
+ #~ "l'indirizzo qui sotto:"
168
+ #~ msgid "Save"
169
+ #~ msgstr "Salva"
170
+ #~ msgid "Sorry, you are not allowed to access this page."
171
+ #~ msgstr "Non ti è permesso accedere a questa pagina."
172
+ #~ msgid "ShareThis Options"
173
+ #~ msgstr "Opzioni ShareThis"
174
+ #~ msgid ""
175
+ #~ "Where do I go to get the ShareThis Code?<br><br>You can configure your "
176
+ #~ "ShareThis widget using our customizing tool (and be sure to register to "
177
+ #~ "get tracking) located here: <a href=\"http://sharethis.com/publisher?"
178
+ #~ "type=wpplugin\">sharethis.com/publisher?type=wpplugin</a>"
179
+ #~ msgstr ""
180
+ #~ "Dove andare per ottenere il Codice ShareThis?<br><br>Puoi configurare il "
181
+ #~ "tuo widget ShareThis tramite il nostro strumento di personalizzazione (e "
182
+ #~ "assicurati di registrarti per avere accesso al tracking) che si trova "
183
+ #~ "qui: <a href=\"http://sharethis.com/publisher?type=wpplugin\">sharethis."
184
+ #~ "com/publisher?type=wpplugin</a>"
185
+ #~ msgid "Paste your widget code in here:"
186
+ #~ msgstr "Incolla qui il tuo codice del widget:"
187
+ #~ msgid "Automatically add ShareThis to your posts?*"
188
+ #~ msgstr "Aggiungi automaticamente ShareThis ai tuoi articoli?*"
189
+ #~ msgid "Automatically add ShareThis to your pages?*"
190
+ #~ msgstr "Aggiungi automaticamente ShareThis alle tue pagine?*"
191
+ #~ msgid "Yes"
192
+ #~ msgstr "Si"
193
+ #~ msgid "No"
194
+ #~ msgstr "No"
195
+ #~ msgid ""
196
+ #~ "* Note, if you turn this off, you will want to add the <a href=\"http://"
197
+ #~ "support.sharethis.com/publishers/publishers-faq/wordpress/66\">ShareThis "
198
+ #~ "template tag</a> to your theme."
199
+ #~ msgstr ""
200
+ #~ "* Nota, se disabiliti questa opzione, dovrai aggiungere il <a href="
201
+ #~ "\"http://support.sharethis.com/publishers/publishers-faq/wordpress/66"
202
+ #~ "\">marcatore dei tempate di ShareThis</a> al tuo tema."
203
+ #~ msgid "Update ShareThis Options"
204
+ #~ msgstr "Aggiorna opzioni ShareThis"
205
+ #~ msgid "ShareThis"
206
+ #~ msgstr "ShareThis"
207
+
langs/revision-control-lv.mo ADDED
Binary file
langs/revision-control-lv.po ADDED
@@ -0,0 +1,86 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ msgid ""
2
+ msgstr ""
3
+ "Project-Id-Version: Revision Control\n"
4
+ "Report-Msgid-Bugs-To: \n"
5
+ "POT-Creation-Date: 2008-12-03 22:24+1000\n"
6
+ "PO-Revision-Date: \n"
7
+ "Last-Translator: Dion Hulse <contact@dd32.id.au>\n"
8
+ "Language-Team: <contact@dd32.id.au>\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: French\n"
13
+ "X-Poedit-Country: Australia\n"
14
+ "X-Poedit-SourceCharset: utf-8\n"
15
+ "X-Poedit-Basepath: C:\\www\\wordpress\\wp-content\\plugins\\revision-control\n"
16
+ "X-Poedit-KeywordsList: __;_e\n"
17
+ "X-Poedit-SearchPath-0: .\n"
18
+
19
+ #: revision-control.php:38
20
+ #: revision-control.php:151
21
+ #: revision-control.php:294
22
+ msgid "Revisions"
23
+ msgstr "Revīzijas"
24
+
25
+ #: revision-control.php:41
26
+ #: revision-control.php:337
27
+ msgid "Revision Control"
28
+ msgstr "Revīziju kontrole"
29
+
30
+ #: revision-control.php:142
31
+ msgid "Post Revisions"
32
+ msgstr "Raksta revīzija"
33
+
34
+ #: revision-control.php:153
35
+ #: revision-control.php:347
36
+ #: revision-control.php:368
37
+ msgid "Enabled"
38
+ msgstr "Aktivizēta"
39
+
40
+ #: revision-control.php:154
41
+ #: revision-control.php:157
42
+ #: revision-control.php:165
43
+ msgid " (default)"
44
+ msgstr "(pamata)"
45
+
46
+ #: revision-control.php:156
47
+ #: revision-control.php:350
48
+ #: revision-control.php:371
49
+ msgid "Disabled"
50
+ msgstr "Deaktivizēta"
51
+
52
+ #: revision-control.php:164
53
+ #: revision-control.php:357
54
+ #: revision-control.php:377
55
+ #, php-format
56
+ msgid "Limit to %d Revisions"
57
+ msgstr "Saīsināt līdz %d revīzijām"
58
+
59
+ #: revision-control.php:262
60
+ msgid "Are you sure you wish to delete this Revision?"
61
+ msgstr "Vai esi pārliecināts, ka vēlies šo revīziju dzēst?"
62
+
63
+ #: revision-control.php:262
64
+ msgid "(delete)"
65
+ msgstr "(dzēst)"
66
+
67
+ #: revision-control.php:329
68
+ msgid "Settings saved."
69
+ msgstr "Uzstādījumi saglabāti."
70
+
71
+ #: revision-control.php:334
72
+ msgid "<strong>Error:</strong> You have defined <code>WP_POST_REVISIONS</code> in your <code>wp-config.php</code> file, In order to use this plugin you will need to remove it."
73
+ msgstr "<strong>Kļūda:</strong> Esi definējis <code>WP_POST_REVISIONS</code> savā <code>wp-config.php</code> failā, Lai lietotu šo spraudni, tas ir jāizņem."
74
+
75
+ #: revision-control.php:343
76
+ msgid "Default Revision Status for Posts"
77
+ msgstr "Pamata revīzijas statuss rakstiem"
78
+
79
+ #: revision-control.php:364
80
+ msgid "Default Revision Status for Pages"
81
+ msgstr "Pamata revīzijas statuss lapām"
82
+
83
+ #: revision-control.php:385
84
+ msgid "Save Changes"
85
+ msgstr "Saglabāt izmaiņas"
86
+
langs/revision-control-lv_LV.mo ADDED
Binary file
langs/revision-control-lv_LV.po ADDED
@@ -0,0 +1,86 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ msgid ""
2
+ msgstr ""
3
+ "Project-Id-Version: Revision Control\n"
4
+ "Report-Msgid-Bugs-To: \n"
5
+ "POT-Creation-Date: 2008-12-03 22:24+1000\n"
6
+ "PO-Revision-Date: \n"
7
+ "Last-Translator: Dion Hulse <contact@dd32.id.au>\n"
8
+ "Language-Team: <contact@dd32.id.au>\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: French\n"
13
+ "X-Poedit-Country: Australia\n"
14
+ "X-Poedit-SourceCharset: utf-8\n"
15
+ "X-Poedit-Basepath: C:\\www\\wordpress\\wp-content\\plugins\\revision-control\n"
16
+ "X-Poedit-KeywordsList: __;_e\n"
17
+ "X-Poedit-SearchPath-0: .\n"
18
+
19
+ #: revision-control.php:38
20
+ #: revision-control.php:151
21
+ #: revision-control.php:294
22
+ msgid "Revisions"
23
+ msgstr "Revīzijas"
24
+
25
+ #: revision-control.php:41
26
+ #: revision-control.php:337
27
+ msgid "Revision Control"
28
+ msgstr "Revīziju kontrole"
29
+
30
+ #: revision-control.php:142
31
+ msgid "Post Revisions"
32
+ msgstr "Raksta revīzija"
33
+
34
+ #: revision-control.php:153
35
+ #: revision-control.php:347
36
+ #: revision-control.php:368
37
+ msgid "Enabled"
38
+ msgstr "Aktivizēta"
39
+
40
+ #: revision-control.php:154
41
+ #: revision-control.php:157
42
+ #: revision-control.php:165
43
+ msgid " (default)"
44
+ msgstr "(pamata)"
45
+
46
+ #: revision-control.php:156
47
+ #: revision-control.php:350
48
+ #: revision-control.php:371
49
+ msgid "Disabled"
50
+ msgstr "Deaktivizēta"
51
+
52
+ #: revision-control.php:164
53
+ #: revision-control.php:357
54
+ #: revision-control.php:377
55
+ #, php-format
56
+ msgid "Limit to %d Revisions"
57
+ msgstr "Saīsināt līdz %d revīzijām"
58
+
59
+ #: revision-control.php:262
60
+ msgid "Are you sure you wish to delete this Revision?"
61
+ msgstr "Vai esi pārliecināts, ka vēlies šo revīziju dzēst?"
62
+
63
+ #: revision-control.php:262
64
+ msgid "(delete)"
65
+ msgstr "(dzēst)"
66
+
67
+ #: revision-control.php:329
68
+ msgid "Settings saved."
69
+ msgstr "Uzstādījumi saglabāti."
70
+
71
+ #: revision-control.php:334
72
+ msgid "<strong>Error:</strong> You have defined <code>WP_POST_REVISIONS</code> in your <code>wp-config.php</code> file, In order to use this plugin you will need to remove it."
73
+ msgstr "<strong>Kļūda:</strong> Esi definējis <code>WP_POST_REVISIONS</code> savā <code>wp-config.php</code> failā, Lai lietotu šo spraudni, tas ir jāizņem."
74
+
75
+ #: revision-control.php:343
76
+ msgid "Default Revision Status for Posts"
77
+ msgstr "Pamata revīzijas statuss rakstiem"
78
+
79
+ #: revision-control.php:364
80
+ msgid "Default Revision Status for Pages"
81
+ msgstr "Pamata revīzijas statuss lapām"
82
+
83
+ #: revision-control.php:385
84
+ msgid "Save Changes"
85
+ msgstr "Saglabāt izmaiņas"
86
+
langs/revision-control-tr_TR.mo ADDED
Binary file
langs/revision-control-tr_TR.po ADDED
@@ -0,0 +1,85 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ msgid ""
2
+ msgstr ""
3
+ "Project-Id-Version: Revision\n"
4
+ "Report-Msgid-Bugs-To: \n"
5
+ "POT-Creation-Date: 2008-10-17 14:48+1000\n"
6
+ "PO-Revision-Date: \n"
7
+ "Last-Translator: Dion Hulse <contact@dd32.id.au>\n"
8
+ "Language-Team: Semih Aksu (Seemsiyah) <systemcoder@windowslive.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: Turkish\n"
13
+ "X-Poedit-Country: TURKEY\n"
14
+ "X-Poedit-KeywordsList: _e;__\n"
15
+ "X-Poedit-Basepath: ../\n"
16
+ "X-Poedit-SearchPath-0: .\n"
17
+
18
+ #: revision-control.php:38
19
+ #: revision-control.php:151
20
+ #: revision-control.php:294
21
+ msgid "Revisions"
22
+ msgstr "Revizyonlar"
23
+
24
+ #: revision-control.php:41
25
+ #: revision-control.php:337
26
+ msgid "Revision Control"
27
+ msgstr "Revizyon Ayarları"
28
+
29
+ #: revision-control.php:142
30
+ msgid "Post Revisions"
31
+ msgstr "Yazı Revizyonları"
32
+
33
+ #: revision-control.php:153
34
+ #: revision-control.php:347
35
+ #: revision-control.php:368
36
+ msgid "Enabled"
37
+ msgstr "Aktif"
38
+
39
+ #: revision-control.php:154
40
+ #: revision-control.php:157
41
+ #: revision-control.php:165
42
+ msgid " (default)"
43
+ msgstr "(varsayılan)"
44
+
45
+ #: revision-control.php:156
46
+ #: revision-control.php:350
47
+ #: revision-control.php:371
48
+ msgid "Disabled"
49
+ msgstr "Devre dışı"
50
+
51
+ #: revision-control.php:164
52
+ #: revision-control.php:357
53
+ #: revision-control.php:377
54
+ #, php-format
55
+ msgid "Limit to %d Revisions"
56
+ msgstr "%d Revizyonla Sınırla"
57
+
58
+ #: revision-control.php:262
59
+ msgid "Are you sure you wish to delete this Revision?"
60
+ msgstr "Bu Revizyonu silmek istediğinize emin misiniz ?"
61
+
62
+ #: revision-control.php:262
63
+ msgid "(delete)"
64
+ msgstr "(sil)"
65
+
66
+ #: revision-control.php:329
67
+ msgid "Settings saved."
68
+ msgstr "Ayarlar kaydedildi."
69
+
70
+ #: revision-control.php:334
71
+ msgid "<strong>Error:</strong> You have defined <code>WP_POST_REVISIONS</code> in your <code>wp-config.php</code> file, In order to use this plugin you will need to remove it."
72
+ msgstr "<strong>Hata:</strong> <code>wp-config.php</code> dosyanızda, <code>WP_POST_REVISIONS</code> kodunu bulunduruyorsunuz. Bu eklentiyi kullanmak için gerekli alanı silmek zorundasınız."
73
+
74
+ #: revision-control.php:343
75
+ msgid "Default Revision Status for Posts"
76
+ msgstr "Yazılar için Varsayılan Revizyon Durumu"
77
+
78
+ #: revision-control.php:364
79
+ msgid "Default Revision Status for Pages"
80
+ msgstr "Sayfalar için Varsayılan Revizyon Durumu"
81
+
82
+ #: revision-control.php:385
83
+ msgid "Save Changes"
84
+ msgstr "Değişiklikleri Kaydet"
85
+
readme.txt CHANGED
@@ -1,9 +1,9 @@
1
  === Revision Control ===
2
  Contributors: dd32
3
- Tags: 2.6, revisions, post, admin
4
- Requires at least: 2.6
5
- Tested up to: 2.7-bleeding
6
- Stable tag: 1.8
7
 
8
  Revision Control allows finer control over the Post Revision system included with WordPress 2.6
9
 
@@ -20,6 +20,7 @@ The plugin also allows the deletion of specific revisions via the Revisions post
20
 
21
  = 1.0 =
22
  * Initial Release
 
23
  = 1.1, 1.2, 1.3 =
24
  * Italian & Japanese Translations
25
  * Allows Deletion of a Single revision via the Revisions post box
@@ -30,6 +31,7 @@ The plugin also allows the deletion of specific revisions via the Revisions post
30
  * Skipped 1.4
31
  * Sticking option values should finally be fixed.
32
  * Thanks to Translators, Apologies to Translators for releasing 1.5 with changes before getting updated lang files
 
33
  = 1.6 =
34
  * oops, Forgot something from 1.5: If you set the page/posts's option to the *same* as the default, Then the per-page option is now forgotten.
35
 
@@ -47,6 +49,14 @@ The plugin also allows the deletion of specific revisions via the Revisions post
47
  * Bug fix: Limit revisions dropdown sticks to 2 revisions on admin panel.
48
  * No features added.
49
 
 
 
 
 
 
 
 
 
50
  == Screenshots ==
51
 
52
  1. The Global Settings
1
  === Revision Control ===
2
  Contributors: dd32
3
+ Tags: 2.7, 2.6, revisions, post, admin
4
+ Requires at least: 2.7
5
+ Tested up to: 2.8
6
+ Stable tag: 1.9.1
7
 
8
  Revision Control allows finer control over the Post Revision system included with WordPress 2.6
9
 
20
 
21
  = 1.0 =
22
  * Initial Release
23
+
24
  = 1.1, 1.2, 1.3 =
25
  * Italian & Japanese Translations
26
  * Allows Deletion of a Single revision via the Revisions post box
31
  * Skipped 1.4
32
  * Sticking option values should finally be fixed.
33
  * Thanks to Translators, Apologies to Translators for releasing 1.5 with changes before getting updated lang files
34
+
35
  = 1.6 =
36
  * oops, Forgot something from 1.5: If you set the page/posts's option to the *same* as the default, Then the per-page option is now forgotten.
37
 
49
  * Bug fix: Limit revisions dropdown sticks to 2 revisions on admin panel.
50
  * No features added.
51
 
52
+ = 1.9 =
53
+ * Spanish Translation from Alejandro
54
+ * Turkish Translation from Semih
55
+ * Latvian Translation from Rolands
56
+ * Fix 'Disabled' per-object checkbox
57
+ * Introduce DD32's common data class, Adds Update version changelog functionality
58
+ * WP 2.7 compatibility, This is mainly a maintanence release until version 2.0 is fully finalised.
59
+
60
  == Screenshots ==
61
 
62
  1. The Global Settings
revision-control.php CHANGED
@@ -4,7 +4,7 @@ Plugin Name: Revision Control
4
  Plugin URI: http://dd32.id.au/wordpress-plugins/revision-control/
5
  Description: Allows finer control over the number of Revisions stored on a global & per-post/page basis.
6
  Author: Dion Hulse
7
- Version: 1.8
8
  */
9
 
10
  /**
@@ -23,6 +23,7 @@ function rc_loaded() {
23
 
24
  //Ok, Time to add Admin related hooks :)
25
  add_action('do_meta_boxes', 'rc_meta_box_manip', 15, 2);
 
26
 
27
  //Now the Defines.
28
  rc_define();
@@ -31,9 +32,9 @@ function rc_loaded() {
31
  /**
32
  * Add the Menu items. DOES NOT USE THE API; I'd like a bit better location than the end of the list.
33
  */
34
- add_action('admin_init', 'rc_admin_init');
35
  function rc_admin_init() {
36
  global $submenu;
 
37
  //Hack into the Menu ordering
38
  $submenu['options-general.php'][17] = array( __('Revisions', 'revision-control'),
39
  'manage_options',
@@ -57,11 +58,8 @@ function rc_admin_init() {
57
  */
58
  function rc_define() {
59
 
60
- $defaults = get_option('revision-control');
61
  if ( ! is_array($defaults) ) { //Upgrade from 1.0 to 1.1
62
- if ( false === $defaults )
63
- $defaults = true;
64
-
65
  $defaults = array('post' => $defaults, 'page' => $defaults);
66
  update_option('revision-control', $defaults);
67
  }
@@ -85,8 +83,8 @@ function rc_define() {
85
  //Eugh.. maybe_serialize() bug #7383 means integers/booleans are stored as string!
86
  if ( is_string($revision_status) ) {
87
  $revision_status = (int)$revision_status;
88
- if ( (bool) $revision_status == $revision_status )
89
- $revision_status = (bool)$revision_status;
90
  }
91
  }
92
  }
@@ -133,13 +131,18 @@ function rc_get_page_id() {
133
  */
134
  function rc_meta_box_manip($page, $context) {
135
  global $wp_meta_boxes;
136
- if ( 'advanced' != $context )
 
 
137
  return;
138
 
139
- if ( isset($wp_meta_boxes[ $page ][ $context ][ 'core' ][ 'revisionsdiv' ]) )
140
- $wp_meta_boxes[ $page ][ $context ][ 'core' ][ 'revisionsdiv' ]['callback'] = 'rc_revisions_meta_box';
 
 
 
141
  else
142
- add_meta_box('revisionsdiv', __('Post Revisions'), 'rc_revisions_meta_box', $page, $context, 'core');
143
  }
144
 
145
  /**
@@ -162,7 +165,7 @@ function rc_revisions_meta_box( $post ) {
162
  <?php for ( $i = 2; $i < 15; $i++ ) : ?>
163
  <option value="<?php echo $i ?>"<?php if ( WP_POST_REVISIONS === $i ) echo ' selected="selected"'
164
  ?>><?php printf( __('Limit to %d Revisions', 'revision-control'), $i);
165
- if ( RC_REVISION_DEFAULT == $i ) _e(' (default)', 'revision-control'); ?></option>
166
  <?php endfor; ?>
167
  </select>
168
  </label>
@@ -250,14 +253,13 @@ function rc_list_post_revisions( $post_id = 0 ) {
250
  foreach ( $revisions as $revision ) {
251
  if ( !current_user_can( 'read_post', $revision->ID ) )
252
  continue;
253
- if ( 'revision' === $revision->post_type && wp_is_post_autosave( $revision ) )
254
- continue;
255
 
256
  $date = wp_post_revision_title( $revision );
257
  $name = get_author_name( $revision->post_author );
258
 
259
  $title = sprintf( $titlef, $date, $name );
260
- if ( current_user_can( 'edit_post', $revision->ID ) ) {
 
261
  $url = wp_nonce_url('admin-post.php?action=delete-revision&revision=' . $revision->ID, 'delete_revision-' . $revision->ID);
262
  $title .= sprintf(' <a href="' . $url . '" onclick="return confirm(\'%s\')">%s</a>', js_escape(__('Are you sure you wish to delete this Revision?', 'revision-control')), __('(delete)', 'revision-control'));
263
  }
@@ -389,4 +391,35 @@ function rc_admin() {
389
  <?php
390
  }
391
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
392
  ?>
4
  Plugin URI: http://dd32.id.au/wordpress-plugins/revision-control/
5
  Description: Allows finer control over the number of Revisions stored on a global & per-post/page basis.
6
  Author: Dion Hulse
7
+ Version: 1.9.1
8
  */
9
 
10
  /**
23
 
24
  //Ok, Time to add Admin related hooks :)
25
  add_action('do_meta_boxes', 'rc_meta_box_manip', 15, 2);
26
+ add_action('admin_init', 'rc_admin_init');
27
 
28
  //Now the Defines.
29
  rc_define();
32
  /**
33
  * Add the Menu items. DOES NOT USE THE API; I'd like a bit better location than the end of the list.
34
  */
 
35
  function rc_admin_init() {
36
  global $submenu;
37
+
38
  //Hack into the Menu ordering
39
  $submenu['options-general.php'][17] = array( __('Revisions', 'revision-control'),
40
  'manage_options',
58
  */
59
  function rc_define() {
60
 
61
+ $defaults = get_option('revision-control', true);
62
  if ( ! is_array($defaults) ) { //Upgrade from 1.0 to 1.1
 
 
 
63
  $defaults = array('post' => $defaults, 'page' => $defaults);
64
  update_option('revision-control', $defaults);
65
  }
83
  //Eugh.. maybe_serialize() bug #7383 means integers/booleans are stored as string!
84
  if ( is_string($revision_status) ) {
85
  $revision_status = (int)$revision_status;
86
+ if ( 1 == $revision_status )
87
+ $revision_status = true;
88
  }
89
  }
90
  }
131
  */
132
  function rc_meta_box_manip($page, $context) {
133
  global $wp_meta_boxes;
134
+ $type = version_compare($GLOBALS['wp_version'], '2.6.999', '>') ? 'normal' : 'advanced';
135
+
136
+ if ( 'dashboard' == $page )
137
  return;
138
 
139
+ if ( $type != $context )
140
+ return;
141
+
142
+ if ( isset($wp_meta_boxes[ $page ][ $type ][ 'core' ][ 'revisionsdiv' ]) )
143
+ $wp_meta_boxes[ $page ][ $type ][ 'core' ][ 'revisionsdiv' ]['callback'] = 'rc_revisions_meta_box';
144
  else
145
+ add_meta_box('revisionsdiv', __('Post Revisions'), 'rc_revisions_meta_box', $page, $type, 'core');
146
  }
147
 
148
  /**
165
  <?php for ( $i = 2; $i < 15; $i++ ) : ?>
166
  <option value="<?php echo $i ?>"<?php if ( WP_POST_REVISIONS === $i ) echo ' selected="selected"'
167
  ?>><?php printf( __('Limit to %d Revisions', 'revision-control'), $i);
168
+ if ( RC_REVISION_DEFAULT === $i ) _e(' (default)', 'revision-control'); ?></option>
169
  <?php endfor; ?>
170
  </select>
171
  </label>
253
  foreach ( $revisions as $revision ) {
254
  if ( !current_user_can( 'read_post', $revision->ID ) )
255
  continue;
 
 
256
 
257
  $date = wp_post_revision_title( $revision );
258
  $name = get_author_name( $revision->post_author );
259
 
260
  $title = sprintf( $titlef, $date, $name );
261
+
262
+ if ( current_user_can( 'edit_post', $revision->ID ) && ! wp_is_post_autosave( $revision ) ) {
263
  $url = wp_nonce_url('admin-post.php?action=delete-revision&revision=' . $revision->ID, 'delete_revision-' . $revision->ID);
264
  $title .= sprintf(' <a href="' . $url . '" onclick="return confirm(\'%s\')">%s</a>', js_escape(__('Are you sure you wish to delete this Revision?', 'revision-control')), __('(delete)', 'revision-control'));
265
  }
391
  <?php
392
  }
393
 
394
+ class revision_control {
395
+ //Stub until 2.0 is finalised.
396
+ var $dd32_requires = 3;
397
+ var $basename = '';
398
+ var $folder = '';
399
+ var $version = '1.9';
400
+
401
+ function revision_control() {
402
+ //Set the directory of the plugin:
403
+ $this->basename = plugin_basename(__FILE__);
404
+ $this->folder = dirname($this->basename);
405
+
406
+ //Set the version of the DD32 library this plugin requires.
407
+ $GLOBALS['dd32_version'] = isset($GLOBALS['dd32_version']) ? max($GLOBALS['dd32_version'], $this->dd32_requires) : $this->dd32_requires;
408
+ add_action('init', array(&$this, 'load_dd32'), 20);
409
+
410
+ //Register general hooks.
411
+ add_action('admin_init', array(&$this, 'admin_init'));
412
+ }
413
+
414
+ function load_dd32() {
415
+ //Load common library
416
+ include 'inc/class.dd32.php';
417
+ }
418
+
419
+ function admin_init() {
420
+ DD32::add_changelog($this->basename, 'http://svn.wp-plugins.org/revision-control/trunk/readme.txt');
421
+ }
422
+ }
423
+ add_action('init', create_function('', '$GLOBALS["revision-control"] = new revision_control();'), 5);
424
+
425
  ?>