Починены баги со страницами, всё приведено в общий вид.

Почему-то стиль page.css подключается дважды. Всё проверил, не знаю почему так.
This commit is contained in:
Linux User 2011-06-30 12:12:06 +08:00
parent b4479c938d
commit 29e518c652
226 changed files with 28 additions and 55 deletions

View file

@ -9,7 +9,7 @@
*/
Editor::$language = strtolower(substr(I18n::$lang, 0, 2));
Editor_Ckeditor::$path = 'assets/ckeditor';
Editor_Ckeditor::$path = 'ckeditor';
// set your editor profiles
// NOTE: when MarkItUp! used, you should set its size at PATH/skins/SKINNAME/style.css

View file

@ -1,20 +1,15 @@
<!doctype html>
<html>
<head>
<title>Добавление страницы</title>
<meta charset="utf-8">
<link rel="stylesheet" type="text/css" media="screen" href="/assets/css/admin.css">
<?php $editor = Editor::factory()->set('width', '')->set('height', 300);
if ($editor->css() != NULL) foreach($editor->css() as $css) echo html::style($css);
if ($editor->js() != NULL) foreach($editor->js() as $js) echo html::script($js);
<?php
$styles = array("page.css");
$editor = Editor::factory()->set('width', '')->set('height', 300);
array_merge($styles, $editor->css());
echo Request::factory('header/standard')
->post('title',"Редактирование страницы")
->post('styles',$styles)
->post('scripts',$editor->js())
->execute();
?>
</head>
<body>
<div id="error"><?php if(!empty($error)) echo $error;?></div>
<div id="message"><?php if(!empty($message)) echo $message;?></div>
<p>Существующие страницы:</p>
<?php echo Request::factory('navigation/standard')->execute() ?>
<hr>
<h3>Добавление страницы</h3>
<?php echo form::open('admin/pages/add') ?>
<p><?php echo form::label('name','Короткое имя: '); echo form::input('name','') ?></p>
@ -25,5 +20,4 @@ if ($editor->js() != NULL) foreach($editor->js() as $js) echo html::script($js);
<?php $editor->render(TRUE, FALSE); ?>
</p>
<?php echo form::close() ?>
</body>
</html>
<?php echo Request::factory('footer/standard')->execute() ?>

View file

@ -1,11 +1,4 @@
<!doctype html>
<html>
<head>
<title>Удаление страницы</title>
<meta charset="utf-8">
<link rel="stylesheet" type="text/css" media="screen" href="/assets/css/admin.css">
</head>
<body>
<?php echo Request::factory('header/standard')->post('title',"Удаление страницы")->post('styles','page.css')->execute() ?>
<div id="error"><?php if(!empty($error)) echo $error;?></div>
<div id="message"><?php if(!empty($message)) echo $message;?></div>
<h3>Удаление страницы <?php echo $name ?></h3>
@ -15,5 +8,4 @@
<p><?php echo form::submit('submit','Удалить страницу') ?>
</p>
<?php echo form::close() ?>
</body>
</html>
<?php echo Request::factory('footer/standard')->execute() ?>

View file

@ -1,15 +1,13 @@
<!doctype html>
<html>
<head>
<title>Редактирование страницы</title>
<meta charset="utf-8">
<link rel="stylesheet" type="text/css" media="screen" href="/assets/css/admin.css">
<?php $editor = Editor::factory()->set('width', '')->set('height', 300);
if ($editor->css() != NULL) foreach($editor->css() as $css) echo html::style($css);
if ($editor->js() != NULL) foreach($editor->js() as $js) echo html::script($js);
<?php
$styles = array("page.css");
$editor = Editor::factory()->set('width', '')->set('height', 300);
array_merge($styles, $editor->css());
echo Request::factory('header/standard')
->post('title',"Редактирование страницы")
->post('styles',$styles)
->post('scripts',$editor->js())
->execute();
?>
</head>
<body>
<div id="error"><?php if(!empty($error)) echo $error;?></div>
<div id="message"><?php if(!empty($message)) echo $message;?></div>
<h3>Редактирование страницы <?php echo $name ?></h3>
@ -22,5 +20,4 @@ if ($editor->js() != NULL) foreach($editor->js() as $js) echo html::script($js);
<?php $editor->render(TRUE, FALSE); ?>
</p>
<?php echo form::close(); ?>
</body>
</html>
<?php echo Request::factory('footer/standard')->execute() ?>

View file

@ -1,11 +1,4 @@
<!doctype html>
<html>
<head>
<title>Обзор страниц</title>
<meta charset="utf-8">
<link rel="stylesheet" type="text/css" media="screen" href="/assets/css/admin.css">
</head>
<body>
<?php echo Request::factory('header/standard')->post('title',"Обзор страниц")->post('styles','page.css')->execute() ?>
<div id="error"><?php if(!empty($error)) echo $error;?></div>
<div id="message"><?php if(!empty($message)) echo $message;?></div>
<p>Существующие страницы:</p>
@ -16,15 +9,12 @@
<?php foreach($pages as $id=>$page):?>
<tr>
<td><?php echo $page->id;?></td><td><a href="/page/view/<?php echo $page->id;?>"><?php echo $page->name;?></a></td><td><?php echo $page->order;?></td>
<td><?php echo HTML::anchor('admin/pages/edit/'.$page->id, '<img id="image_edit">');?></td>
<td><?php echo HTML::anchor('admin/pages/delete/'.$page->id, '<img id="image_delete">');?></td>
<td><?php echo HTML::anchor('pages/edit/'.$page->id, 'Редактировать');?></td>
<td><?php echo HTML::anchor('pages/delete/'.$page->id, 'Удалить');?></td>
</tr>
<?php endforeach;?>
</tbody>
</table>
<p><a href="/admin/pages/add">Добавить страницу</a></p>
<p><a href="/admin/users/logout">Разлогиниться</a></p>
<img id="image">
</body>
</html>
<p><?php echo HTML::anchor("pages/add", "Добавить страницу")?></p>
<?php echo Request::factory('footer/standard')->execute() ?>

View file

Before

Width:  |  Height:  |  Size: 43 B

After

Width:  |  Height:  |  Size: 43 B

View file

Before

Width:  |  Height:  |  Size: 2.7 KiB

After

Width:  |  Height:  |  Size: 2.7 KiB

View file

Before

Width:  |  Height:  |  Size: 256 B

After

Width:  |  Height:  |  Size: 256 B

Some files were not shown because too many files have changed in this diff Show more