Revision 954
Added by Matthias over 15 years ago
trunk/CHANGELOG | ||
---|---|---|
12 | 12 |
|
13 | 13 |
------------------------------------- 2.8.0 ------------------------------------- |
14 | 14 |
25-Feb-2009 Matthias Gallas |
15 |
+ Added language support for template_description (affects templates and themes) |
|
15 | 16 |
# fixed wrong path to images in news and form modul |
16 | 17 |
# fixed manage section is showed twice (ticket #694) |
17 | 18 |
- removed unneeded icons from wb_theme |
trunk/wb/admin/templates/details.php | ||
---|---|---|
25 | 25 |
|
26 | 26 |
// Include the config file |
27 | 27 |
require('../../config.php'); |
28 |
require_once(WB_PATH .'/framework/functions.php'); |
|
28 | 29 |
|
29 | 30 |
// Get template name |
30 | 31 |
if(!isset($_POST['file']) OR $_POST['file'] == "") { |
... | ... | |
55 | 56 |
$row = $result->fetchRow(); |
56 | 57 |
} |
57 | 58 |
|
59 |
// check if a template description exists for the displayed backend language |
|
60 |
$tool_description = false; |
|
61 |
if(function_exists('file_get_contents') && file_exists(WB_PATH.'/templates/'.$file.'/languages/'.LANGUAGE .'.php')) { |
|
62 |
// read contents of the template language file into string |
|
63 |
$data = @file_get_contents(WB_PATH .'/templates/' .$file .'/languages/' .LANGUAGE .'.php'); |
|
64 |
// use regular expressions to fetch the content of the variable from the string |
|
65 |
$tool_description = get_variable_content('template_description', $data, false, false); |
|
66 |
// replace optional placeholder {WB_URL} with value stored in config.php |
|
67 |
if($tool_description !== false && strlen(trim($tool_description)) != 0) { |
|
68 |
$tool_description = str_replace('{WB_URL}', WB_URL, $tool_description); |
|
69 |
} else { |
|
70 |
$tool_description = false; |
|
71 |
} |
|
72 |
} |
|
73 |
if($tool_description !== false) { |
|
74 |
// Override the template-description with correct desription in users language |
|
75 |
$row['description'] = $tool_description; |
|
76 |
} |
|
77 |
|
|
58 | 78 |
$template->set_var(array( |
59 | 79 |
'NAME' => $row['name'], |
60 | 80 |
'AUTHOR' => $row['author'], |
trunk/wb/templates/classic/info.php | ||
---|---|---|
1 | 1 |
<?php |
2 | 2 |
/** |
3 | 3 |
* $Id$ |
4 |
* Website Baker theme: wb_theme
|
|
4 |
* Website Baker theme: classic
|
|
5 | 5 |
* This theme is the default WB backend Theme |
6 | 6 |
* Feel free to modify or build up on this template. |
7 | 7 |
* |
... | ... | |
35 | 35 |
$template_author = 'Matthias Gallas'; |
36 | 36 |
$template_license = '<a href="http://www.gnu.org/licenses/gpl.html">GNU General Public License</a>'; |
37 | 37 |
$template_license_terms = '-'; |
38 |
$template_description = 'Default backend theme for Website Baker 2.8.';
|
|
38 |
$template_description = 'Backend theme for Website Baker 2.7.';
|
|
39 | 39 |
|
40 | 40 |
?> |
trunk/wb/templates/classic/languages/EN.php | ||
---|---|---|
1 |
<?php |
|
2 |
|
|
3 |
// $Id$ |
|
4 |
|
|
5 |
/* |
|
6 |
|
|
7 |
Website Baker Project <http://www.websitebaker.org/> |
|
8 |
Copyright (C) 2004-2009, Ryan Djurovich |
|
9 |
|
|
10 |
Website Baker is free software; you can redistribute it and/or modify |
|
11 |
it under the terms of the GNU General Public License as published by |
|
12 |
the Free Software Foundation; either version 2 of the License, or |
|
13 |
(at your option) any later version. |
|
14 |
|
|
15 |
Website Baker is distributed in the hope that it will be useful, |
|
16 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
17 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
18 |
GNU General Public License for more details. |
|
19 |
|
|
20 |
You should have received a copy of the GNU General Public License |
|
21 |
along with Website Baker; if not, write to the Free Software |
|
22 |
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
|
23 |
|
|
24 |
*/ |
|
25 |
|
|
26 |
//Modul Description |
|
27 |
$template_description = 'Backend theme from Website Baker 2.7.'; |
|
28 |
|
|
29 |
?> |
|
0 | 30 |
trunk/wb/templates/classic/languages/index.php | ||
---|---|---|
1 |
<?php |
|
2 |
|
|
3 |
// $Id$ |
|
4 |
|
|
5 |
/* |
|
6 |
|
|
7 |
Website Baker Project <http://www.websitebaker.org/> |
|
8 |
Copyright (C) 2004-2009, Ryan Djurovich |
|
9 |
|
|
10 |
Website Baker is free software; you can redistribute it and/or modify |
|
11 |
it under the terms of the GNU General Public License as published by |
|
12 |
the Free Software Foundation; either version 2 of the License, or |
|
13 |
(at your option) any later version. |
|
14 |
|
|
15 |
Website Baker is distributed in the hope that it will be useful, |
|
16 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
17 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
18 |
GNU General Public License for more details. |
|
19 |
|
|
20 |
You should have received a copy of the GNU General Public License |
|
21 |
along with Website Baker; if not, write to the Free Software |
|
22 |
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
|
23 |
|
|
24 |
*/ |
|
25 |
|
|
26 |
header("Location: ../../../index.php"); |
|
27 |
|
|
28 |
?> |
|
0 | 29 |
trunk/wb/templates/classic/languages/DE.php | ||
---|---|---|
1 |
<?php |
|
2 |
|
|
3 |
// $Id$ |
|
4 |
|
|
5 |
/* |
|
6 |
|
|
7 |
Website Baker Project <http://www.websitebaker.org/> |
|
8 |
Copyright (C) 2004-2009, Ryan Djurovich |
|
9 |
|
|
10 |
Website Baker is free software; you can redistribute it and/or modify |
|
11 |
it under the terms of the GNU General Public License as published by |
|
12 |
the Free Software Foundation; either version 2 of the License, or |
|
13 |
(at your option) any later version. |
|
14 |
|
|
15 |
Website Baker is distributed in the hope that it will be useful, |
|
16 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
17 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
18 |
GNU General Public License for more details. |
|
19 |
|
|
20 |
You should have received a copy of the GNU General Public License |
|
21 |
along with Website Baker; if not, write to the Free Software |
|
22 |
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
|
23 |
|
|
24 |
*/ |
|
25 |
|
|
26 |
//Modul Description |
|
27 |
$template_description = 'Das Backend-Theme von Websitebaker 2.7.'; |
|
28 |
|
|
29 |
?> |
|
0 | 30 |
trunk/wb/templates/wb_theme/info.php | ||
---|---|---|
9 | 9 |
* |
10 | 10 |
* LICENSE: GNU General Public License |
11 | 11 |
* |
12 |
* @author Matthias Gallas
|
|
12 |
* @author Johannes Tassilo Gruber
|
|
13 | 13 |
* @copyright GNU General Public License |
14 | 14 |
* @license http://www.gnu.org/licenses/gpl.html |
15 | 15 |
* @version 2.80 |
... | ... | |
32 | 32 |
$template_function = 'theme'; |
33 | 33 |
$template_version = '2.80'; |
34 | 34 |
$template_platform = '2.8'; |
35 |
$template_author = 'Matthias Gallas';
|
|
35 |
$template_author = 'Johannes Tassilo Gruber';
|
|
36 | 36 |
$template_license = '<a href="http://www.gnu.org/licenses/gpl.html">GNU General Public License</a>'; |
37 | 37 |
$template_license_terms = '-'; |
38 | 38 |
$template_description = 'Default backend theme for Website Baker 2.8.'; |
trunk/wb/templates/wb_theme/languages/EN.php | ||
---|---|---|
1 |
<?php |
|
2 |
|
|
3 |
// $Id$ |
|
4 |
|
|
5 |
/* |
|
6 |
|
|
7 |
Website Baker Project <http://www.websitebaker.org/> |
|
8 |
Copyright (C) 2004-2009, Ryan Djurovich |
|
9 |
|
|
10 |
Website Baker is free software; you can redistribute it and/or modify |
|
11 |
it under the terms of the GNU General Public License as published by |
|
12 |
the Free Software Foundation; either version 2 of the License, or |
|
13 |
(at your option) any later version. |
|
14 |
|
|
15 |
Website Baker is distributed in the hope that it will be useful, |
|
16 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
17 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
18 |
GNU General Public License for more details. |
|
19 |
|
|
20 |
You should have received a copy of the GNU General Public License |
|
21 |
along with Website Baker; if not, write to the Free Software |
|
22 |
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
|
23 |
|
|
24 |
*/ |
|
25 |
|
|
26 |
//Modul Description |
|
27 |
$template_description = 'Default backend theme for Website Baker 2.8.'; |
|
28 |
|
|
29 |
?> |
|
0 | 30 |
trunk/wb/templates/wb_theme/languages/index.php | ||
---|---|---|
1 |
<?php |
|
2 |
|
|
3 |
// $Id$ |
|
4 |
|
|
5 |
/* |
|
6 |
|
|
7 |
Website Baker Project <http://www.websitebaker.org/> |
|
8 |
Copyright (C) 2004-2009, Ryan Djurovich |
|
9 |
|
|
10 |
Website Baker is free software; you can redistribute it and/or modify |
|
11 |
it under the terms of the GNU General Public License as published by |
|
12 |
the Free Software Foundation; either version 2 of the License, or |
|
13 |
(at your option) any later version. |
|
14 |
|
|
15 |
Website Baker is distributed in the hope that it will be useful, |
|
16 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
17 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
18 |
GNU General Public License for more details. |
|
19 |
|
|
20 |
You should have received a copy of the GNU General Public License |
|
21 |
along with Website Baker; if not, write to the Free Software |
|
22 |
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
|
23 |
|
|
24 |
*/ |
|
25 |
|
|
26 |
header("Location: ../../../index.php"); |
|
27 |
|
|
28 |
?> |
|
0 | 29 |
trunk/wb/templates/wb_theme/languages/DE.php | ||
---|---|---|
1 |
<?php |
|
2 |
|
|
3 |
// $Id$ |
|
4 |
|
|
5 |
/* |
|
6 |
|
|
7 |
Website Baker Project <http://www.websitebaker.org/> |
|
8 |
Copyright (C) 2004-2009, Ryan Djurovich |
|
9 |
|
|
10 |
Website Baker is free software; you can redistribute it and/or modify |
|
11 |
it under the terms of the GNU General Public License as published by |
|
12 |
the Free Software Foundation; either version 2 of the License, or |
|
13 |
(at your option) any later version. |
|
14 |
|
|
15 |
Website Baker is distributed in the hope that it will be useful, |
|
16 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
17 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
18 |
GNU General Public License for more details. |
|
19 |
|
|
20 |
You should have received a copy of the GNU General Public License |
|
21 |
along with Website Baker; if not, write to the Free Software |
|
22 |
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
|
23 |
|
|
24 |
*/ |
|
25 |
|
|
26 |
//Modul Description |
|
27 |
$template_description = 'Das Standard-Backend-Theme von Websitebaker 2.8'; |
|
28 |
|
|
29 |
?> |
|
0 | 30 |
Also available in: Unified diff
Added language support for template_description (affects templates and themes)