Post Thumbnail Editor - Version 1.0.4

Version Description

  • Added full paths to php includes
  • Fix handling for thumbnail names with spaces
  • Fix unlink/deletion issue
  • Added Portuguese translation
Download this release

Release Info

Developer sewpafly
Plugin Icon Post Thumbnail Editor
Version 1.0.4
Comparing to
See all releases

Code changes from version 1.0.3 to 1.0.4

README.txt CHANGED
@@ -2,7 +2,7 @@
2
  Contributors: sewpafly
3
  Donate link: https://www.wepay.com/donate/34543
4
  Tags: post-thumbnail, post thumbnail, featured image, featured, editor, image, awesome
5
- Requires at least: 3.2.1
6
  Tested up to: 3.2.1
7
  Stable tag: trunk
8
 
@@ -63,6 +63,12 @@ Using a version with [json_encode](http://www.php.net/manual/en/function.json-en
63
 
64
  == Changelog ==
65
 
 
 
 
 
 
 
66
  = 1.0.3 =
67
  * Fixed some javascript issues
68
  * Added Italian translation
@@ -92,6 +98,9 @@ Using a version with [json_encode](http://www.php.net/manual/en/function.json-en
92
 
93
  == Upgrade Notice ==
94
 
 
 
 
95
  = 1.0.3 =
96
  Fixed javascript problems & added italian translation
97
 
2
  Contributors: sewpafly
3
  Donate link: https://www.wepay.com/donate/34543
4
  Tags: post-thumbnail, post thumbnail, featured image, featured, editor, image, awesome
5
+ Requires at least: 3.2
6
  Tested up to: 3.2.1
7
  Stable tag: trunk
8
 
63
 
64
  == Changelog ==
65
 
66
+ = 1.0.4 =
67
+ * Added full paths to php includes
68
+ * Fix handling for thumbnail names with spaces
69
+ * Fix unlink/deletion issue
70
+ * Added Portuguese translation
71
+
72
  = 1.0.3 =
73
  * Fixed some javascript issues
74
  * Added Italian translation
98
 
99
  == Upgrade Notice ==
100
 
101
+ = 1.0.4 =
102
+ Bugfixes & portuguese translation
103
+
104
  = 1.0.3 =
105
  Fixed javascript problems & added italian translation
106
 
html/pte.php CHANGED
@@ -114,7 +114,7 @@
114
  <td class="col2">
115
  <div class="pte-size-label">${$index}</div>
116
  <img src="${$value.url}?${randomness()}"/>
117
- <input id="pte-${$index}-file" type="hidden" value="${$value.file}"/>
118
  </td>
119
  </tr>
120
  {{/each}}
@@ -140,13 +140,13 @@
140
  printf( __( 'Click %1$shere%2$s to modify another thumbnail.' , PTE_DOMAIN ), '<a href="" onclick="window.location.reload();">', '</a>' );
141
  ?></p>
142
  </div>
143
- {{if $data['error']}}
144
- <div id="error"><?php _e( 'We noticed some potential issues:', PTE_DOMAIN ); ?>
145
- <ul>
146
- {{each $data['error']}}<li>${$value}</li>{{/each}}
147
- </ul>
148
- </div>
149
- {{/if}}
150
  {{/if}}
151
  </script>
152
  <div id="pte-loading">
114
  <td class="col2">
115
  <div class="pte-size-label">${$index}</div>
116
  <img src="${$value.url}?${randomness()}"/>
117
+ <input class="pte-file" type="hidden" value="${$value.file}"/>
118
  </td>
119
  </tr>
120
  {{/each}}
140
  printf( __( 'Click %1$shere%2$s to modify another thumbnail.' , PTE_DOMAIN ), '<a href="" onclick="window.location.reload();">', '</a>' );
141
  ?></p>
142
  </div>
143
+ {{/if}}
144
+ {{if $data['error']}}
145
+ <div id="error"><?php _e( 'We noticed some potential issues:', PTE_DOMAIN ); ?>
146
+ <ul>
147
+ {{each $data['error']}}<li>${$value}</li>{{/each}}
148
+ </ul>
149
+ </div>
150
  {{/if}}
151
  </script>
152
  <div id="pte-loading">
i18n/post-thumbnail-editor-fr_FR.mo CHANGED
Binary file
i18n/post-thumbnail-editor-fr_FR.po CHANGED
@@ -8,7 +8,7 @@ msgstr ""
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
11
- "PO-Revision-Date: 2011-08-29 15:53+0100\n"
12
  "Last-Translator: Li-An <lian00@gmail.com>\n"
13
  "Language-Team: Li-An <lian00@gmail.com>\n"
14
  "X-Poedit-Language: French\n"
@@ -43,17 +43,18 @@ msgstr "Revenir en arrière"
43
  msgid "Post Thumbnail Editor - Step 2"
44
  msgstr "Post Thumbnail Editor - Étape 2"
45
 
46
- #: html/pte.php:83 html/pte.php:144
 
47
  msgid "We noticed some potential issues:"
48
  msgstr "Nous avons noté d'éventuels problèmes:"
49
 
50
  #: html/pte.php:86
51
  msgid "View %1$slogs%2$s for further information"
52
- msgstr ""
53
 
54
  #: html/pte.php:91
55
  msgid "%1$sEnable debugging%2$s for additional information"
56
- msgstr ""
57
 
58
  #: html/pte.php:101
59
  msgid "Select the images you want to keep: %1$sAll%2$s | %3$sNone%4$s"
@@ -69,8 +70,10 @@ msgstr "Je ferai mieux de recommencer..."
69
 
70
  #. #-#-#-#-# post-thumbnail-editor.pot (Post Thumbnail Editor 1.0.1-alpha2) #-#-#-#-#
71
  #. Plugin Name of the plugin/theme
72
- #: html/pte.php:135 post-thumbnail-editor.php:113
73
- #: post-thumbnail-editor.php:178 post-thumbnail-editor.php:179
 
 
74
  #: php/options.php:64
75
  msgid "Post Thumbnail Editor"
76
  msgstr "Post Thumbnail Editor"
@@ -91,15 +94,13 @@ msgstr "Veuillez attendre"
91
  msgid "Click here to show application logs"
92
  msgstr "Cliquez ici pour montrer les logs de l'application"
93
 
94
- #: html/pte.php:162 php/options.php:30
 
95
  msgid "Debug"
96
  msgstr "Debugger"
97
 
98
  #: html/pte.php:167
99
- msgid ""
100
- "If you are having any issues with this plugin, create a problem report on "
101
- "%1$sgithub%2$s or %3$swordpress.org%4$s so that I can look into it. Copy "
102
- "these log statements and include some information about what you were trying "
103
  msgstr "Si vous rencontrer des problèmes avec ce plugin, veuillez créer un rapport de problème à %1$sgithub%2$s ou %3$swordpress.org%4$s afin que je puisse le consulter. Veuillez copier ces états de log et inclure les informations sur ce que vous étiez en train de faire, ce que vous espériez obtenir, et ce qui en est résulté (plus il y aura d'informations, mieux ce sera). Merci et bonne chance !"
104
 
105
  #: html/pte.php:181
@@ -112,7 +113,7 @@ msgstr "Effacer les messages"
112
 
113
  #: html/pte.php:185
114
  msgid "Run Tests"
115
- msgstr ""
116
 
117
  #: html/pte.php:186
118
  msgid "Close"
@@ -122,7 +123,8 @@ msgstr "Fermer"
122
  msgid "Edit Thumbnails"
123
  msgstr "Éditer les miniatures"
124
 
125
- #: post-thumbnail-editor.php:168 php/options.php:51
 
126
  msgid "Thumbnails"
127
  msgstr "Miniatures"
128
 
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
11
+ "PO-Revision-Date: 2011-10-20 16:10+0100\n"
12
  "Last-Translator: Li-An <lian00@gmail.com>\n"
13
  "Language-Team: Li-An <lian00@gmail.com>\n"
14
  "X-Poedit-Language: French\n"
43
  msgid "Post Thumbnail Editor - Step 2"
44
  msgstr "Post Thumbnail Editor - Étape 2"
45
 
46
+ #: html/pte.php:83
47
+ #: html/pte.php:144
48
  msgid "We noticed some potential issues:"
49
  msgstr "Nous avons noté d'éventuels problèmes:"
50
 
51
  #: html/pte.php:86
52
  msgid "View %1$slogs%2$s for further information"
53
+ msgstr "Veuiller voir %1$slogs%2$s pour des informations complémentaires"
54
 
55
  #: html/pte.php:91
56
  msgid "%1$sEnable debugging%2$s for additional information"
57
+ msgstr "%1$sAutoriser le debuggage%2$s pour des informations complémentaires"
58
 
59
  #: html/pte.php:101
60
  msgid "Select the images you want to keep: %1$sAll%2$s | %3$sNone%4$s"
70
 
71
  #. #-#-#-#-# post-thumbnail-editor.pot (Post Thumbnail Editor 1.0.1-alpha2) #-#-#-#-#
72
  #. Plugin Name of the plugin/theme
73
+ #: html/pte.php:135
74
+ #: post-thumbnail-editor.php:113
75
+ #: post-thumbnail-editor.php:178
76
+ #: post-thumbnail-editor.php:179
77
  #: php/options.php:64
78
  msgid "Post Thumbnail Editor"
79
  msgstr "Post Thumbnail Editor"
94
  msgid "Click here to show application logs"
95
  msgstr "Cliquez ici pour montrer les logs de l'application"
96
 
97
+ #: html/pte.php:162
98
+ #: php/options.php:30
99
  msgid "Debug"
100
  msgstr "Debugger"
101
 
102
  #: html/pte.php:167
103
+ msgid "If you are having any issues with this plugin, create a problem report on %1$sgithub%2$s or %3$swordpress.org%4$s so that I can look into it. Copy these log statements and include some information about what you were trying "
 
 
 
104
  msgstr "Si vous rencontrer des problèmes avec ce plugin, veuillez créer un rapport de problème à %1$sgithub%2$s ou %3$swordpress.org%4$s afin que je puisse le consulter. Veuillez copier ces états de log et inclure les informations sur ce que vous étiez en train de faire, ce que vous espériez obtenir, et ce qui en est résulté (plus il y aura d'informations, mieux ce sera). Merci et bonne chance !"
105
 
106
  #: html/pte.php:181
113
 
114
  #: html/pte.php:185
115
  msgid "Run Tests"
116
+ msgstr "Lancer des tests"
117
 
118
  #: html/pte.php:186
119
  msgid "Close"
123
  msgid "Edit Thumbnails"
124
  msgstr "Éditer les miniatures"
125
 
126
+ #: post-thumbnail-editor.php:168
127
+ #: php/options.php:51
128
  msgid "Thumbnails"
129
  msgstr "Miniatures"
130
 
i18n/post-thumbnail-editor-pt_BR.mo ADDED
Binary file
i18n/post-thumbnail-editor-pt_BR.po ADDED
@@ -0,0 +1,254 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2010 Post Thumbnail Editor
2
+ # This file is distributed under the same license as the Post Thumbnail Editor package.
3
+ msgid ""
4
+ msgstr ""
5
+ "Project-Id-Version: Post Thumbnail Editor 1.0.3\n"
6
+ "Report-Msgid-Bugs-To: http://wordpress.org/tag/post-thumbnail-editor\n"
7
+ "POT-Creation-Date: 2011-09-08 15:17:02+00:00\n"
8
+ "PO-Revision-Date: 2011-09-28 15:00-0300\n"
9
+ "Last-Translator: \n"
10
+ "Language-Team: \n"
11
+ "MIME-Version: 1.0\n"
12
+ "Content-Type: text/plain; charset=UTF-8\n"
13
+ "Content-Transfer-Encoding: 8bit\n"
14
+
15
+ #: html/pte.php:20
16
+ msgid "Post Thumbnail Editor - Step 1"
17
+ msgstr "Editar Miniatura do Post - Passo 1"
18
+
19
+ #: html/pte.php:33
20
+ msgid "Create Thumbnails"
21
+ msgstr "Criar Thumbs"
22
+
23
+ #: html/pte.php:39
24
+ msgid "Choose the images/thumbnails that you want to edit:"
25
+ msgstr "Escolha as imagens/miniaturas que pretende editar:"
26
+
27
+ #: html/pte.php:42
28
+ msgid "Select: %1$sAll%2$s | %3$sNone%4$s"
29
+ msgstr "Selecione: %1$sTodas%2$s | %3$sNenhuma%4$s"
30
+
31
+ #: html/pte.php:59
32
+ msgid "Current image:"
33
+ msgstr "Imagem atual:"
34
+
35
+ #: html/pte.php:78
36
+ msgid "Back"
37
+ msgstr "Voltar"
38
+
39
+ #: html/pte.php:80
40
+ msgid "Post Thumbnail Editor - Step 2"
41
+ msgstr "Editar Miniatura do Post - Passo 2"
42
+
43
+ #: html/pte.php:83
44
+ #: html/pte.php:144
45
+ msgid "We noticed some potential issues:"
46
+ msgstr "Percebemos algumas questões importantes:"
47
+
48
+ #: html/pte.php:86
49
+ msgid "View %1$slogs%2$s for further information"
50
+ msgstr "Acesse %1$slogs%2$s para maiores informações"
51
+
52
+ #: html/pte.php:91
53
+ msgid "%1$sEnable debugging%2$s for additional information"
54
+ msgstr "%1$sHabilite o Debug%2$s para informações adicionais"
55
+
56
+ #: html/pte.php:101
57
+ msgid "Select the images you want to keep: %1$sAll%2$s | %3$sNone%4$s"
58
+ msgstr "Selecione as imagens que pretende manter: %1$sTodas%2$s | %3$sNenhuma%4$s"
59
+
60
+ #: html/pte.php:124
61
+ msgid "Okay, these look good..."
62
+ msgstr "Ok, parece que ficou bom..."
63
+
64
+ #: html/pte.php:128
65
+ msgid "I'd rather start over..."
66
+ msgstr "Eu odiei! Refazer..."
67
+
68
+ #. #-#-#-#-# post-thumbnail-editor.pot (Post Thumbnail Editor 1.0.3) #-#-#-#-#
69
+ #. Plugin Name of the plugin/theme
70
+ #: html/pte.php:135
71
+ #: php/options.php:64
72
+ #: post-thumbnail-editor.php:113
73
+ #: post-thumbnail-editor.php:178
74
+ #: post-thumbnail-editor.php:179
75
+ msgid "Post Thumbnail Editor"
76
+ msgstr "Post Thumbnail Editor"
77
+
78
+ msgid "Post Thumbnail Editor Here"
79
+ msgstr "Clique aqui para Editar a Miniatura"
80
+
81
+ #: html/pte.php:138
82
+ msgid "Images were created successfully."
83
+ msgstr "As Imagens foram geradas com sucesso."
84
+
85
+ #: html/pte.php:140
86
+ msgid "Click %1$shere%2$s to modify another thumbnail."
87
+ msgstr "Clique %1$saqui%2$s para modificar outra miniatura."
88
+
89
+ #: html/pte.php:156
90
+ msgid "Please wait"
91
+ msgstr "Aguarde por favor"
92
+
93
+ #: html/pte.php:160
94
+ msgid "Click here to show application logs"
95
+ msgstr "Clique aqui para visualizar os logs da aplicação"
96
+
97
+ #: html/pte.php:162
98
+ #: php/options.php:30
99
+ msgid "Debug"
100
+ msgstr "Debug"
101
+
102
+ #: html/pte.php:167
103
+ msgid "If you are having any issues with this plugin, create a problem report on %1$sgithub%2$s or %3$swordpress.org%4$s so that I can look into it. Copy these log statements and include some information about what you were trying to do, the expected output, and the output you got (the more information the better). Thanks and good luck!"
104
+ msgstr "Se você tiver algum problema ao utilizar este plugin, me informe detalhes sobre este BUG no %1$sgithub%2$s or %3$swordpress.org%4$s para eu dar uma olhada. Copiei os erros gerados pelo log e inclua o que e quando você tentou fazer que não deu certo bem detalhado (Em Inglês). Obrigado e boa sorte!"
105
+
106
+ #: html/pte.php:181
107
+ msgid "Send to Pastebin"
108
+ msgstr "Enviar para o site Pastebin"
109
+
110
+ #: html/pte.php:182
111
+ msgid "Clear Messages"
112
+ msgstr "Limpar Messagens"
113
+
114
+ #: html/pte.php:185
115
+ msgid "Run Tests"
116
+ msgstr "Rodar Testes"
117
+
118
+ #: html/pte.php:186
119
+ msgid "Close"
120
+ msgstr "Fechar"
121
+
122
+ #: php/functions.php:257
123
+ msgid "Sorry, there was a problem trying to send to pastebin"
124
+ msgstr "Deculpe, mas houve um problema ao tentar enviar para o pastebin"
125
+
126
+ #: php/functions.php:258
127
+ msgid "PASTEBIN URL:"
128
+ msgstr "URL do PASTEBIN:"
129
+
130
+ #: php/functions.php:259
131
+ msgid "Disabling aspect ratio"
132
+ msgstr "Desabilitando área de corte proporcional"
133
+
134
+ #: php/functions.php:260
135
+ msgid "Error parsing selection information"
136
+ msgstr "Erro na análise da informação de seleção"
137
+
138
+ #: php/functions.php:278
139
+ msgid "Invalid meta data for POST #%d: %s"
140
+ msgstr "dado inválido do POST #%d: %s"
141
+
142
+ #: php/functions.php:283
143
+ msgid "Please contact support"
144
+ msgstr "Favor contatar suporte"
145
+
146
+ #: php/log.php:15
147
+ msgid "ERROR"
148
+ msgstr "ERROR"
149
+
150
+ #: php/log.php:18
151
+ msgid "WARNING"
152
+ msgstr "WARNING"
153
+
154
+ #: php/log.php:21
155
+ msgid "DEBUG"
156
+ msgstr "DEBUG"
157
+
158
+ #: php/log.php:99
159
+ msgid "ERROR Logging Message: %s"
160
+ msgstr ""
161
+
162
+ #: php/options.php:8
163
+ msgid "These site-wide settings can only be changed by an administrator"
164
+ msgstr "Essas configurações do site só podem ser alteradas por um usuário administrador"
165
+
166
+ #: php/options.php:19
167
+ msgid "User Options"
168
+ msgstr "Opções de Usuário"
169
+
170
+ #: php/options.php:24
171
+ msgid "Thickbox dimensions"
172
+ msgstr "dimensões do Thickbox"
173
+
174
+ #: php/options.php:36
175
+ msgid "Reset to defaults"
176
+ msgstr "Resetar dados para padrão"
177
+
178
+ #: php/options.php:47
179
+ msgid "Site Options"
180
+ msgstr "Opções de Site"
181
+
182
+ #: php/options.php:51
183
+ #: post-thumbnail-editor.php:168
184
+ msgid "Thumbnails"
185
+ msgstr "Miniaturas"
186
+
187
+ #: php/options.php:72
188
+ msgid "Save Changes"
189
+ msgstr "Salvar Alterações"
190
+
191
+ #: php/options.php:86
192
+ msgid "Only users with the 'manage_options' capability may make changes to these settings."
193
+ msgstr "Somente os usuários com a capacidade de 'manage_options' podem fazer alterações a estas configurações."
194
+
195
+ #: php/options.php:118
196
+ msgid "Thickbox width must be at least 750 pixels."
197
+ msgstr "A largura do Thickbox deve ser no mínimo 750 px."
198
+
199
+ #: php/options.php:128
200
+ msgid "Thickbox height must be greater than 550 pixels."
201
+ msgstr "A altura do Thickbox deve ser maior que 550 px."
202
+
203
+ #: php/options.php:142
204
+ msgid "Width:"
205
+ msgstr "Largura:"
206
+
207
+ #: php/options.php:146
208
+ msgid "Set this to a value greater than 750."
209
+ msgstr "Defina em um valor maior que 750."
210
+
211
+ #: php/options.php:153
212
+ msgid "Height:"
213
+ msgstr "Altura:"
214
+
215
+ #: php/options.php:157
216
+ msgid "Set this to a value greater than 550."
217
+ msgstr "Defina em um valor maior que 550."
218
+
219
+ #: php/options.php:169
220
+ msgid "Enable debugging"
221
+ msgstr "Habilitar Debug"
222
+
223
+ #: php/options.php:178
224
+ msgid "Reset User Options"
225
+ msgstr "Resetar configurações de Usuário"
226
+
227
+ #: php/options.php:204
228
+ msgid "Post Thumbnail"
229
+ msgstr "Miniatura do Post"
230
+
231
+ #: php/options.php:205
232
+ msgid "Hidden"
233
+ msgstr "Ocultar"
234
+
235
+ #: post-thumbnail-editor.php:167
236
+ msgid "Edit Thumbnails"
237
+ msgstr "Editar Miniaturas"
238
+
239
+ #. Plugin URI of the plugin/theme
240
+ msgid "http://wordpress.org/extend/plugins/post-thumbnail-editor/"
241
+ msgstr ""
242
+
243
+ #. Description of the plugin/theme
244
+ msgid "Individually manage your post thumbnails"
245
+ msgstr "Gerenciar individualmente as miniaturas do post"
246
+
247
+ #. Author of the plugin/theme
248
+ msgid "sewpafly"
249
+ msgstr ""
250
+
251
+ #. Author URI of the plugin/theme
252
+ msgid "http://sewpafly.github.com/post-thumbnail-editor"
253
+ msgstr ""
254
+
i18n/post-thumbnail-editor.pot CHANGED
@@ -2,9 +2,9 @@
2
  # This file is distributed under the same license as the Post Thumbnail Editor package.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: Post Thumbnail Editor 1.0.3\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/post-thumbnail-editor\n"
7
- "POT-Creation-Date: 2011-09-08 15:17:02+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
@@ -40,7 +40,7 @@ msgstr ""
40
  msgid "Post Thumbnail Editor - Step 2"
41
  msgstr ""
42
 
43
- #: html/pte.php:83 html/pte.php:144
44
  msgid "We noticed some potential issues:"
45
  msgstr ""
46
 
@@ -64,10 +64,11 @@ msgstr ""
64
  msgid "I'd rather start over..."
65
  msgstr ""
66
 
67
- #. #-#-#-#-# post-thumbnail-editor.pot (Post Thumbnail Editor 1.0.3) #-#-#-#-#
68
  #. Plugin Name of the plugin/theme
69
- #: html/pte.php:135 php/options.php:64 post-thumbnail-editor.php:113
70
  #: post-thumbnail-editor.php:178 post-thumbnail-editor.php:179
 
71
  msgid "Post Thumbnail Editor"
72
  msgstr ""
73
 
@@ -116,28 +117,12 @@ msgstr ""
116
  msgid "Close"
117
  msgstr ""
118
 
119
- #: php/functions.php:257
120
- msgid "Sorry, there was a problem trying to send to pastebin"
121
- msgstr ""
122
-
123
- #: php/functions.php:258
124
- msgid "PASTEBIN URL:"
125
- msgstr ""
126
-
127
- #: php/functions.php:259
128
- msgid "Disabling aspect ratio"
129
- msgstr ""
130
-
131
- #: php/functions.php:260
132
- msgid "Error parsing selection information"
133
- msgstr ""
134
-
135
- #: php/functions.php:278
136
- msgid "Invalid meta data for POST #%d: %s"
137
  msgstr ""
138
 
139
- #: php/functions.php:283
140
- msgid "Please contact support"
141
  msgstr ""
142
 
143
  #: php/log.php:15
@@ -176,10 +161,6 @@ msgstr ""
176
  msgid "Site Options"
177
  msgstr ""
178
 
179
- #: php/options.php:51 post-thumbnail-editor.php:168
180
- msgid "Thumbnails"
181
- msgstr ""
182
-
183
  #: php/options.php:72
184
  msgid "Save Changes"
185
  msgstr ""
@@ -230,8 +211,28 @@ msgstr ""
230
  msgid "Hidden"
231
  msgstr ""
232
 
233
- #: post-thumbnail-editor.php:167
234
- msgid "Edit Thumbnails"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
235
  msgstr ""
236
 
237
  #. Plugin URI of the plugin/theme
2
  # This file is distributed under the same license as the Post Thumbnail Editor package.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: Post Thumbnail Editor 1.0.4-beta\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/post-thumbnail-editor\n"
7
+ "POT-Creation-Date: 2011-10-17 21:23:53+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
40
  msgid "Post Thumbnail Editor - Step 2"
41
  msgstr ""
42
 
43
+ #: html/pte.php:83 html/pte.php:145
44
  msgid "We noticed some potential issues:"
45
  msgstr ""
46
 
64
  msgid "I'd rather start over..."
65
  msgstr ""
66
 
67
+ #. #-#-#-#-# post-thumbnail-editor.pot (Post Thumbnail Editor 1.0.4-beta) #-#-#-#-#
68
  #. Plugin Name of the plugin/theme
69
+ #: html/pte.php:135 post-thumbnail-editor.php:113
70
  #: post-thumbnail-editor.php:178 post-thumbnail-editor.php:179
71
+ #: php/options.php:64
72
  msgid "Post Thumbnail Editor"
73
  msgstr ""
74
 
117
  msgid "Close"
118
  msgstr ""
119
 
120
+ #: post-thumbnail-editor.php:167
121
+ msgid "Edit Thumbnails"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
122
  msgstr ""
123
 
124
+ #: post-thumbnail-editor.php:168 php/options.php:51
125
+ msgid "Thumbnails"
126
  msgstr ""
127
 
128
  #: php/log.php:15
161
  msgid "Site Options"
162
  msgstr ""
163
 
 
 
 
 
164
  #: php/options.php:72
165
  msgid "Save Changes"
166
  msgstr ""
211
  msgid "Hidden"
212
  msgstr ""
213
 
214
+ #: php/functions.php:257
215
+ msgid "Sorry, there was a problem trying to send to pastebin"
216
+ msgstr ""
217
+
218
+ #: php/functions.php:258
219
+ msgid "PASTEBIN URL:"
220
+ msgstr ""
221
+
222
+ #: php/functions.php:259
223
+ msgid "Disabling aspect ratio"
224
+ msgstr ""
225
+
226
+ #: php/functions.php:260
227
+ msgid "Error parsing selection information"
228
+ msgstr ""
229
+
230
+ #: php/functions.php:278
231
+ msgid "Invalid meta data for POST #%d: %s"
232
+ msgstr ""
233
+
234
+ #: php/functions.php:283
235
+ msgid "Please contact support"
236
  msgstr ""
237
 
238
  #. Plugin URI of the plugin/theme
js/pte.coffee CHANGED
@@ -369,7 +369,7 @@ do (pte) ->
369
  thumbnail_data = {}
370
  $('input.pte-confirm').filter(':checked').each (i, elem) ->
371
  size = $(elem).val()
372
- thumbnail_data[size] = $("\#pte-#{ size }-file").val()
373
  submit_data =
374
  'id': $('#pte-post-id').val()
375
  'action': 'pte_ajax'
369
  thumbnail_data = {}
370
  $('input.pte-confirm').filter(':checked').each (i, elem) ->
371
  size = $(elem).val()
372
+ thumbnail_data[size] = $(elem).parent().parent().find('.pte-file').val()
373
  submit_data =
374
  'id': $('#pte-post-id').val()
375
  'action': 'pte_ajax'
js/pte.full.js CHANGED
@@ -1067,7 +1067,7 @@
1067
  $('input.pte-confirm').filter(':checked').each(function(i, elem) {
1068
  var size;
1069
  size = $(elem).val();
1070
- return thumbnail_data[size] = $("\#pte-" + size + "-file").val();
1071
  });
1072
  submit_data = {
1073
  'id': $('#pte-post-id').val(),
1067
  $('input.pte-confirm').filter(':checked').each(function(i, elem) {
1068
  var size;
1069
  size = $(elem).val();
1070
+ return thumbnail_data[size] = $(elem).parent().parent().find('.pte-file').val();
1071
  });
1072
  submit_data = {
1073
  'id': $('#pte-post-id').val(),
js/pte.full.min.js CHANGED
@@ -28,6 +28,6 @@ g.width>0&&g.height&&g.height>0&&b(".pte-size").filter(":checked").size()>0?b("#
28
  (log("DISABLE"),b("#pte-confirm").attr("disabled",!0));return!0},50);c=new r(function(){var a;a=null;b("input.pte-size").filter(":checked").each(function(c,g){try{a=w(a,thumbnail_info[b(g).val()])}catch(d){return a=null,a!==o.getOptions().aspectRatio&&alert(d),!1}return!0});s(a);p.onSelectEnd(null,o.getSelection());return!0},50);b.extend(a.functions,{pteVerifySubmitButtonHandler:g});b("input.pte-size").click(c.doFunc);return b(".pte-confirm").live("click",function(){return g.doFunc()})};i=function(){var c;
29
  b("#pte-submit").click(function(){var a,e;e=o.getSelection();a=b("#pte-sizer").val();a={id:b("#pte-post-id").val(),action:"pte_ajax","pte-action":"resize-images","pte-sizes[]":b(".pte-size").filter(":checked").map(function(){return b(this).val()}).get(),x:Math.floor(e.x1/a),y:Math.floor(e.y1/a),w:Math.floor(e.width/a),h:Math.floor(e.height/a)};log("===== RESIZE-IMAGES =====");log(a);if(isNaN(a.x)||isNaN(a.y)||isNaN(a.w)||isNaN(a.h))return alert(objectL10n.crop_submit_data_error),log("ERROR with submit_data and NaN's"),
30
  !1;o.setOptions({hide:!0,x1:0,y1:0,x2:0,y2:0});b("#pte-submit").attr("disabled",!0);b.getJSON(ajaxurl,a,c);return!0});return c=function(c){log("===== RESIZE-IMAGES SUCCESS =====");log(c);a.parseServerLog(c.log);if(c.error!=null&&c.thumbnails==null)alert(c.error);else return b("#stage1").moveLeft(),b("#stage2").html(b("#stage2template").tmpl(c)).moveLeft({callback:a.functions.pteVerifySubmitButtonHandler.doFunc}),!1}};k=function(){var c;b("#pte-confirm").live("click",function(){var a,e;e={};b("input.pte-confirm").filter(":checked").each(function(a,
31
- c){var d;d=b(c).val();return e[d]=b("#pte-"+d+"-file").val()});a={id:b("#pte-post-id").val(),action:"pte_ajax","pte-action":"confirm-images","pte-nonce":b("#pte-nonce").val(),"pte-confirm":e};log("===== CONFIRM-IMAGES =====");log(a);return b.getJSON(ajaxurl,a,c)});return c=function(c){log("===== CONFIRM-IMAGES SUCCESS =====");log(c);a.parseServerLog(c.log);b("#stage2").moveLeft();b("#stage3").html(b("#stage3template").tmpl(c)).moveLeft();return!1}};h=function(){var a,d;d=function(a){var e;var c,d;
32
- a!=null&&a.preventDefault();e=(c=(d=a.data)!=null?d.selector:void 0)!=null?c:".pte-size",a=e;return b(a).filter(":checked").click()};a=function(a){var e;var c,d;a!=null&&a.preventDefault();e=(c=a!=null?(d=a.data)!=null?d.selector:void 0:void 0)!=null?c:".pte-size",a=e;return b(a).not(":checked").click()};b("#pte-selectors .all").click(a);b("#pte-selectors .none").click(d).click();b("#stage2").delegate("#pte-stage2-selectors .all","click",{selector:".pte-confirm"},a);b("#stage2").delegate("#pte-stage2-selectors .none",
33
  "click",{selector:".pte-confirm"},d);return!0};return b.extend(a.functions,{iasSetAR:s})})(n)}).call(this);
