@@ -1,52 +1,52 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | -define('_MD_A_MYBLOCKSADMIN_PERMUPDATED', 'Permissions updated successfully') ; |
|
| 4 | -define('_MD_A_MYBLOCKSADMIN_BLOCKADMIN', 'Blocks administration') ; |
|
| 5 | -define('_MD_A_MYBLOCKSADMIN_NAME', 'Name') ; |
|
| 6 | -define('_MD_A_MYBLOCKSADMIN_TITLE', 'Title') ; |
|
| 7 | -define('_MD_A_MYBLOCKSADMIN_SIDE', 'Side') ; |
|
| 8 | -define('_MD_A_MYBLOCKSADMIN_SBLEFT', 'o --- - Gauche') ; |
|
| 9 | -define('_MD_A_MYBLOCKSADMIN_SBRIGHT', '- --- o Droite') ; |
|
| 10 | -define('_MD_A_MYBLOCKSADMIN_CBLEFT', '- o-- - CENTRE-GAUCHE') ; |
|
| 11 | -define('_MD_A_MYBLOCKSADMIN_CBRIGHT', '- --o - CENTRE-DROIT') ; |
|
| 12 | -define('_MD_A_MYBLOCKSADMIN_CBCENTER', '- -o- - CENTRE') ; |
|
| 13 | -define('_MD_A_MYBLOCKSADMIN_VISIBLE', 'Visible') ; |
|
| 14 | -define('_MD_A_MYBLOCKSADMIN_WEIGHT', 'Ordre') ; |
|
| 15 | -define('_MD_A_MYBLOCKSADMIN_VISIBLEIN', 'Visible sur') ; |
|
| 16 | -define('_MD_A_MYBLOCKSADMIN_CONTENT', 'Contenu') ; |
|
| 17 | -define('_MD_A_MYBLOCKSADMIN_CAPT_USABLETAGS', 'Tags Utilisables') ; |
|
| 18 | -define('_MD_A_MYBLOCKSADMIN_FMT_TAGRULE', '%s sera remplaé par %s dans l\'affichage') ; |
|
| 19 | -define('_MD_A_MYBLOCKSADMIN_CTYPE', 'Type personnalisé') ; |
|
| 20 | -define('_MD_A_MYBLOCKSADMIN_EDITTPL', 'Editer le template') ; |
|
| 21 | -define('_MD_A_MYBLOCKSADMIN_OPTIONS', 'Option du Bloc') ; |
|
| 22 | -define('_MD_A_MYBLOCKSADMIN_BCACHETIME', 'Temps du Cache') ; |
|
| 23 | -define('_MD_A_MYBLOCKSADMIN_ACTION', 'Action') ; |
|
| 24 | -define('_MD_A_MYBLOCKSADMIN_DESCRIPTION', 'Description') ; |
|
| 25 | -define('_MD_A_MYBLOCKSADMIN_TOPPAGE', 'Top Page') ; |
|
| 26 | -define('_MD_A_MYBLOCKSADMIN_ALLPAGES', 'Toutes les Pages') ; |
|
| 27 | -define('_MD_A_MYBLOCKSADMIN_PERMFORM', 'Permissions') ; |
|
| 28 | -define('_MD_A_MYBLOCKSADMIN_PERM_MADMIN', 'Admin module') ; |
|
| 29 | -define('_MD_A_MYBLOCKSADMIN_PERM_MREAD', 'Accès module') ; |
|
| 30 | -define('_MD_A_MYBLOCKSADMIN_DBUPDATED', 'Mise à jour avec succès de la Base de données') ; |
|
| 31 | -define('_MD_A_MYBLOCKSADMIN_FMT_REMOVEBLOCK', '%s sera supprimé. Voulez-vous confirmer?') ; |
|
| 32 | - |
|
| 33 | - |
|
| 34 | -define('_MD_A_MYBLOCKSADMIN_CLONEFORM', 'Cloner le bloc') ; |
|
| 35 | -define('_MD_A_MYBLOCKSADMIN_NEWFORM', 'Créer un bloc') ; |
|
| 36 | -define('_MD_A_MYBLOCKSADMIN_EDITFORM', 'Editer un bloc') ; |
|
| 37 | - |
|
| 38 | -define('_MD_A_MYBLOCKSADMIN_LINK_FORCECLONE', 'Forcer clonage') ; |
|
| 39 | - |
|
| 40 | -define('_MD_A_MYBLOCKSADMIN_BTN_CLONE', 'Cloner') ; |
|
| 41 | -define('_MD_A_MYBLOCKSADMIN_BTN_NEW', 'Créer') ; |
|
| 42 | -define('_MD_A_MYBLOCKSADMIN_BTN_EDIT', 'Mise à jour') ; |
|
| 43 | - |
|
| 44 | -define('_MD_A_MYBLOCKSADMIN_CTYPE_HTML', 'Personnalisé (pleinn HTML)') ; |
|
| 45 | -define('_MD_A_MYBLOCKSADMIN_CTYPE_NOSMILE', 'Personnalisé (HTML+BBCODE+AutoLink)') ; |
|
| 46 | -define('_MD_A_MYBLOCKSADMIN_CTYPE_SMILE', 'Personnalisé (HTML+BBCODE+AutoLink+Smiley)') ; |
|
| 47 | -define('_MD_A_MYBLOCKSADMIN_CTYPE_PHP', 'Personnalisé (PHP eval())') ; |
|
| 48 | - |
|
| 49 | -define('_MD_A_MYBLOCKSADMIN_NOTICE4COMMONFCK', 'Si vous voulez utiliser l\'éditeur WYSIWYG, installez common / FCKeditor') ; |
|
| 3 | +define('_MD_A_MYBLOCKSADMIN_PERMUPDATED', 'Permissions updated successfully'); |
|
| 4 | +define('_MD_A_MYBLOCKSADMIN_BLOCKADMIN', 'Blocks administration'); |
|
| 5 | +define('_MD_A_MYBLOCKSADMIN_NAME', 'Name'); |
|
| 6 | +define('_MD_A_MYBLOCKSADMIN_TITLE', 'Title'); |
|
| 7 | +define('_MD_A_MYBLOCKSADMIN_SIDE', 'Side'); |
|
| 8 | +define('_MD_A_MYBLOCKSADMIN_SBLEFT', 'o --- - Gauche'); |
|
| 9 | +define('_MD_A_MYBLOCKSADMIN_SBRIGHT', '- --- o Droite'); |
|
| 10 | +define('_MD_A_MYBLOCKSADMIN_CBLEFT', '- o-- - CENTRE-GAUCHE'); |
|
| 11 | +define('_MD_A_MYBLOCKSADMIN_CBRIGHT', '- --o - CENTRE-DROIT'); |
|
| 12 | +define('_MD_A_MYBLOCKSADMIN_CBCENTER', '- -o- - CENTRE'); |
|
| 13 | +define('_MD_A_MYBLOCKSADMIN_VISIBLE', 'Visible'); |
|
| 14 | +define('_MD_A_MYBLOCKSADMIN_WEIGHT', 'Ordre'); |
|
| 15 | +define('_MD_A_MYBLOCKSADMIN_VISIBLEIN', 'Visible sur'); |
|
| 16 | +define('_MD_A_MYBLOCKSADMIN_CONTENT', 'Contenu'); |
|
| 17 | +define('_MD_A_MYBLOCKSADMIN_CAPT_USABLETAGS', 'Tags Utilisables'); |
|
| 18 | +define('_MD_A_MYBLOCKSADMIN_FMT_TAGRULE', '%s sera remplaé par %s dans l\'affichage'); |
|
| 19 | +define('_MD_A_MYBLOCKSADMIN_CTYPE', 'Type personnalisé'); |
|
| 20 | +define('_MD_A_MYBLOCKSADMIN_EDITTPL', 'Editer le template'); |
|
| 21 | +define('_MD_A_MYBLOCKSADMIN_OPTIONS', 'Option du Bloc'); |
|
| 22 | +define('_MD_A_MYBLOCKSADMIN_BCACHETIME', 'Temps du Cache'); |
|
| 23 | +define('_MD_A_MYBLOCKSADMIN_ACTION', 'Action'); |
|
| 24 | +define('_MD_A_MYBLOCKSADMIN_DESCRIPTION', 'Description'); |
|
| 25 | +define('_MD_A_MYBLOCKSADMIN_TOPPAGE', 'Top Page'); |
|
| 26 | +define('_MD_A_MYBLOCKSADMIN_ALLPAGES', 'Toutes les Pages'); |
|
| 27 | +define('_MD_A_MYBLOCKSADMIN_PERMFORM', 'Permissions'); |
|
| 28 | +define('_MD_A_MYBLOCKSADMIN_PERM_MADMIN', 'Admin module'); |
|
| 29 | +define('_MD_A_MYBLOCKSADMIN_PERM_MREAD', 'Accès module'); |
|
| 30 | +define('_MD_A_MYBLOCKSADMIN_DBUPDATED', 'Mise à jour avec succès de la Base de données'); |
|
| 31 | +define('_MD_A_MYBLOCKSADMIN_FMT_REMOVEBLOCK', '%s sera supprimé. Voulez-vous confirmer?'); |
|
| 32 | + |
|
| 33 | + |
|
| 34 | +define('_MD_A_MYBLOCKSADMIN_CLONEFORM', 'Cloner le bloc'); |
|
| 35 | +define('_MD_A_MYBLOCKSADMIN_NEWFORM', 'Créer un bloc'); |
|
| 36 | +define('_MD_A_MYBLOCKSADMIN_EDITFORM', 'Editer un bloc'); |
|
| 37 | + |
|
| 38 | +define('_MD_A_MYBLOCKSADMIN_LINK_FORCECLONE', 'Forcer clonage'); |
|
| 39 | + |
|
| 40 | +define('_MD_A_MYBLOCKSADMIN_BTN_CLONE', 'Cloner'); |
|
| 41 | +define('_MD_A_MYBLOCKSADMIN_BTN_NEW', 'Créer'); |
|
| 42 | +define('_MD_A_MYBLOCKSADMIN_BTN_EDIT', 'Mise à jour'); |
|
| 43 | + |
|
| 44 | +define('_MD_A_MYBLOCKSADMIN_CTYPE_HTML', 'Personnalisé (pleinn HTML)'); |
|
| 45 | +define('_MD_A_MYBLOCKSADMIN_CTYPE_NOSMILE', 'Personnalisé (HTML+BBCODE+AutoLink)'); |
|
| 46 | +define('_MD_A_MYBLOCKSADMIN_CTYPE_SMILE', 'Personnalisé (HTML+BBCODE+AutoLink+Smiley)'); |
|
| 47 | +define('_MD_A_MYBLOCKSADMIN_CTYPE_PHP', 'Personnalisé (PHP eval())'); |
|
| 48 | + |
|
| 49 | +define('_MD_A_MYBLOCKSADMIN_NOTICE4COMMONFCK', 'Si vous voulez utiliser l\'éditeur WYSIWYG, installez common / FCKeditor'); |
|
| 50 | 50 | |
| 51 | 51 | |
| 52 | 52 | // Group permission phrases |
@@ -1,11 +1,11 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | -define('_MD_A_MYTPLSFORM_TPLSADMIN', 'Templates') ; |
|
| 4 | -define('_MD_A_MYTPLSFORM_EDIT', 'Edition du template') ; |
|
| 5 | -define('_MD_A_MYTPLSFORM_UPDATED', 'Mise à jour avec succès du template') ; |
|
| 6 | -define('_MD_A_MYTPLSFORM_CREATED', 'Template créé avec succès') ; |
|
| 7 | -define('_MD_A_MYTPLSFORM_LABEL_TPLFILE', 'Nom du Template') ; |
|
| 8 | -define('_MD_A_MYTPLSFORM_BTN_MODIFYCONT', 'Renvoyer') ; |
|
| 9 | -define('_MD_A_MYTPLSFORM_BTN_MODIFYEND', 'Sauvegarder et Terminer') ; |
|
| 10 | -define('_MD_A_MYTPLSFORM_BTN_CREATE', 'Créer') ; |
|
| 11 | -define('_MD_A_MYTPLSFORM_BTN_RESET', 'Annuler') ; |
|
| 3 | +define('_MD_A_MYTPLSFORM_TPLSADMIN', 'Templates'); |
|
| 4 | +define('_MD_A_MYTPLSFORM_EDIT', 'Edition du template'); |
|
| 5 | +define('_MD_A_MYTPLSFORM_UPDATED', 'Mise à jour avec succès du template'); |
|
| 6 | +define('_MD_A_MYTPLSFORM_CREATED', 'Template créé avec succès'); |
|
| 7 | +define('_MD_A_MYTPLSFORM_LABEL_TPLFILE', 'Nom du Template'); |
|
| 8 | +define('_MD_A_MYTPLSFORM_BTN_MODIFYCONT', 'Renvoyer'); |
|
| 9 | +define('_MD_A_MYTPLSFORM_BTN_MODIFYEND', 'Sauvegarder et Terminer'); |
|
| 10 | +define('_MD_A_MYTPLSFORM_BTN_CREATE', 'Créer'); |
|
| 11 | +define('_MD_A_MYTPLSFORM_BTN_RESET', 'Annuler'); |
|
@@ -1,37 +1,37 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | -define('_MI_ALTSYS_MODULENAME', 'ALTSYS') ; |
|
| 4 | -define('_MI_ALTSYS_MODULEDESC', 'Gestion simplifiée du système') ; |
|
| 3 | +define('_MI_ALTSYS_MODULENAME', 'ALTSYS'); |
|
| 4 | +define('_MI_ALTSYS_MODULEDESC', 'Gestion simplifiée du système'); |
|
| 5 | 5 | |
| 6 | 6 | // menus |
| 7 | -define('_MI_ALTSYS_MENU_CUSTOMBLOCKS', 'Blocs personnalisés') ; |
|
| 8 | -define('_MI_ALTSYS_MENU_NEWCUSTOMBLOCK', 'Créer un Nouveau Bloc') ; |
|
| 9 | -define('_MI_ALTSYS_MENU_MYBLOCKSADMIN', 'Blocs des Modules') ; |
|
| 10 | -define('_MI_ALTSYS_MENU_MYTPLSADMIN', 'Templates') ; |
|
| 11 | -define('_MI_ALTSYS_MENU_COMPILEHOOKADMIN', 'Templates Advancés') ; |
|
| 12 | -define('_MI_ALTSYS_MENU_MYLANGADMIN', 'Langages') ; |
|
| 13 | -define('_MI_ALTSYS_MENU_ADVANCEDLANGADMIN', 'Langages Advancés') ; |
|
| 14 | -define('_MI_ALTSYS_MENU_MYAVATAR', 'Avatars') ; |
|
| 15 | -define('_MI_ALTSYS_MENU_MYSMILEY', 'Emoticones') ; |
|
| 7 | +define('_MI_ALTSYS_MENU_CUSTOMBLOCKS', 'Blocs personnalisés'); |
|
| 8 | +define('_MI_ALTSYS_MENU_NEWCUSTOMBLOCK', 'Créer un Nouveau Bloc'); |
|
| 9 | +define('_MI_ALTSYS_MENU_MYBLOCKSADMIN', 'Blocs des Modules'); |
|
| 10 | +define('_MI_ALTSYS_MENU_MYTPLSADMIN', 'Templates'); |
|
| 11 | +define('_MI_ALTSYS_MENU_COMPILEHOOKADMIN', 'Templates Advancés'); |
|
| 12 | +define('_MI_ALTSYS_MENU_MYLANGADMIN', 'Langages'); |
|
| 13 | +define('_MI_ALTSYS_MENU_ADVANCEDLANGADMIN', 'Langages Advancés'); |
|
| 14 | +define('_MI_ALTSYS_MENU_MYAVATAR', 'Avatars'); |
|
| 15 | +define('_MI_ALTSYS_MENU_MYSMILEY', 'Emoticones'); |
|
| 16 | 16 | |
| 17 | 17 | // blocks |
| 18 | -define('_MI_ALTSYS_BNAME_ADMIN_MENU', 'Menu Admin') ; |
|
| 18 | +define('_MI_ALTSYS_BNAME_ADMIN_MENU', 'Menu Admin'); |
|
| 19 | 19 | |
| 20 | 20 | // configs |
| 21 | -define('_MI_ALTSYS_ADMINMENU_HFT', 'Rewrite admin menu') ; |
|
| 22 | -define('_MI_ALTSYS_ADMINMENU_HFTDSC', 'If your admin menu is broken, remove cache/adminmenu.php. This feature works only with XOOPS 2.0.x') ; |
|
| 23 | -define('_MI_ALTSYS_AMHFT_OPT_2COL', 'Two columns of module icons') ; |
|
| 24 | -define('_MI_ALTSYS_AMHFT_OPT_NOIMG', 'IMG to TEXT') ; |
|
| 25 | -define('_MI_ALTSYS_AMHFT_OPT_XCSTY', 'Like XoopsCube Legacy 2.1') ; |
|
| 21 | +define('_MI_ALTSYS_ADMINMENU_HFT', 'Rewrite admin menu'); |
|
| 22 | +define('_MI_ALTSYS_ADMINMENU_HFTDSC', 'If your admin menu is broken, remove cache/adminmenu.php. This feature works only with XOOPS 2.0.x'); |
|
| 23 | +define('_MI_ALTSYS_AMHFT_OPT_2COL', 'Two columns of module icons'); |
|
| 24 | +define('_MI_ALTSYS_AMHFT_OPT_NOIMG', 'IMG to TEXT'); |
|
| 25 | +define('_MI_ALTSYS_AMHFT_OPT_XCSTY', 'Like XoopsCube Legacy 2.1'); |
|
| 26 | 26 | |
| 27 | -define('_MI_ALTSYS_ADMINMENU_IM', 'Copy mymenu links into admin menu') ; |
|
| 28 | -define('_MI_ALTSYS_ADMINMENU_IMDSC', 'If your admin menu is broken, remove cache/adminmenu.php. This feature works only with XOOPS 2.0.x') ; |
|
| 27 | +define('_MI_ALTSYS_ADMINMENU_IM', 'Copy mymenu links into admin menu'); |
|
| 28 | +define('_MI_ALTSYS_ADMINMENU_IMDSC', 'If your admin menu is broken, remove cache/adminmenu.php. This feature works only with XOOPS 2.0.x'); |
|
| 29 | 29 | |
| 30 | -define('_MI_ALTSYS_ADMIN_IN_THEME', 'Theme set for admin') ; |
|
| 31 | -define('_MI_ALTSYS_ADMIN_IN_THEMEDSC', 'Set the name of the theme displaying admin area. Insert a line just after including common.php in mainfile.php<br />include XOOPS_TRUST_PATH.\'/libs/altsys/include/admin_in_theme.inc.php\';<br /> to enable this. This feature works only with XOOPS 2.0.x') ; |
|
| 30 | +define('_MI_ALTSYS_ADMIN_IN_THEME', 'Theme set for admin'); |
|
| 31 | +define('_MI_ALTSYS_ADMIN_IN_THEMEDSC', 'Set the name of the theme displaying admin area. Insert a line just after including common.php in mainfile.php<br />include XOOPS_TRUST_PATH.\'/libs/altsys/include/admin_in_theme.inc.php\';<br /> to enable this. This feature works only with XOOPS 2.0.x'); |
|
| 32 | 32 | |
| 33 | -define('_MI_ALTSYS_ENABLEFORCECLONE', 'Forcer tous les blocs à CLONABLE') ; |
|
| 34 | -define('_MI_ALTSYS_ENABLEFORCECLONEDSC', 'Vous devriez savoir que l\'utilisation de multiples instances d\'un bloc sur une même page peut provoquer des erreurs d\'affichage') ; |
|
| 33 | +define('_MI_ALTSYS_ENABLEFORCECLONE', 'Forcer tous les blocs à CLONABLE'); |
|
| 34 | +define('_MI_ALTSYS_ENABLEFORCECLONEDSC', 'Vous devriez savoir que l\'utilisation de multiples instances d\'un bloc sur une même page peut provoquer des erreurs d\'affichage'); |
|
| 35 | 35 | |
| 36 | 36 | define('_MI_ALTSYS_IMAGES_DIR', 'Répertoire pour les fichiers image'); |
| 37 | 37 | define('_MI_ALTSYS_IMAGES_DIRDSC', 'chemin relatif dans le répertoire du module. par défaut: images'); |
@@ -1,4 +1,4 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | -define('_MD_A_MYPREFERENCES_FORMTITLE', 'Préférences Modules') ; |
|
| 4 | -define('_MD_A_MYPREFERENCES_UPDATED', 'Mise à jour avec succès des préférences') ; |
|
| 3 | +define('_MD_A_MYPREFERENCES_FORMTITLE', 'Préférences Modules'); |
|
| 4 | +define('_MD_A_MYPREFERENCES_UPDATED', 'Mise à jour avec succès des préférences'); |
|
@@ -1,27 +1,27 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | -define('_MYLANGADMIN_H3_MODULE', 'Module cible') ; |
|
| 4 | -define('_MYLANGADMIN_CACHEUPDATED', 'Le fichier de cache a été mis à jour') ; |
|
| 5 | -define('_MYLANGADMIN_BTN_UPDATE', 'Mise à jour') ; |
|
| 6 | -define('_MYLANGADMIN_BTN_RESET', 'réinitialiser') ; |
|
| 3 | +define('_MYLANGADMIN_H3_MODULE', 'Module cible'); |
|
| 4 | +define('_MYLANGADMIN_CACHEUPDATED', 'Le fichier de cache a été mis à jour'); |
|
| 5 | +define('_MYLANGADMIN_BTN_UPDATE', 'Mise à jour'); |
|
| 6 | +define('_MYLANGADMIN_BTN_RESET', 'réinitialiser'); |
|
| 7 | 7 | |
| 8 | -define('_MYLANGADMIN_TH_CONSTANTNAME', 'Nom de la Constante') ; |
|
| 9 | -define('_MYLANGADMIN_TH_DEFAULTVALUE', 'Valeur par défaut') ; |
|
| 10 | -define('_MYLANGADMIN_TH_USERVALUE', 'Valeur de Utilisateur') ; |
|
| 8 | +define('_MYLANGADMIN_TH_CONSTANTNAME', 'Nom de la Constante'); |
|
| 9 | +define('_MYLANGADMIN_TH_DEFAULTVALUE', 'Valeur par défaut'); |
|
| 10 | +define('_MYLANGADMIN_TH_USERVALUE', 'Valeur de Utilisateur'); |
|
| 11 | 11 | |
| 12 | -define('_MYLANGADMIN_NOTE_ADDEDBYMYLANG', '(constante ajoutée par utilisateur)') ; |
|
| 13 | -define('_MYLANGADMIN_DT_MYLANGFILENAME', 'Reécriture partielle du nom de fichier') ; |
|
| 12 | +define('_MYLANGADMIN_NOTE_ADDEDBYMYLANG', '(constante ajoutée par utilisateur)'); |
|
| 13 | +define('_MYLANGADMIN_DT_MYLANGFILENAME', 'Reécriture partielle du nom de fichier'); |
|
| 14 | 14 | |
| 15 | -define('_MYLANGADMIN_DT_CACHEFILENAME', 'Nom du fichier en Cache') ; |
|
| 16 | -define('_MYLANGADMIN_DT_CACHESTATUS', 'Mise en Cache du statut') ; |
|
| 17 | -define('_MYLANGADMIN_CREATED', 'Créé') ; |
|
| 18 | -define('_MYLANGADMIN_NOTCREATED', 'N\'a pas été créé pour l\'instant') ; |
|
| 15 | +define('_MYLANGADMIN_DT_CACHEFILENAME', 'Nom du fichier en Cache'); |
|
| 16 | +define('_MYLANGADMIN_DT_CACHESTATUS', 'Mise en Cache du statut'); |
|
| 17 | +define('_MYLANGADMIN_CREATED', 'Créé'); |
|
| 18 | +define('_MYLANGADMIN_NOTCREATED', 'N\'a pas été créé pour l\'instant'); |
|
| 19 | 19 | |
| 20 | -define('_MYLANGADMIN_ERR_MODNOLANGUAGE', 'Le module sélectionné n\'a pas de dossier de la langue') ; |
|
| 21 | -define('_MYLANGADMIN_ERR_MODLANGINCOMPATIBLE', 'Le module sélectionné a une structure incompatible') ; |
|
| 22 | -define('_MYLANGADMIN_ERR_MODEMPTYLANGDIR', 'Le module sélectionné n\'a pas de fichier langue de reécriture') ; |
|
| 20 | +define('_MYLANGADMIN_ERR_MODNOLANGUAGE', 'Le module sélectionné n\'a pas de dossier de la langue'); |
|
| 21 | +define('_MYLANGADMIN_ERR_MODLANGINCOMPATIBLE', 'Le module sélectionné a une structure incompatible'); |
|
| 22 | +define('_MYLANGADMIN_ERR_MODEMPTYLANGDIR', 'Le module sélectionné n\'a pas de fichier langue de reécriture'); |
|
| 23 | 23 | |
| 24 | -define('_MYLANGADMIN_MSG_D3LANGMANENABLED', 'Le système de reécriture est activé dès maintenant.') ; |
|
| 25 | -define('_MYLANGADMIN_FMT_HOWTOENABLED3LANGMAN4XCL', 'Le système de reécriture est désormais désactivé. Pour l\'activer, copiez "%s" dans "%s"') ; |
|
| 26 | -define('_MYLANGADMIN_MSG_HOWTOENABLED3LANGMAN4X2', 'Le système de reécriture ne peut pas fonctionner avec ce noyau de XOOPS, sauf quelques modules D3. Si vous souhaitez l\'activer avec ce noyau, essayez de modifier comme ceci:') ; |
|
| 27 | -define('_MYLANGADMIN_MSG_NOTICE4ALREADYREAD', 'Puisque ce fichier a déjà été lu par le système, cette colonne représente la valeur actuelle') ; |
|
| 24 | +define('_MYLANGADMIN_MSG_D3LANGMANENABLED', 'Le système de reécriture est activé dès maintenant.'); |
|
| 25 | +define('_MYLANGADMIN_FMT_HOWTOENABLED3LANGMAN4XCL', 'Le système de reécriture est désormais désactivé. Pour l\'activer, copiez "%s" dans "%s"'); |
|
| 26 | +define('_MYLANGADMIN_MSG_HOWTOENABLED3LANGMAN4X2', 'Le système de reécriture ne peut pas fonctionner avec ce noyau de XOOPS, sauf quelques modules D3. Si vous souhaitez l\'activer avec ce noyau, essayez de modifier comme ceci:'); |
|
| 27 | +define('_MYLANGADMIN_MSG_NOTICE4ALREADYREAD', 'Puisque ce fichier a déjà été lu par le système, cette colonne représente la valeur actuelle'); |
|
@@ -1,27 +1,27 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | -define('_MYTPLSADMIN_CREATE_NEW_TPLSET', 'Créer une nouvelle série') ; |
|
| 4 | -define('_MYTPLSADMIN_CAPTION_BASE', 'Base') ; |
|
| 5 | -define('_MYTPLSADMIN_CAPTION_SETNAME', 'nom') ; |
|
| 6 | -define('_MYTPLSADMIN_OPT_BLANKSET', '(vide)') ; |
|
| 7 | -define('_MYTPLSADMIN_CAPTION_COPYTO', 'à') ; |
|
| 8 | -define('_MYTPLSADMIN_BTN_COPY', 'COPIER') ; |
|
| 9 | -define('_MYTPLSADMIN_TITLE_CHECKALL', 'Activer / désactiver toutes les cases de cette ligne') ; |
|
| 10 | -define('_MYTPLSADMIN_CNF_DELETE_SELECTED_TEMPLATES', 'Tous les templates sélectionnés dans l\'ensemble (ligne) seront supprimés. Voulez-vous confirmer?') ; |
|
| 11 | -define('_MYTPLSADMIN_CNF_COPY_SELECTED_TEMPLATES', 'Tous les templates sélectionnés dans l\'ensemble (ligne) seront copiés/écrasé dans l\'ensemble sélectionné. Voulez-vous confirmer?') ; |
|
| 12 | -define('_MYTPLSADMIN_TH_NAME', 'Nom template name') ; |
|
| 13 | -define('_MYTPLSADMIN_TH_TYPE', 'type') ; |
|
| 14 | -define('_MYTPLSADMIN_TH_FILE', 'fichier source') ; |
|
| 15 | -define('_MYTPLSADMIN_ERR_NOTPLFILE', 'Aucun template sélectionné.') ; |
|
| 16 | -define('_MYTPLSADMIN_ERR_INVALIDTPLSET', "L\'ensemble de destination est le même que la source, ou aucun ensemble de templates n\'a été spécifié.") ; |
|
| 17 | -define('_MYTPLSADMIN_ERR_CANTREMOVEDEFAULT', "Vous ne pouvez pas supprimer l'ensemble 'default'.") ; |
|
| 18 | -define('_MYTPLSADMIN_ERR_DUPLICATEDSETNAME', "Ce nom d'ensemble de templates existe déjà.") ; |
|
| 19 | -define('_MYTPLSADMIN_ERR_INVALIDSETNAME', "un mauvais nom d'ensemble de templates a été spécifié.") ; |
|
| 3 | +define('_MYTPLSADMIN_CREATE_NEW_TPLSET', 'Créer une nouvelle série'); |
|
| 4 | +define('_MYTPLSADMIN_CAPTION_BASE', 'Base'); |
|
| 5 | +define('_MYTPLSADMIN_CAPTION_SETNAME', 'nom'); |
|
| 6 | +define('_MYTPLSADMIN_OPT_BLANKSET', '(vide)'); |
|
| 7 | +define('_MYTPLSADMIN_CAPTION_COPYTO', 'à'); |
|
| 8 | +define('_MYTPLSADMIN_BTN_COPY', 'COPIER'); |
|
| 9 | +define('_MYTPLSADMIN_TITLE_CHECKALL', 'Activer / désactiver toutes les cases de cette ligne'); |
|
| 10 | +define('_MYTPLSADMIN_CNF_DELETE_SELECTED_TEMPLATES', 'Tous les templates sélectionnés dans l\'ensemble (ligne) seront supprimés. Voulez-vous confirmer?'); |
|
| 11 | +define('_MYTPLSADMIN_CNF_COPY_SELECTED_TEMPLATES', 'Tous les templates sélectionnés dans l\'ensemble (ligne) seront copiés/écrasé dans l\'ensemble sélectionné. Voulez-vous confirmer?'); |
|
| 12 | +define('_MYTPLSADMIN_TH_NAME', 'Nom template name'); |
|
| 13 | +define('_MYTPLSADMIN_TH_TYPE', 'type'); |
|
| 14 | +define('_MYTPLSADMIN_TH_FILE', 'fichier source'); |
|
| 15 | +define('_MYTPLSADMIN_ERR_NOTPLFILE', 'Aucun template sélectionné.'); |
|
| 16 | +define('_MYTPLSADMIN_ERR_INVALIDTPLSET', "L\'ensemble de destination est le même que la source, ou aucun ensemble de templates n\'a été spécifié."); |
|
| 17 | +define('_MYTPLSADMIN_ERR_CANTREMOVEDEFAULT', "Vous ne pouvez pas supprimer l'ensemble 'default'."); |
|
| 18 | +define('_MYTPLSADMIN_ERR_DUPLICATEDSETNAME', "Ce nom d'ensemble de templates existe déjà."); |
|
| 19 | +define('_MYTPLSADMIN_ERR_INVALIDSETNAME', "un mauvais nom d'ensemble de templates a été spécifié."); |
|
| 20 | 20 | |
| 21 | -define('_MYTPLSADMIN_H3_MODULE', 'Module') ; |
|
| 22 | -define('_MYTPLSADMIN_BTN_NEWTPLSET', 'créer') ; |
|
| 21 | +define('_MYTPLSADMIN_H3_MODULE', 'Module'); |
|
| 22 | +define('_MYTPLSADMIN_BTN_NEWTPLSET', 'créer'); |
|
| 23 | 23 | |
| 24 | -define('_MYTPLSADMIN_DBUPDATED', 'Mise à jour avec succès des Templates') ; |
|
| 24 | +define('_MYTPLSADMIN_DBUPDATED', 'Mise à jour avec succès des Templates'); |
|
| 25 | 25 | |
| 26 | -define('_MYTPLSADMIN_CUSTOMTEMPLATE', 'Template personnalisé') ; |
|
| 27 | -define('_MYTPLSADMIN_CREATENEWCUSTOMTEMPLATE', 'Créer un nouveau template personnalisé') ; |
|
| 26 | +define('_MYTPLSADMIN_CUSTOMTEMPLATE', 'Template personnalisé'); |
|
| 27 | +define('_MYTPLSADMIN_CREATENEWCUSTOMTEMPLATE', 'Créer un nouveau template personnalisé'); |
|
@@ -178,7 +178,7 @@ discard block |
||
| 178 | 178 | altsys_include_mymenu() ; |
| 179 | 179 | |
| 180 | 180 | echo "<h3 style='text-align:"._GLOBAL_LEFT.";'>"._MD_A_MYTPLSFORM_EDIT . ' : ' . htmlspecialchars($tpl['tpl_type'], ENT_QUOTES) . ' : ' . htmlspecialchars($tpl['tpl_file'], ENT_QUOTES) . ' (' |
| 181 | - . htmlspecialchars($tpl['tpl_tplset'], ENT_QUOTES) . ")</h3>\n" ; |
|
| 181 | + . htmlspecialchars($tpl['tpl_tplset'], ENT_QUOTES) . ")</h3>\n" ; |
|
| 182 | 182 | |
| 183 | 183 | |
| 184 | 184 | // diff from file to selected DB template |
@@ -241,7 +241,7 @@ discard block |
||
| 241 | 241 | echo " |
| 242 | 242 | <a name='altsys_tplsform_top' id='altsys_tplsform_top'></a> |
| 243 | 243 | <form name='MainForm' id='altsys_tplsform' action='?mode=admin&lib=altsys&page=mytplsform&tpl_file=".htmlspecialchars($tpl_file, ENT_QUOTES) . '&tpl_tplset=' |
| 244 | - . htmlspecialchars($tpl['tpl_tplset'], ENT_QUOTES) . '&dirname=' . $target_mname . "' method='post'> |
|
| 244 | + . htmlspecialchars($tpl['tpl_tplset'], ENT_QUOTES) . '&dirname=' . $target_mname . "' method='post'> |
|
| 245 | 245 | ".$xoopsGTicket->getTicketHtml(__LINE__, 1800, 'altsys_tplsform')." |
| 246 | 246 | <textarea name='tpl_source' id='altsys_tpl_source' wrap='off' style='width:600px;height:400px;'>".htmlspecialchars($tpl['tpl_source'], ENT_QUOTES) . '</textarea> |
| 247 | 247 | <br /> |
@@ -5,36 +5,36 @@ discard block |
||
| 5 | 5 | // GIJOE <http://www.peak.ne.jp/> // |
| 6 | 6 | // ------------------------------------------------------------------------- // |
| 7 | 7 | |
| 8 | -require_once __DIR__.'/class/AltsysBreadcrumbs.class.php' ; |
|
| 9 | -include_once __DIR__ . '/include/gtickets.php'; |
|
| 10 | -include_once __DIR__.'/include/altsys_functions.php' ; |
|
| 11 | -include_once __DIR__ . '/include/tpls_functions.php'; |
|
| 12 | -include_once __DIR__.'/include/Text_Diff.php' ; |
|
| 13 | -include_once __DIR__.'/include/Text_Diff_Renderer.php' ; |
|
| 14 | -include_once __DIR__.'/include/Text_Diff_Renderer_unified.php' ; |
|
| 8 | +require_once __DIR__.'/class/AltsysBreadcrumbs.class.php'; |
|
| 9 | +include_once __DIR__.'/include/gtickets.php'; |
|
| 10 | +include_once __DIR__.'/include/altsys_functions.php'; |
|
| 11 | +include_once __DIR__.'/include/tpls_functions.php'; |
|
| 12 | +include_once __DIR__.'/include/Text_Diff.php'; |
|
| 13 | +include_once __DIR__.'/include/Text_Diff_Renderer.php'; |
|
| 14 | +include_once __DIR__.'/include/Text_Diff_Renderer_unified.php'; |
|
| 15 | 15 | |
| 16 | 16 | |
| 17 | 17 | // only groups have 'module_admin' of 'altsys' can do that. |
| 18 | -$module_handler = xoops_getHandler('module') ; |
|
| 19 | -$module = $module_handler->getByDirname('altsys') ; |
|
| 20 | -$moduleperm_handler = xoops_getHandler('groupperm') ; |
|
| 21 | -if (! is_object(@$xoopsUser) || ! $moduleperm_handler->checkRight('module_admin', $module->getVar('mid'), $xoopsUser->getGroups())) { |
|
| 22 | - die('only admin of altsys can access this area') ; |
|
| 18 | +$module_handler = xoops_getHandler('module'); |
|
| 19 | +$module = $module_handler->getByDirname('altsys'); |
|
| 20 | +$moduleperm_handler = xoops_getHandler('groupperm'); |
|
| 21 | +if (!is_object(@$xoopsUser) || !$moduleperm_handler->checkRight('module_admin', $module->getVar('mid'), $xoopsUser->getGroups())) { |
|
| 22 | + die('only admin of altsys can access this area'); |
|
| 23 | 23 | } |
| 24 | 24 | |
| 25 | 25 | //$xoops_system_path = XOOPS_ROOT_PATH . '/modules/system' ; |
| 26 | 26 | |
| 27 | 27 | // initials |
| 28 | 28 | $db = XoopsDatabaseFactory::getDatabaseConnection(); |
| 29 | -(method_exists('MyTextSanitizer', 'sGetInstance') and $myts = MyTextSanitizer::sGetInstance()) || $myts = MyTextSanitizer::getInstance() ; |
|
| 29 | +(method_exists('MyTextSanitizer', 'sGetInstance') and $myts = MyTextSanitizer::sGetInstance()) || $myts = MyTextSanitizer::getInstance(); |
|
| 30 | 30 | |
| 31 | 31 | // language file |
| 32 | -altsys_include_language_file('mytplsform') ; |
|
| 33 | -altsys_include_language_file('mytplsadmin') ; |
|
| 32 | +altsys_include_language_file('mytplsform'); |
|
| 33 | +altsys_include_language_file('mytplsadmin'); |
|
| 34 | 34 | |
| 35 | 35 | // check $xoopsModule |
| 36 | -if (! is_object($xoopsModule)) { |
|
| 37 | - redirect_header(XOOPS_URL.'/user.php', 1, _NOPERM) ; |
|
| 36 | +if (!is_object($xoopsModule)) { |
|
| 37 | + redirect_header(XOOPS_URL.'/user.php', 1, _NOPERM); |
|
| 38 | 38 | } |
| 39 | 39 | |
| 40 | 40 | // check access right (needs system_admin of tplset) |
@@ -42,128 +42,128 @@ discard block |
||
| 42 | 42 | //if (!$sysperm_handler->checkRight('system_admin', XOOPS_SYSTEM_TPLSET, $xoopsUser->getGroups())) redirect_header( XOOPS_URL.'/user.php' , 1 , _NOPERM ) ; |
| 43 | 43 | |
| 44 | 44 | // tpl_file from $_GET |
| 45 | -$tpl_tplset = $myts->stripSlashesGPC(@$_GET['tpl_tplset']) ; |
|
| 46 | -if (! $tpl_tplset) { |
|
| 47 | - $tpl_tplset = $xoopsConfig['template_set'] ; |
|
| 45 | +$tpl_tplset = $myts->stripSlashesGPC(@$_GET['tpl_tplset']); |
|
| 46 | +if (!$tpl_tplset) { |
|
| 47 | + $tpl_tplset = $xoopsConfig['template_set']; |
|
| 48 | 48 | } |
| 49 | -$tpl_tplset4sql = addslashes($tpl_tplset) ; |
|
| 49 | +$tpl_tplset4sql = addslashes($tpl_tplset); |
|
| 50 | 50 | |
| 51 | 51 | if (empty($_GET['tpl_file']) || $_GET['tpl_file'] == '_custom') { |
| 52 | - $edit_mode = 'create' ; |
|
| 53 | - $tpl_file = '_custom' ; |
|
| 52 | + $edit_mode = 'create'; |
|
| 53 | + $tpl_file = '_custom'; |
|
| 54 | 54 | $tpl = array( |
| 55 | - 'tpl_id' => 0 , |
|
| 56 | - 'tpl_refid' => 0 , |
|
| 57 | - 'tpl_module' => '_custom' , |
|
| 58 | - 'tpl_tplset' => $tpl_tplset , |
|
| 59 | - 'tpl_file' => '_custom_'.substr(date('YmdHis'), 2, -2).'.html' , |
|
| 60 | - 'tpl_desc' => '' , |
|
| 61 | - 'tpl_lastmodified' => 0 , |
|
| 62 | - 'tpl_lastimported' => 0 , |
|
| 63 | - 'tpl_type' => 'custom' , |
|
| 55 | + 'tpl_id' => 0, |
|
| 56 | + 'tpl_refid' => 0, |
|
| 57 | + 'tpl_module' => '_custom', |
|
| 58 | + 'tpl_tplset' => $tpl_tplset, |
|
| 59 | + 'tpl_file' => '_custom_'.substr(date('YmdHis'), 2, -2).'.html', |
|
| 60 | + 'tpl_desc' => '', |
|
| 61 | + 'tpl_lastmodified' => 0, |
|
| 62 | + 'tpl_lastimported' => 0, |
|
| 63 | + 'tpl_type' => 'custom', |
|
| 64 | 64 | 'tpl_source' => '' |
| 65 | - ) ; |
|
| 65 | + ); |
|
| 66 | 66 | |
| 67 | 67 | // breadcrumbs |
| 68 | - $breadcrumbsObj = AltsysBreadcrumbs::getInstance() ; |
|
| 69 | - $breadcrumbsObj->appendPath(XOOPS_URL.'/modules/altsys/admin/index.php?mode=admin&lib=altsys&page=mytplsadmin', '_MI_ALTSYS_MENU_MYTPLSADMIN') ; |
|
| 70 | - $breadcrumbsObj->appendPath(XOOPS_URL.'/modules/altsys/admin/index.php?mode=admin&lib=altsys&page=mytplsadmin&dirname=_custom', _MYTPLSADMIN_CUSTOMTEMPLATE) ; |
|
| 71 | - $breadcrumbsObj->appendPath('', '_MYTPLSADMIN_CREATENEWCUSTOMTEMPLATE') ; |
|
| 68 | + $breadcrumbsObj = AltsysBreadcrumbs::getInstance(); |
|
| 69 | + $breadcrumbsObj->appendPath(XOOPS_URL.'/modules/altsys/admin/index.php?mode=admin&lib=altsys&page=mytplsadmin', '_MI_ALTSYS_MENU_MYTPLSADMIN'); |
|
| 70 | + $breadcrumbsObj->appendPath(XOOPS_URL.'/modules/altsys/admin/index.php?mode=admin&lib=altsys&page=mytplsadmin&dirname=_custom', _MYTPLSADMIN_CUSTOMTEMPLATE); |
|
| 71 | + $breadcrumbsObj->appendPath('', '_MYTPLSADMIN_CREATENEWCUSTOMTEMPLATE'); |
|
| 72 | 72 | $target_mname = _MYTPLSADMIN_CUSTOMTEMPLATE; |
| 73 | 73 | } else { |
| 74 | 74 | // tpl_file from $_GET |
| 75 | - $edit_mode = 'modify' ; |
|
| 76 | - $tpl_file = $myts->stripSlashesGPC(@$_GET['tpl_file']) ; |
|
| 77 | - $tpl_file = str_replace('db:', '', $tpl_file) ; |
|
| 78 | - $tpl_file4sql = addslashes($tpl_file) ; |
|
| 75 | + $edit_mode = 'modify'; |
|
| 76 | + $tpl_file = $myts->stripSlashesGPC(@$_GET['tpl_file']); |
|
| 77 | + $tpl_file = str_replace('db:', '', $tpl_file); |
|
| 78 | + $tpl_file4sql = addslashes($tpl_file); |
|
| 79 | 79 | |
| 80 | 80 | // get information from tplfile table |
| 81 | - $sql = 'SELECT * FROM ' . $db->prefix('tplfile') . ' f NATURAL LEFT JOIN ' . $db->prefix('tplsource') . " s WHERE f.tpl_file='$tpl_file4sql' ORDER BY f.tpl_tplset='$tpl_tplset4sql' DESC,f.tpl_tplset='default' DESC" ; |
|
| 82 | - $tpl = $db->fetchArray($db->query($sql)) ; |
|
| 81 | + $sql = 'SELECT * FROM '.$db->prefix('tplfile').' f NATURAL LEFT JOIN '.$db->prefix('tplsource')." s WHERE f.tpl_file='$tpl_file4sql' ORDER BY f.tpl_tplset='$tpl_tplset4sql' DESC,f.tpl_tplset='default' DESC"; |
|
| 82 | + $tpl = $db->fetchArray($db->query($sql)); |
|
| 83 | 83 | |
| 84 | 84 | // get module info |
| 85 | 85 | if ($tpl['tpl_module'] == '_custom') { |
| 86 | - $target_module = null ; |
|
| 87 | - $target_mname = _MYTPLSADMIN_CUSTOMTEMPLATE ; |
|
| 86 | + $target_module = null; |
|
| 87 | + $target_mname = _MYTPLSADMIN_CUSTOMTEMPLATE; |
|
| 88 | 88 | } else { |
| 89 | - $module_handler = xoops_getHandler('module') ; |
|
| 90 | - $target_module = $module_handler->getByDirname($tpl['tpl_module']) ; |
|
| 91 | - $target_mname = is_object($target_module) ? $target_module->getVar('name') : '' ; |
|
| 89 | + $module_handler = xoops_getHandler('module'); |
|
| 90 | + $target_module = $module_handler->getByDirname($tpl['tpl_module']); |
|
| 91 | + $target_mname = is_object($target_module) ? $target_module->getVar('name') : ''; |
|
| 92 | 92 | } |
| 93 | 93 | |
| 94 | 94 | // breadcrumbs |
| 95 | - $breadcrumbsObj = AltsysBreadcrumbs::getInstance() ; |
|
| 95 | + $breadcrumbsObj = AltsysBreadcrumbs::getInstance(); |
|
| 96 | 96 | if ($mydirname != 'altsys' && is_object($target_module)) { |
| 97 | 97 | // mytplsform in each modules |
| 98 | - $mod_url = XOOPS_URL.'/modules/'.$target_module->getVar('dirname') ; |
|
| 99 | - $modinfo = $target_module->getInfo() ; |
|
| 100 | - $breadcrumbsObj->appendPath($mod_url.'/'.@$modinfo['adminindex'], $target_mname) ; |
|
| 101 | - $breadcrumbsObj->appendPath($mod_url.'/admin/index.php?mode=admin&lib=altsys&page=mytplsadmin', _MD_A_MYTPLSFORM_TPLSADMIN) ; |
|
| 98 | + $mod_url = XOOPS_URL.'/modules/'.$target_module->getVar('dirname'); |
|
| 99 | + $modinfo = $target_module->getInfo(); |
|
| 100 | + $breadcrumbsObj->appendPath($mod_url.'/'.@$modinfo['adminindex'], $target_mname); |
|
| 101 | + $breadcrumbsObj->appendPath($mod_url.'/admin/index.php?mode=admin&lib=altsys&page=mytplsadmin', _MD_A_MYTPLSFORM_TPLSADMIN); |
|
| 102 | 102 | } else { |
| 103 | 103 | // mytplsform in altsys |
| 104 | - $breadcrumbsObj->appendPath(XOOPS_URL.'/modules/altsys/admin/index.php?mode=admin&lib=altsys&page=mytplsadmin', '_MI_ALTSYS_MENU_MYTPLSADMIN') ; |
|
| 105 | - $breadcrumbsObj->appendPath(XOOPS_URL.'/modules/altsys/admin/index.php?mode=admin&lib=altsys&page=mytplsadmin&dirname='.htmlspecialchars($tpl['tpl_module']), $target_mname) ; |
|
| 104 | + $breadcrumbsObj->appendPath(XOOPS_URL.'/modules/altsys/admin/index.php?mode=admin&lib=altsys&page=mytplsadmin', '_MI_ALTSYS_MENU_MYTPLSADMIN'); |
|
| 105 | + $breadcrumbsObj->appendPath(XOOPS_URL.'/modules/altsys/admin/index.php?mode=admin&lib=altsys&page=mytplsadmin&dirname='.htmlspecialchars($tpl['tpl_module']), $target_mname); |
|
| 106 | 106 | } |
| 107 | - $breadcrumbsObj->appendPath('', _MD_A_MYTPLSFORM_EDIT) ; |
|
| 107 | + $breadcrumbsObj->appendPath('', _MD_A_MYTPLSFORM_EDIT); |
|
| 108 | 108 | } |
| 109 | 109 | |
| 110 | 110 | // error in specifying tpl_file |
| 111 | 111 | if (empty($tpl)) { |
| 112 | 112 | if (strncmp($tpl_file, 'file:', 5) === 0) { |
| 113 | - die('Not DB template') ; |
|
| 113 | + die('Not DB template'); |
|
| 114 | 114 | } else { |
| 115 | - die('Invalid tpl_file.') ; |
|
| 115 | + die('Invalid tpl_file.'); |
|
| 116 | 116 | } |
| 117 | 117 | } |
| 118 | 118 | |
| 119 | 119 | //****************// |
| 120 | 120 | // TRANSACT stage // |
| 121 | 121 | //****************// |
| 122 | -if (! empty($_POST['do_modifycont']) || ! empty($_POST['do_modify'])) { |
|
| 122 | +if (!empty($_POST['do_modifycont']) || !empty($_POST['do_modify'])) { |
|
| 123 | 123 | // Ticket Check |
| 124 | - if (! $xoopsGTicket->check(true, 'altsys_tplsform')) { |
|
| 124 | + if (!$xoopsGTicket->check(true, 'altsys_tplsform')) { |
|
| 125 | 125 | redirect_header(XOOPS_URL.'/', 3, $xoopsGTicket->getErrors()); |
| 126 | 126 | } |
| 127 | 127 | |
| 128 | - $result = $db->query('SELECT tpl_id FROM ' . $db->prefix('tplfile') . " WHERE tpl_file='$tpl_file4sql' AND tpl_tplset='" . addslashes($tpl['tpl_tplset']) . "'") ; |
|
| 128 | + $result = $db->query('SELECT tpl_id FROM '.$db->prefix('tplfile')." WHERE tpl_file='$tpl_file4sql' AND tpl_tplset='".addslashes($tpl['tpl_tplset'])."'"); |
|
| 129 | 129 | while (list($tpl_id) = $db->fetchRow($result)) { |
| 130 | - $sql = 'UPDATE ' . $db->prefix('tplsource') . " SET tpl_source='" . addslashes($myts->stripSlashesGPC($_POST['tpl_source'])) . "' WHERE tpl_id=$tpl_id" ; |
|
| 131 | - if (! $db->query($sql)) { |
|
| 132 | - die('SQL Error') ; |
|
| 130 | + $sql = 'UPDATE '.$db->prefix('tplsource')." SET tpl_source='".addslashes($myts->stripSlashesGPC($_POST['tpl_source']))."' WHERE tpl_id=$tpl_id"; |
|
| 131 | + if (!$db->query($sql)) { |
|
| 132 | + die('SQL Error'); |
|
| 133 | 133 | } |
| 134 | - $db->query('UPDATE ' . $db->prefix('tplfile') . " SET tpl_lastmodified=UNIX_TIMESTAMP() WHERE tpl_id=$tpl_id") ; |
|
| 135 | - altsys_template_touch($tpl_id) ; |
|
| 134 | + $db->query('UPDATE '.$db->prefix('tplfile')." SET tpl_lastmodified=UNIX_TIMESTAMP() WHERE tpl_id=$tpl_id"); |
|
| 135 | + altsys_template_touch($tpl_id); |
|
| 136 | 136 | } |
| 137 | 137 | |
| 138 | 138 | // continue or end ? |
| 139 | - if (! empty($_POST['do_modifycont'])) { |
|
| 140 | - redirect_header('index.php?mode=admin&lib=altsys&page=mytplsform&tpl_file='.$tpl_file.'&tpl_tplset='.$tpl_tplset.'&dirname='.$tpl['tpl_module'].'#altsys_tplsform_top', 1, _MD_A_MYTPLSFORM_UPDATED) ; |
|
| 139 | + if (!empty($_POST['do_modifycont'])) { |
|
| 140 | + redirect_header('index.php?mode=admin&lib=altsys&page=mytplsform&tpl_file='.$tpl_file.'&tpl_tplset='.$tpl_tplset.'&dirname='.$tpl['tpl_module'].'#altsys_tplsform_top', 1, _MD_A_MYTPLSFORM_UPDATED); |
|
| 141 | 141 | } else { |
| 142 | - redirect_header('index.php?mode=admin&lib=altsys&page=mytplsadmin&dirname='.$tpl['tpl_module'], 1, _MD_A_MYTPLSFORM_UPDATED) ; |
|
| 142 | + redirect_header('index.php?mode=admin&lib=altsys&page=mytplsadmin&dirname='.$tpl['tpl_module'], 1, _MD_A_MYTPLSFORM_UPDATED); |
|
| 143 | 143 | } |
| 144 | - exit ; |
|
| 144 | + exit; |
|
| 145 | 145 | } |
| 146 | 146 | |
| 147 | -if (! empty($_POST['do_create'])) { |
|
| 147 | +if (!empty($_POST['do_create'])) { |
|
| 148 | 148 | // Ticket Check |
| 149 | - if (! $xoopsGTicket->check(true, 'altsys_tplsform')) { |
|
| 149 | + if (!$xoopsGTicket->check(true, 'altsys_tplsform')) { |
|
| 150 | 150 | redirect_header(XOOPS_URL.'/', 3, $xoopsGTicket->getErrors()); |
| 151 | 151 | } |
| 152 | 152 | |
| 153 | - $sql = 'INSERT INTO ' . $db->prefix('tplfile') . " SET tpl_file='" . addslashes($myts->stripSlashesGPC($_POST['tpl_file'])) . "',tpl_refid=0,tpl_module='" . addslashes($tpl['tpl_module']) . "',tpl_tplset='" . addslashes($tpl['tpl_tplset']) . "',tpl_lastmodified=UNIX_TIMESTAMP(),tpl_type='" . addslashes($tpl['tpl_type']) . "'" ; |
|
| 154 | - if (! $db->query($sql)) { |
|
| 155 | - die('SQL Error'.__LINE__) ; |
|
| 153 | + $sql = 'INSERT INTO '.$db->prefix('tplfile')." SET tpl_file='".addslashes($myts->stripSlashesGPC($_POST['tpl_file']))."',tpl_refid=0,tpl_module='".addslashes($tpl['tpl_module'])."',tpl_tplset='".addslashes($tpl['tpl_tplset'])."',tpl_lastmodified=UNIX_TIMESTAMP(),tpl_type='".addslashes($tpl['tpl_type'])."'"; |
|
| 154 | + if (!$db->query($sql)) { |
|
| 155 | + die('SQL Error'.__LINE__); |
|
| 156 | 156 | } |
| 157 | 157 | $tpl_id = (int)$db->getInsertId(); |
| 158 | - $sql = 'INSERT INTO ' . $db->prefix('tplsource') . " SET tpl_id=$tpl_id,tpl_source='" . addslashes($myts->stripSlashesGPC($_POST['tpl_source'])) . "'" ; |
|
| 159 | - if (! $db->query($sql)) { |
|
| 160 | - die('SQL Error'.__LINE__) ; |
|
| 158 | + $sql = 'INSERT INTO '.$db->prefix('tplsource')." SET tpl_id=$tpl_id,tpl_source='".addslashes($myts->stripSlashesGPC($_POST['tpl_source']))."'"; |
|
| 159 | + if (!$db->query($sql)) { |
|
| 160 | + die('SQL Error'.__LINE__); |
|
| 161 | 161 | } |
| 162 | - altsys_template_touch($tpl_id) ; |
|
| 162 | + altsys_template_touch($tpl_id); |
|
| 163 | 163 | |
| 164 | 164 | // continue or end ? |
| 165 | - redirect_header('index.php?mode=admin&lib=altsys&page=mytplsadmin&dirname='.$tpl['tpl_module'], 1, _MD_A_MYTPLSFORM_CREATED) ; |
|
| 166 | - exit ; |
|
| 165 | + redirect_header('index.php?mode=admin&lib=altsys&page=mytplsadmin&dirname='.$tpl['tpl_module'], 1, _MD_A_MYTPLSFORM_CREATED); |
|
| 166 | + exit; |
|
| 167 | 167 | } |
| 168 | 168 | |
| 169 | 169 | |
@@ -171,56 +171,56 @@ discard block |
||
| 171 | 171 | //****************// |
| 172 | 172 | // FORM stage // |
| 173 | 173 | //****************// |
| 174 | -xoops_cp_header() ; |
|
| 175 | -$mymenu_fake_uri = 'index.php?mode=admin&lib=altsys&page=mytplsadmin&dirname='.$mydirname ; |
|
| 174 | +xoops_cp_header(); |
|
| 175 | +$mymenu_fake_uri = 'index.php?mode=admin&lib=altsys&page=mytplsadmin&dirname='.$mydirname; |
|
| 176 | 176 | |
| 177 | 177 | // mymenu |
| 178 | -altsys_include_mymenu() ; |
|
| 178 | +altsys_include_mymenu(); |
|
| 179 | 179 | |
| 180 | -echo "<h3 style='text-align:"._GLOBAL_LEFT.";'>"._MD_A_MYTPLSFORM_EDIT . ' : ' . htmlspecialchars($tpl['tpl_type'], ENT_QUOTES) . ' : ' . htmlspecialchars($tpl['tpl_file'], ENT_QUOTES) . ' (' |
|
| 181 | - . htmlspecialchars($tpl['tpl_tplset'], ENT_QUOTES) . ")</h3>\n" ; |
|
| 180 | +echo "<h3 style='text-align:"._GLOBAL_LEFT.";'>"._MD_A_MYTPLSFORM_EDIT.' : '.htmlspecialchars($tpl['tpl_type'], ENT_QUOTES).' : '.htmlspecialchars($tpl['tpl_file'], ENT_QUOTES).' (' |
|
| 181 | + . htmlspecialchars($tpl['tpl_tplset'], ENT_QUOTES).")</h3>\n"; |
|
| 182 | 182 | |
| 183 | 183 | |
| 184 | 184 | // diff from file to selected DB template |
| 185 | -$basefilepath = tplsadmin_get_basefilepath($tpl['tpl_module'], $tpl['tpl_type'], $tpl['tpl_file']) ; |
|
| 186 | -$diff_from_file4disp = '' ; |
|
| 185 | +$basefilepath = tplsadmin_get_basefilepath($tpl['tpl_module'], $tpl['tpl_type'], $tpl['tpl_file']); |
|
| 186 | +$diff_from_file4disp = ''; |
|
| 187 | 187 | if (file_exists($basefilepath)) { |
| 188 | - $original_error_level = error_reporting() ; |
|
| 189 | - error_reporting($original_error_level & ~ E_NOTICE & ~ E_WARNING) ; |
|
| 190 | - $diff = new Text_Diff(file($basefilepath), explode("\n", $tpl['tpl_source'])) ; |
|
| 188 | + $original_error_level = error_reporting(); |
|
| 189 | + error_reporting($original_error_level & ~ E_NOTICE & ~ E_WARNING); |
|
| 190 | + $diff = new Text_Diff(file($basefilepath), explode("\n", $tpl['tpl_source'])); |
|
| 191 | 191 | $renderer = new Text_Diff_Renderer_unified(); |
| 192 | - $diff_str = htmlspecialchars($renderer->render($diff), ENT_QUOTES) ; |
|
| 192 | + $diff_str = htmlspecialchars($renderer->render($diff), ENT_QUOTES); |
|
| 193 | 193 | foreach (explode("\n", $diff_str) as $line) { |
| 194 | 194 | if (ord($line) == 0x2d) { |
| 195 | - $diff_from_file4disp .= "<span style='color:red;'>".$line."</span>\n" ; |
|
| 195 | + $diff_from_file4disp .= "<span style='color:red;'>".$line."</span>\n"; |
|
| 196 | 196 | } elseif (ord($line) == 0x2b) { |
| 197 | - $diff_from_file4disp .= "<span style='color:blue;'>".$line."</span>\n" ; |
|
| 197 | + $diff_from_file4disp .= "<span style='color:blue;'>".$line."</span>\n"; |
|
| 198 | 198 | } else { |
| 199 | - $diff_from_file4disp .= $line."\n" ; |
|
| 199 | + $diff_from_file4disp .= $line."\n"; |
|
| 200 | 200 | } |
| 201 | 201 | } |
| 202 | - error_reporting($original_error_level) ; |
|
| 202 | + error_reporting($original_error_level); |
|
| 203 | 203 | } |
| 204 | 204 | |
| 205 | 205 | // diff from DB-default to selected DB template |
| 206 | -$diff_from_default4disp = '' ; |
|
| 206 | +$diff_from_default4disp = ''; |
|
| 207 | 207 | if ($tpl['tpl_tplset'] != 'default') { |
| 208 | - $original_error_level = error_reporting() ; |
|
| 209 | - error_reporting($original_error_level & ~ E_NOTICE & ~ E_WARNING) ; |
|
| 210 | - list($default_source) = $db->fetchRow($db->query('SELECT tpl_source FROM ' . $db->prefix('tplfile') . ' NATURAL LEFT JOIN ' . $db->prefix('tplsource') . " WHERE tpl_tplset='default' AND tpl_file='" . addslashes($tpl['tpl_file']) . "' AND tpl_module='" . addslashes($tpl['tpl_module']) . "'")) ; |
|
| 211 | - $diff = new Text_Diff(explode("\n", $default_source), explode("\n", $tpl['tpl_source'])) ; |
|
| 208 | + $original_error_level = error_reporting(); |
|
| 209 | + error_reporting($original_error_level & ~ E_NOTICE & ~ E_WARNING); |
|
| 210 | + list($default_source) = $db->fetchRow($db->query('SELECT tpl_source FROM '.$db->prefix('tplfile').' NATURAL LEFT JOIN '.$db->prefix('tplsource')." WHERE tpl_tplset='default' AND tpl_file='".addslashes($tpl['tpl_file'])."' AND tpl_module='".addslashes($tpl['tpl_module'])."'")); |
|
| 211 | + $diff = new Text_Diff(explode("\n", $default_source), explode("\n", $tpl['tpl_source'])); |
|
| 212 | 212 | $renderer = new Text_Diff_Renderer_unified(); |
| 213 | - $diff_str = htmlspecialchars($renderer->render($diff), ENT_QUOTES) ; |
|
| 213 | + $diff_str = htmlspecialchars($renderer->render($diff), ENT_QUOTES); |
|
| 214 | 214 | foreach (explode("\n", $diff_str) as $line) { |
| 215 | 215 | if (ord($line) == 0x2d) { |
| 216 | - $diff_from_default4disp .= "<span style='color:red;'>".$line."</span>\n" ; |
|
| 216 | + $diff_from_default4disp .= "<span style='color:red;'>".$line."</span>\n"; |
|
| 217 | 217 | } elseif (ord($line) == 0x2b) { |
| 218 | - $diff_from_default4disp .= "<span style='color:blue;'>".$line."</span>\n" ; |
|
| 218 | + $diff_from_default4disp .= "<span style='color:blue;'>".$line."</span>\n"; |
|
| 219 | 219 | } else { |
| 220 | - $diff_from_default4disp .= $line."\n" ; |
|
| 220 | + $diff_from_default4disp .= $line."\n"; |
|
| 221 | 221 | } |
| 222 | 222 | } |
| 223 | - error_reporting($original_error_level) ; |
|
| 223 | + error_reporting($original_error_level); |
|
| 224 | 224 | } |
| 225 | 225 | |
| 226 | 226 | |
@@ -228,11 +228,11 @@ discard block |
||
| 228 | 228 | <form name='diff_form' id='diff_form' action='' method='get'>\n" ; |
| 229 | 229 | if ($diff_from_file4disp) { |
| 230 | 230 | echo "<input type='checkbox' name='display_diff2file' value='1' onClick=\"if(this.checked){document.getElementById('diff2file').style.display='block'}else{document.getElementById('diff2file').style.display='none'};\" id='display_diff2file' checked='checked' /> <label for='display_diff2file'>diff from file</label> |
| 231 | - <pre id='diff2file' style='display:block;border:1px solid black;'>$diff_from_file4disp</pre>\n" ; |
|
| 231 | + <pre id='diff2file' style='display:block;border:1px solid black;'>$diff_from_file4disp</pre>\n"; |
|
| 232 | 232 | } |
| 233 | 233 | if ($diff_from_default4disp) { |
| 234 | 234 | echo "<input type='checkbox' name='display_diff2default' value='1' onClick=\"if(this.checked){document.getElementById('diff2default').style.display='block'}else{document.getElementById('diff2default').style.display='none'};\" id='display_diff2default' /> <label for='display_diff2default'>diff from default</label> |
| 235 | - <pre id='diff2default' style='display:none;border:1px solid black;'>$diff_from_default4disp</pre>\n" ; |
|
| 235 | + <pre id='diff2default' style='display:none;border:1px solid black;'>$diff_from_default4disp</pre>\n"; |
|
| 236 | 236 | } |
| 237 | 237 | echo " |
| 238 | 238 | </form>\n" ; |
@@ -240,10 +240,10 @@ discard block |
||
| 240 | 240 | |
| 241 | 241 | echo " |
| 242 | 242 | <a name='altsys_tplsform_top' id='altsys_tplsform_top'></a> |
| 243 | -<form name='MainForm' id='altsys_tplsform' action='?mode=admin&lib=altsys&page=mytplsform&tpl_file=".htmlspecialchars($tpl_file, ENT_QUOTES) . '&tpl_tplset=' |
|
| 244 | - . htmlspecialchars($tpl['tpl_tplset'], ENT_QUOTES) . '&dirname=' . $target_mname . "' method='post'> |
|
| 243 | +<form name='MainForm' id='altsys_tplsform' action='?mode=admin&lib=altsys&page=mytplsform&tpl_file=".htmlspecialchars($tpl_file, ENT_QUOTES).'&tpl_tplset=' |
|
| 244 | + . htmlspecialchars($tpl['tpl_tplset'], ENT_QUOTES).'&dirname='.$target_mname."' method='post'> |
|
| 245 | 245 | ".$xoopsGTicket->getTicketHtml(__LINE__, 1800, 'altsys_tplsform')." |
| 246 | - <textarea name='tpl_source' id='altsys_tpl_source' wrap='off' style='width:600px;height:400px;'>".htmlspecialchars($tpl['tpl_source'], ENT_QUOTES) . '</textarea> |
|
| 246 | + <textarea name='tpl_source' id='altsys_tpl_source' wrap='off' style='width:600px;height:400px;'>".htmlspecialchars($tpl['tpl_source'], ENT_QUOTES).'</textarea> |
|
| 247 | 247 | <br /> |
| 248 | 248 | '; |
| 249 | 249 | if ($edit_mode == 'create') { |
@@ -251,7 +251,7 @@ discard block |
||
| 251 | 251 | echo " |
| 252 | 252 | <label for='tpl_file'>"._MD_A_MYTPLSFORM_LABEL_TPLFILE."</label> |
| 253 | 253 | <input type='text' name='tpl_file' id='tpl_file' value='".htmlspecialchars($tpl['tpl_file'], ENT_QUOTES)."' size='64' /><br /> |
| 254 | - <input type='submit' name='do_create' id='do_create' value='"._MD_A_MYTPLSFORM_BTN_CREATE."' />\n" ; |
|
| 254 | + <input type='submit' name='do_create' id='do_create' value='"._MD_A_MYTPLSFORM_BTN_CREATE."' />\n"; |
|
| 255 | 255 | } else { |
| 256 | 256 | // modify form |
| 257 | 257 | echo " |
@@ -261,4 +261,4 @@ discard block |
||
| 261 | 261 | </form>\n" ; |
| 262 | 262 | } |
| 263 | 263 | |
| 264 | -xoops_cp_footer() ; |
|
| 264 | +xoops_cp_footer(); |
|
@@ -5,25 +5,25 @@ discard block |
||
| 5 | 5 | // GIJOE <http://www.peak.ne.jp/> // |
| 6 | 6 | // ------------------------------------------------------------------------- // |
| 7 | 7 | |
| 8 | -include_once __DIR__.'/include/gtickets.php' ; |
|
| 9 | -include_once __DIR__.'/include/altsys_functions.php' ; |
|
| 10 | -include_once __DIR__.'/include/tpls_functions.php' ; |
|
| 8 | +include_once __DIR__.'/include/gtickets.php'; |
|
| 9 | +include_once __DIR__.'/include/altsys_functions.php'; |
|
| 10 | +include_once __DIR__.'/include/tpls_functions.php'; |
|
| 11 | 11 | |
| 12 | 12 | |
| 13 | 13 | // this page can be called only from altsys |
| 14 | 14 | if ($xoopsModule->getVar('dirname') != 'altsys') { |
| 15 | - die('this page can be called only from altsys') ; |
|
| 15 | + die('this page can be called only from altsys'); |
|
| 16 | 16 | } |
| 17 | 17 | |
| 18 | 18 | |
| 19 | 19 | // language file |
| 20 | -altsys_include_language_file('compilehookadmin') ; |
|
| 20 | +altsys_include_language_file('compilehookadmin'); |
|
| 21 | 21 | |
| 22 | 22 | |
| 23 | -$db = XoopsDatabaseFactory::getDatabaseConnection() ; |
|
| 23 | +$db = XoopsDatabaseFactory::getDatabaseConnection(); |
|
| 24 | 24 | |
| 25 | -if (empty($_FILES['tplset_archive']['tmp_name']) || ! is_uploaded_file($_FILES['tplset_archive']['tmp_name'])) { |
|
| 26 | - die(_TPLSADMIN_ERR_NOTUPLOADED) ; |
|
| 25 | +if (empty($_FILES['tplset_archive']['tmp_name']) || !is_uploaded_file($_FILES['tplset_archive']['tmp_name'])) { |
|
| 26 | + die(_TPLSADMIN_ERR_NOTUPLOADED); |
|
| 27 | 27 | } |
| 28 | 28 | //fix for mb_http_output setting and for add any browsers |
| 29 | 29 | if (function_exists('mb_http_output')) { |
@@ -32,7 +32,7 @@ discard block |
||
| 32 | 32 | //ob_buffer over flow |
| 33 | 33 | //HACK by suin & nao-pon 2012/01/06 |
| 34 | 34 | while (ob_get_level() > 0) { |
| 35 | - if (! ob_end_clean()) { |
|
| 35 | + if (!ob_end_clean()) { |
|
| 36 | 36 | break; |
| 37 | 37 | } |
| 38 | 38 | } |
@@ -41,62 +41,62 @@ discard block |
||
| 41 | 41 | // EXTRACT STAGE |
| 42 | 42 | // |
| 43 | 43 | |
| 44 | -$orig_filename4check = strtolower($_FILES['tplset_archive']['name']) ; |
|
| 44 | +$orig_filename4check = strtolower($_FILES['tplset_archive']['name']); |
|
| 45 | 45 | if (strtolower(substr($orig_filename4check, -4)) == '.zip') { |
| 46 | 46 | |
| 47 | 47 | // zip |
| 48 | - require_once __DIR__.'/include/Archive_Zip.php' ; |
|
| 49 | - $reader = new Archive_Zip($_FILES['tplset_archive']['tmp_name']) ; |
|
| 50 | - $files = $reader->extract(array( 'extract_as_string' => true )) ; |
|
| 51 | - if (! is_array(@$files)) { |
|
| 52 | - die($reader->errorName()) ; |
|
| 48 | + require_once __DIR__.'/include/Archive_Zip.php'; |
|
| 49 | + $reader = new Archive_Zip($_FILES['tplset_archive']['tmp_name']); |
|
| 50 | + $files = $reader->extract(array('extract_as_string' => true)); |
|
| 51 | + if (!is_array(@$files)) { |
|
| 52 | + die($reader->errorName()); |
|
| 53 | 53 | } |
| 54 | - $do_upload = true ; |
|
| 54 | + $do_upload = true; |
|
| 55 | 55 | } elseif (substr($orig_filename4check, -4) == '.tgz' || substr($orig_filename4check, -7) == '.tar.gz') { |
| 56 | 56 | |
| 57 | 57 | // tar.gz |
| 58 | - require_once XOOPS_ROOT_PATH.'/class/class.tar.php' ; |
|
| 59 | - $tar = new tar() ; |
|
| 60 | - $tar->openTAR($_FILES['tplset_archive']['tmp_name']) ; |
|
| 61 | - $files = array() ; |
|
| 58 | + require_once XOOPS_ROOT_PATH.'/class/class.tar.php'; |
|
| 59 | + $tar = new tar(); |
|
| 60 | + $tar->openTAR($_FILES['tplset_archive']['tmp_name']); |
|
| 61 | + $files = array(); |
|
| 62 | 62 | foreach ($tar->files as $id => $info) { |
| 63 | 63 | $files[] = array( |
| 64 | - 'filename' => $info['name'] , |
|
| 65 | - 'mtime' => $info['time'] , |
|
| 64 | + 'filename' => $info['name'], |
|
| 65 | + 'mtime' => $info['time'], |
|
| 66 | 66 | 'content' => $info['file'] |
| 67 | - ) ; |
|
| 67 | + ); |
|
| 68 | 68 | } |
| 69 | 69 | if (empty($files)) { |
| 70 | - die(_TPLSADMIN_ERR_INVALIDARCHIVE) ; |
|
| 70 | + die(_TPLSADMIN_ERR_INVALIDARCHIVE); |
|
| 71 | 71 | } |
| 72 | - $do_upload = true ; |
|
| 72 | + $do_upload = true; |
|
| 73 | 73 | } |
| 74 | 74 | |
| 75 | 75 | if (empty($do_upload)) { |
| 76 | - die(_TPLSADMIN_ERR_EXTENSION) ; |
|
| 76 | + die(_TPLSADMIN_ERR_EXTENSION); |
|
| 77 | 77 | } |
| 78 | 78 | |
| 79 | 79 | // |
| 80 | 80 | // IMPORT STAGE |
| 81 | 81 | // |
| 82 | 82 | |
| 83 | -$tplset = @$_POST['tplset'] ; |
|
| 84 | -if (! preg_match('/^[0-9A-Za-z_-]{1,16}$/', $tplset)) { |
|
| 85 | - die(_TPLSADMIN_ERR_INVALIDTPLSET) ; |
|
| 83 | +$tplset = @$_POST['tplset']; |
|
| 84 | +if (!preg_match('/^[0-9A-Za-z_-]{1,16}$/', $tplset)) { |
|
| 85 | + die(_TPLSADMIN_ERR_INVALIDTPLSET); |
|
| 86 | 86 | } |
| 87 | 87 | |
| 88 | -$imported = 0 ; |
|
| 88 | +$imported = 0; |
|
| 89 | 89 | foreach ($files as $file) { |
| 90 | - if (! empty($file['folder'])) { |
|
| 91 | - continue ; |
|
| 90 | + if (!empty($file['folder'])) { |
|
| 91 | + continue; |
|
| 92 | 92 | } |
| 93 | - $pos = strrpos($file['filename'], '/') ; |
|
| 94 | - $tpl_file = $pos === false ? $file['filename'] : substr($file['filename'], $pos + 1) ; |
|
| 93 | + $pos = strrpos($file['filename'], '/'); |
|
| 94 | + $tpl_file = $pos === false ? $file['filename'] : substr($file['filename'], $pos + 1); |
|
| 95 | 95 | |
| 96 | 96 | if (tplsadmin_import_data($tplset, $tpl_file, rtrim($file['content']), $file['mtime'])) { |
| 97 | - $imported ++ ; |
|
| 97 | + $imported++; |
|
| 98 | 98 | } |
| 99 | 99 | } |
| 100 | 100 | |
| 101 | -redirect_header('?mode=admin&lib=altsys&page=compilehookadmin', 3, sprintf(_TPLSADMIN_FMT_MSG_PUTTEMPLATES, $imported)) ; |
|
| 102 | -exit ; |
|
| 101 | +redirect_header('?mode=admin&lib=altsys&page=compilehookadmin', 3, sprintf(_TPLSADMIN_FMT_MSG_PUTTEMPLATES, $imported)); |
|
| 102 | +exit; |
|
@@ -1,45 +1,45 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | -if (! $xoopsConfig['theme_fromfile']) { |
|
| 4 | - return ; |
|
| 3 | +if (!$xoopsConfig['theme_fromfile']) { |
|
| 4 | + return; |
|
| 5 | 5 | } |
| 6 | 6 | |
| 7 | 7 | // templates/ under modules |
| 8 | 8 | // $tplsadmin_autoupdate_path = XOOPS_THEME_PATH . '/' . $xoopsConfig['theme_set'] . '/templates' ; |
| 9 | 9 | |
| 10 | -if (! is_array(@$tplsadmin_autoupdate_dirnames)) { |
|
| 11 | - return ; |
|
| 10 | +if (!is_array(@$tplsadmin_autoupdate_dirnames)) { |
|
| 11 | + return; |
|
| 12 | 12 | } |
| 13 | 13 | |
| 14 | 14 | foreach ($tplsadmin_autoupdate_dirnames as $dirname) { |
| 15 | - $dirname = preg_replace('/[^a-zA-Z0-9_-]/', '', $dirname) ; |
|
| 16 | - $tplsadmin_autoupdate_path = XOOPS_ROOT_PATH . '/modules/' . $dirname . '/templates' ; |
|
| 15 | + $dirname = preg_replace('/[^a-zA-Z0-9_-]/', '', $dirname); |
|
| 16 | + $tplsadmin_autoupdate_path = XOOPS_ROOT_PATH.'/modules/'.$dirname.'/templates'; |
|
| 17 | 17 | |
| 18 | 18 | // modules |
| 19 | - if ($handler = @opendir($tplsadmin_autoupdate_path . '/')) { |
|
| 19 | + if ($handler = @opendir($tplsadmin_autoupdate_path.'/')) { |
|
| 20 | 20 | while (($file = readdir($handler)) !== false) { |
| 21 | - $file_path = $tplsadmin_autoupdate_path . '/' . $file ; |
|
| 21 | + $file_path = $tplsadmin_autoupdate_path.'/'.$file; |
|
| 22 | 22 | if (is_file($file_path) && substr($file, -5) == '.html') { |
| 23 | 23 | $mtime = (int)(@filemtime($file_path)); |
| 24 | - list($count) = $xoopsDB->fetchRow($xoopsDB->query('SELECT COUNT(*) FROM ' . $xoopsDB->prefix('tplfile') . " WHERE tpl_tplset='" . addslashes($xoopsConfig['template_set']) . "' AND tpl_file='" . addslashes($file) . "' AND tpl_lastmodified >= $mtime")) ; |
|
| 24 | + list($count) = $xoopsDB->fetchRow($xoopsDB->query('SELECT COUNT(*) FROM '.$xoopsDB->prefix('tplfile')." WHERE tpl_tplset='".addslashes($xoopsConfig['template_set'])."' AND tpl_file='".addslashes($file)."' AND tpl_lastmodified >= $mtime")); |
|
| 25 | 25 | if ($count <= 0) { |
| 26 | - include_once XOOPS_TRUST_PATH.'/libs/altsys/include/tpls_functions.php' ; |
|
| 27 | - tplsadmin_import_data($xoopsConfig['template_set'], $file, implode('', file($file_path)), $mtime) ; |
|
| 26 | + include_once XOOPS_TRUST_PATH.'/libs/altsys/include/tpls_functions.php'; |
|
| 27 | + tplsadmin_import_data($xoopsConfig['template_set'], $file, implode('', file($file_path)), $mtime); |
|
| 28 | 28 | } |
| 29 | 29 | } |
| 30 | 30 | } |
| 31 | 31 | } |
| 32 | 32 | |
| 33 | 33 | // blocks |
| 34 | - if ($handler = @opendir($tplsadmin_autoupdate_path . '/blocks/')) { |
|
| 34 | + if ($handler = @opendir($tplsadmin_autoupdate_path.'/blocks/')) { |
|
| 35 | 35 | while (($file = readdir($handler)) !== false) { |
| 36 | - $file_path = $tplsadmin_autoupdate_path . '/blocks/' . $file ; |
|
| 36 | + $file_path = $tplsadmin_autoupdate_path.'/blocks/'.$file; |
|
| 37 | 37 | if (is_file($file_path) && substr($file, -5) == '.html') { |
| 38 | 38 | $mtime = (int)(@filemtime($file_path)); |
| 39 | - list($count) = $xoopsDB->fetchRow($xoopsDB->query('SELECT COUNT(*) FROM ' . $xoopsDB->prefix('tplfile') . " WHERE tpl_tplset='" . addslashes($xoopsConfig['template_set']) . "' AND tpl_file='" . addslashes($file) . "' AND tpl_lastmodified >= $mtime")) ; |
|
| 39 | + list($count) = $xoopsDB->fetchRow($xoopsDB->query('SELECT COUNT(*) FROM '.$xoopsDB->prefix('tplfile')." WHERE tpl_tplset='".addslashes($xoopsConfig['template_set'])."' AND tpl_file='".addslashes($file)."' AND tpl_lastmodified >= $mtime")); |
|
| 40 | 40 | if ($count <= 0) { |
| 41 | - include_once XOOPS_TRUST_PATH.'/libs/altsys/include/tpls_functions.php' ; |
|
| 42 | - tplsadmin_import_data($xoopsConfig['template_set'], $file, implode('', file($file_path)), $mtime) ; |
|
| 41 | + include_once XOOPS_TRUST_PATH.'/libs/altsys/include/tpls_functions.php'; |
|
| 42 | + tplsadmin_import_data($xoopsConfig['template_set'], $file, implode('', file($file_path)), $mtime); |
|
| 43 | 43 | } |
| 44 | 44 | } |
| 45 | 45 | } |