@@ -19,7 +19,7 @@ |
||
19 | 19 | 'cmssite' => $cmssite |
20 | 20 | ); |
21 | 21 | |
22 | - $tpl = $this->template->create(dirname(__FILE__) . '/templates/stylesheet-edit'); |
|
22 | + $tpl = $this->template->create(dirname(__FILE__).'/templates/stylesheet-edit'); |
|
23 | 23 | return $tpl->render($this, $data); |
24 | 24 | } |
25 | 25 |
@@ -71,7 +71,7 @@ |
||
71 | 71 | 'element_types' => $element_types |
72 | 72 | ); |
73 | 73 | |
74 | - $tpl = $this->template->create(dirname(__FILE__) . '/templates/section-html'); |
|
74 | + $tpl = $this->template->create(dirname(__FILE__).'/templates/section-html'); |
|
75 | 75 | return $tpl->render($this, $data); |
76 | 76 | } |
77 | 77 |
@@ -34,7 +34,7 @@ |
||
34 | 34 | 'kernel' => $this->getKernel() |
35 | 35 | ); |
36 | 36 | |
37 | - $tpl = $this->template->create(dirname(__FILE__) . '/templates/template-section-edit'); |
|
37 | + $tpl = $this->template->create(dirname(__FILE__).'/templates/template-section-edit'); |
|
38 | 38 | return $tpl->render($this, $data); |
39 | 39 | } |
40 | 40 |
@@ -51,7 +51,7 @@ discard block |
||
51 | 51 | 'sections' => $this->getModel()->getSections() |
52 | 52 | ); |
53 | 53 | |
54 | - $tpl = $this->template->create(dirname(__FILE__) . '/templates/template'); |
|
54 | + $tpl = $this->template->create(dirname(__FILE__).'/templates/template'); |
|
55 | 55 | return $tpl->render($this, $data); |
56 | 56 | } |
57 | 57 | |
@@ -63,7 +63,7 @@ discard block |
||
63 | 63 | 'translation' => $this->getKernel()->getTranslation() |
64 | 64 | ); |
65 | 65 | |
66 | - $tpl = $this->template->create(dirname(__FILE__) . '/templates/template-edit'); |
|
66 | + $tpl = $this->template->create(dirname(__FILE__).'/templates/template-edit'); |
|
67 | 67 | return $tpl->render($this, $data); |
68 | 68 | } |
69 | 69 |
@@ -44,7 +44,7 @@ discard block |
||
44 | 44 | 'kernel' => $this->getKernel() |
45 | 45 | ); |
46 | 46 | |
47 | - $tpl = $this->template->create(dirname(__FILE__) . '/templates/site'); |
|
47 | + $tpl = $this->template->create(dirname(__FILE__).'/templates/site'); |
|
48 | 48 | return $tpl->render($this, $data); |
49 | 49 | } |
50 | 50 | |
@@ -64,7 +64,7 @@ discard block |
||
64 | 64 | 'translation' => $this->getKernel()->getTranslation('cms') |
65 | 65 | ); |
66 | 66 | |
67 | - $tpl = $this->template->create(dirname(__FILE__) . '/templates/site-edit'); |
|
67 | + $tpl = $this->template->create(dirname(__FILE__).'/templates/site-edit'); |
|
68 | 68 | return $tpl->render($this, $data); |
69 | 69 | } |
70 | 70 |
@@ -92,7 +92,7 @@ discard block |
||
92 | 92 | 'news' => $news |
93 | 93 | ); |
94 | 94 | |
95 | - $tpl = $this->template->create(dirname(__FILE__) . '/templates/pages'); |
|
95 | + $tpl = $this->template->create(dirname(__FILE__).'/templates/pages'); |
|
96 | 96 | return $tpl->render($this, $data); |
97 | 97 | } |
98 | 98 | |
@@ -146,7 +146,7 @@ discard block |
||
146 | 146 | 'kernel' => $this->getKernel(), |
147 | 147 | 'cmspages' => $cmspages); |
148 | 148 | |
149 | - $tpl = $this->template->create(dirname(__FILE__) . '/templates/page-edit'); |
|
149 | + $tpl = $this->template->create(dirname(__FILE__).'/templates/page-edit'); |
|
150 | 150 | return $tpl->render($this, $data); |
151 | 151 | } |
152 | 152 | |
@@ -158,12 +158,12 @@ discard block |
||
158 | 158 | |
159 | 159 | if ($cmspage->save($_POST)) { |
160 | 160 | if (!empty($_POST['choose_file']) && $this->getKernel()->user->hasModuleAccess('filemanager')) { |
161 | - return new k_SeeOther($this->url($cmspage->get('id') . '/filehandler/selectfile', array('images' => 1))); |
|
161 | + return new k_SeeOther($this->url($cmspage->get('id').'/filehandler/selectfile', array('images' => 1))); |
|
162 | 162 | } elseif (!empty($_POST['close'])) { |
163 | 163 | return new k_SeeOther($this->url($cmspage->get('id'))); |
164 | 164 | } elseif (!empty($_POST['add_keywords'])) { |
165 | 165 | $keyword_shared = $this->getKernel()->useShared('keyword'); |
166 | - return new k_SeeOther($this->url($cmspage->get('id') . '/keyword/connect')); |
|
166 | + return new k_SeeOther($this->url($cmspage->get('id').'/keyword/connect')); |
|
167 | 167 | } else { |
168 | 168 | return new k_SeeOther($this->url(null, array('type' => $cmspage->get('type')))); |
169 | 169 | } |
@@ -19,7 +19,7 @@ |
||
19 | 19 | |
20 | 20 | function getSiteId() |
21 | 21 | { |
22 | - return $this->context->name(); |
|
22 | + return $this->context->name(); |
|
23 | 23 | } |
24 | 24 | |
25 | 25 | function renderHtml() |
@@ -37,7 +37,7 @@ discard block |
||
37 | 37 | 'templates' => $templates |
38 | 38 | ); |
39 | 39 | |
40 | - $tpl = $this->template->create(dirname(__FILE__) . '/templates/templates'); |
|
40 | + $tpl = $this->template->create(dirname(__FILE__).'/templates/templates'); |
|
41 | 41 | return $tpl->render($this, $data); |
42 | 42 | } |
43 | 43 | |
@@ -54,7 +54,7 @@ discard block |
||
54 | 54 | 'translation' => $this->getKernel()->getTranslation() |
55 | 55 | ); |
56 | 56 | |
57 | - $tpl = $this->template->create(dirname(__FILE__) . '/templates/template-edit'); |
|
57 | + $tpl = $this->template->create(dirname(__FILE__).'/templates/template-edit'); |
|
58 | 58 | return $tpl->render($this, $data); |
59 | 59 | } |
60 | 60 |
@@ -17,6 +17,9 @@ |
||
17 | 17 | } |
18 | 18 | } |
19 | 19 | |
20 | + /** |
|
21 | + * @return integer |
|
22 | + */ |
|
20 | 23 | function getSiteId() |
21 | 24 | { |
22 | 25 | return $this->context->name(); |
@@ -24,7 +24,7 @@ discard block |
||
24 | 24 | function setEditor($editor) |
25 | 25 | { |
26 | 26 | if (!in_array($editor, $this->implemented_editors)) { |
27 | - throw new Exception($editor . 'editor not implemented'); |
|
27 | + throw new Exception($editor.'editor not implemented'); |
|
28 | 28 | } |
29 | 29 | |
30 | 30 | $this->editor = $editor; |
@@ -87,8 +87,8 @@ discard block |
||
87 | 87 | } |
88 | 88 | |
89 | 89 | if (in_array('a', $this->allowed_tags)) { |
90 | - $button[]= 'link'; |
|
91 | - $button[]= 'unlink'; |
|
90 | + $button[] = 'link'; |
|
91 | + $button[] = 'unlink'; |
|
92 | 92 | } |
93 | 93 | |
94 | 94 | if (in_array('ul', $this->allowed_tags)) { |
@@ -58,7 +58,7 @@ discard block |
||
58 | 58 | $element['extra_style'] = ' style="'.$element['extra_style'].'"'; |
59 | 59 | } |
60 | 60 | |
61 | - $function = 'parse'.$element['type'] . 'Element'; |
|
61 | + $function = 'parse'.$element['type'].'Element'; |
|
62 | 62 | $output = $this->$function($element); |
63 | 63 | |
64 | 64 | $display .= '<div id="element-'.$element['id'].'"'.$element['extra_class'].$element['extra_style'].'>'; |
@@ -76,9 +76,9 @@ discard block |
||
76 | 76 | } else { |
77 | 77 | $display .= ' <li><a href="'.url(null).'?action=move&element_id='.$element['id'].'&id='.$element['section_id'].'">'.$this->t('move').'</a></li>'; |
78 | 78 | } |
79 | - $display .= ' <li><a class="confirm" href="' . url(null) . '?delete='.$element['id'].'">'.$this->t('delete').'</a></li>'; |
|
80 | - $display .= ' </ul>'; |
|
81 | - $display .= '<div>' . $output . '</div>'; |
|
79 | + $display .= ' <li><a class="confirm" href="'.url(null).'?delete='.$element['id'].'">'.$this->t('delete').'</a></li>'; |
|
80 | + $display .= ' </ul>'; |
|
81 | + $display .= '<div>'.$output.'</div>'; |
|
82 | 82 | $display .= '</div>'; |
83 | 83 | } |
84 | 84 | return $display; |
@@ -21,6 +21,9 @@ |
||
21 | 21 | $this->translation = $translation; |
22 | 22 | } |
23 | 23 | |
24 | + /** |
|
25 | + * @param string $phrase |
|
26 | + */ |
|
24 | 27 | function t($phrase) |
25 | 28 | { |
26 | 29 | return utf8_encode($this->translation->get($phrase)); |