28
  (log("DISABLE"),b("#pte-confirm").attr("disabled",!0));return!0},50);c=new r(function(){var a;a=null;b("input.pte-size").filter(":checked").each(function(c,g){try{a=w(a,thumbnail_info[b(g).val()])}catch(d){return a=null,a!==o.getOptions().aspectRatio&&alert(d),!1}return!0});s(a);p.onSelectEnd(null,o.getSelection());return!0},50);b.extend(a.functions,{pteVerifySubmitButtonHandler:g});b("input.pte-size").click(c.doFunc);return b(".pte-confirm").live("click",function(){return g.doFunc()})};i=function(){var c;
29
  b("#pte-submit").click(function(){var a,e;e=o.getSelection();a=b("#pte-sizer").val();a={id:b("#pte-post-id").val(),action:"pte_ajax","pte-action":"resize-images","pte-sizes[]":b(".pte-size").filter(":checked").map(function(){return b(this).val()}).get(),x:Math.floor(e.x1/a),y:Math.floor(e.y1/a),w:Math.floor(e.width/a),h:Math.floor(e.height/a)};log("===== RESIZE-IMAGES =====");log(a);if(isNaN(a.x)||isNaN(a.y)||isNaN(a.w)||isNaN(a.h))return alert(objectL10n.crop_submit_data_error),log("ERROR with submit_data and NaN's"),
30
  !1;o.setOptions({hide:!0,x1:0,y1:0,x2:0,y2:0});b("#pte-submit").attr("disabled",!0);b.getJSON(ajaxurl,a,c);return!0});return c=function(c){log("===== RESIZE-IMAGES SUCCESS =====");log(c);a.parseServerLog(c.log);if(c.error!=null&&c.thumbnails==null)alert(c.error);else return b("#stage1").moveLeft(),b("#stage2").html(b("#stage2template").tmpl(c)).moveLeft({callback:a.functions.pteVerifySubmitButtonHandler.doFunc}),!1}};k=function(){var c;b("#pte-confirm").live("click",function(){var a,e;e={};b("input.pte-confirm").filter(":checked").each(function(a,
31
+ c){var d;d=b(c).val();return e[d]=b(c).parent().parent().find(".pte-file").val()});a={id:b("#pte-post-id").val(),action:"pte_ajax","pte-action":"confirm-images","pte-nonce":b("#pte-nonce").val(),"pte-confirm":e};log("===== CONFIRM-IMAGES =====");log(a);return b.getJSON(ajaxurl,a,c)});return c=function(c){log("===== CONFIRM-IMAGES SUCCESS =====");log(c);a.parseServerLog(c.log);b("#stage2").moveLeft();b("#stage3").html(b("#stage3template").tmpl(c)).moveLeft();return!1}};h=function(){var a,d;d=function(a){var e;
32
+ var c,d;a!=null&&a.preventDefault();e=(c=(d=a.data)!=null?d.selector:void 0)!=null?c:".pte-size",a=e;return b(a).filter(":checked").click()};a=function(a){var e;var c,d;a!=null&&a.preventDefault();e=(c=a!=null?(d=a.data)!=null?d.selector:void 0:void 0)!=null?c:".pte-size",a=e;return b(a).not(":checked").click()};b("#pte-selectors .all").click(a);b("#pte-selectors .none").click(d).click();b("#stage2").delegate("#pte-stage2-selectors .all","click",{selector:".pte-confirm"},a);b("#stage2").delegate("#pte-stage2-selectors .none",
33
  "click",{selector:".pte-confirm"},d);return!0};return b.extend(a.functions,{iasSetAR:s})})(n)}).call(this);
