Last change
on this file since 31742 was
12819,
checked in by mistic100, 12 years ago
|
fix detection regex and watermark position
|
File size:
1.4 KB
|
Rev | Line | |
---|
[10337] | 1 | <?php |
---|
| 2 | load_plugin_lang('charlies_content'); |
---|
| 3 | |
---|
| 4 | switch ($PLUGIN_ACTION) { |
---|
[12819] | 5 | // Affichage simple de la configuration |
---|
| 6 | case 'read_config': |
---|
| 7 | // vérifie que ffmpeg est bien présent |
---|
| 8 | if (!file_exists('include/ffmpeg.exe') AND $plugin_config['active']) { |
---|
| 9 | $ERRORS['fatal'][] = 'charlies_content.error_ffmpeg'; |
---|
| 10 | } |
---|
| 11 | |
---|
| 12 | $PAGE['content'] .= ' |
---|
| 13 | <table> |
---|
| 14 | <tr> |
---|
| 15 | <td>'.l10n('charlies_content.video_time').' :</td> |
---|
| 16 | <td>'.bool_to_string($plugin_config['video_time']).($plugin_config['video_time']!=='rand' ? ' sec':'om').'</td> |
---|
| 17 | </tr> |
---|
| 18 | </table>'; |
---|
| 19 | break; |
---|
| 20 | |
---|
| 21 | |
---|
| 22 | // Actions avant enregistrement |
---|
| 23 | case 'save_config': |
---|
| 24 | if (!is_decimal($_POST['Plugins']['charlies_content']['video_time']) AND $_POST['Plugins']['charlies_content']['video_time'] != 'rand') { |
---|
| 25 | $_POST['Plugins']['charlies_content']['video_time'] = 'rand'; |
---|
| 26 | $ERRORS['conf'][] = array(l10n('charlies_content.video_time'), 'must_be_integer'); |
---|
| 27 | } |
---|
[10337] | 28 | |
---|
[12819] | 29 | break; |
---|
[10337] | 30 | |
---|
[12819] | 31 | |
---|
| 32 | // Formulaire d'édition |
---|
| 33 | case 'edit_config': |
---|
| 34 | $PAGE['content'] .=' |
---|
| 35 | <table> |
---|
| 36 | <tr> |
---|
| 37 | <td>'.l10n('charlies_content.video_time').' :</td> |
---|
| 38 | <td> |
---|
| 39 | <input type="text" name="Plugins[charlies_content][video_time]" value="'.$plugin_config['video_time'].'" size="3"/>sec |
---|
| 40 | <i>'.l10n('charlies_content.rand').'</i> |
---|
| 41 | </td> |
---|
| 42 | </tr> |
---|
| 43 | </table>'; |
---|
| 44 | break; |
---|
[10337] | 45 | } |
---|
| 46 | ?> |
---|
Note: See
TracBrowser
for help on using the repository browser.