js/pte_admin.coffee CHANGED
@@ -62,7 +62,6 @@ do (pte) ->
62
  return false
63
 
64
  # Add convenience functions to menu
65
- #$editmenu.append $("""<a class="thickbox" href="#{ pte_url() }">#{ objectL10n.PTE }</a>""")
66
  $editmenu.append $getLink().click checkExistingThickbox
67
 
68
  injectPTE()
62
  return false
63
 
64
  # Add convenience functions to menu
 
65
  $editmenu.append $getLink().click checkExistingThickbox
66
 
67
  injectPTE()
php/functions.php CHANGED
@@ -3,7 +3,7 @@
3
  * TODO: add helper functions to get various links to different functions
4
  */
5
 
6
- require_once( "log.php" );
7
 
8
  function pte_require_json() {
9
  if ( function_exists( 'ob_start' ) ){
@@ -288,6 +288,7 @@ function pte_launch(){
288
  $logger->debug( "USER-AGENT: " . $_SERVER['HTTP_USER_AGENT'] );
289
  $logger->debug( "WORDPRESS: " . $GLOBALS['wp_version'] );
290
  $logger->debug( "SIZER: ${sizer}" );
 
291
 
292
  require( PTE_PLUGINPATH . "html/pte.php" );
293
  }
@@ -585,10 +586,18 @@ function pte_confirm_images(){
585
  $new_file = $dir
586
  . DIRECTORY_SEPARATOR
587
  . basename( $good_file );
588
- if ( isset( $data['file'] ) ){
589
  $old_file = $dir
590
  . DIRECTORY_SEPARATOR
591
- . $data['file'];
 
 
 
 
 
 
 
 
592
  }
593
 
594
  // Move good image
@@ -608,15 +617,6 @@ function pte_confirm_images(){
608
  );
609
  $logger->debug( "Updating '{$size}' metadata: " . print_r( $metadata['sizes'][$size], true ) );
610
  wp_update_attachment_metadata( $id, $metadata);
611
-
612
- // Delete/unlink old file
613
- if ( isset( $old_file )
614
- && $old_file !== $new_file
615
- && file_exists( $old_file ) )
616
- {
617
- $logger->debug( "Deleting old thumbnail: {$old_file}" );
618
- unlink( $old_file );
619
- }
620
  }
621
  // Delete tmpdir
622
  pte_rmdir( $PTE_TMP_DIR );
3
  * TODO: add helper functions to get various links to different functions
4
  */
5
 
6
+ require_once(PTE_PLUGINPATH . 'php/log.php');
7
 
8
  function pte_require_json() {
9
  if ( function_exists( 'ob_start' ) ){
288
  $logger->debug( "USER-AGENT: " . $_SERVER['HTTP_USER_AGENT'] );
289
  $logger->debug( "WORDPRESS: " . $GLOBALS['wp_version'] );
290
  $logger->debug( "SIZER: ${sizer}" );
291
+ $logger->debug( "META: " . print_r( $meta, true ) );
292
 
293
  require( PTE_PLUGINPATH . "html/pte.php" );
294
  }
586
  $new_file = $dir
587
  . DIRECTORY_SEPARATOR
588
  . basename( $good_file );
589
+ if ( isset( $data['current']['file'] ) ){
590
  $old_file = $dir
591
  . DIRECTORY_SEPARATOR
592
+ . $data['current']['file'];
593
+ }
594
+
595
+ // Delete/unlink old file
596
+ if ( isset( $old_file )
597
+ && file_exists( $old_file ) )
598
+ {
599
+ $logger->debug( "Deleting old thumbnail: {$old_file}" );
600
+ unlink( $old_file );
601
  }
602
 
603
  // Move good image
617
  );
618
  $logger->debug( "Updating '{$size}' metadata: " . print_r( $metadata['sizes'][$size], true ) );
619
  wp_update_attachment_metadata( $id, $metadata);
 
 
 
 
 
 
 
 
 
620
  }
621
  // Delete tmpdir
622
  pte_rmdir( $PTE_TMP_DIR );
post-thumbnail-editor.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin URI: http://wordpress.org/extend/plugins/post-thumbnail-editor/
4
  Author: sewpafly
5
  Author URI: http://sewpafly.github.com/post-thumbnail-editor
6
- Version: 1.0.3
7
  Description: Individually manage your post thumbnails
8
 
9
  LICENSE
@@ -35,7 +35,7 @@
35
  define( 'PTE_PLUGINURL', plugins_url(basename( dirname(__FILE__))) . "/");
36
  define( 'PTE_PLUGINPATH', dirname(__FILE__) . "/");
37
  define( 'PTE_DOMAIN', "post-thumbnail-editor");
38
- define( 'PTE_VERSION', "1.0.3");
39
 
40
  /*
41
  * Option Functionality
@@ -110,7 +110,7 @@ function pte_admin_media_scripts(){
110
  }
111
  wp_localize_script('pte'
112
  , 'objectL10n'
113
- , array('PTE' => __('Post Thumbnail Editor'))
114
  );
115
  add_action("admin_head","pte_enable_admin_js",100);
116
  }
3
  Plugin URI: http://wordpress.org/extend/plugins/post-thumbnail-editor/
4
  Author: sewpafly
5
  Author URI: http://sewpafly.github.com/post-thumbnail-editor
6
+ Version: 1.0.4
7
  Description: Individually manage your post thumbnails
8
 
9
  LICENSE
35
  define( 'PTE_PLUGINURL', plugins_url(basename( dirname(__FILE__))) . "/");
36
  define( 'PTE_PLUGINPATH', dirname(__FILE__) . "/");
37
  define( 'PTE_DOMAIN', "post-thumbnail-editor");
38
+ define( 'PTE_VERSION', "1.0.4");
39
 
40
  /*
41
  * Option Functionality
110
  }
111
  wp_localize_script('pte'
112
  , 'objectL10n'
113
+ , array('PTE' => __('Post Thumbnail Editor', PTE_DOMAIN))
114
  );
115
  add_action("admin_head","pte_enable_admin_js",100);
116
  }