From 12a7f489fac3e168d35213d3412daaa02c0011e5 Mon Sep 17 00:00:00 2001 From: pecesama Date: Thu, 12 Jul 2007 05:17:52 +0000 Subject: [PATCH] v0.85 --- admin/admin.php | 5 +- admin/ajax.php | 3 +- admin/close.php | 87 +++++++------ admin/css/style.css | 3 +- admin/index.php | 15 ++- admin/options.php | 128 ++++++++++++++++++++ admin/settings.php | 20 ++- admin/user.php | 4 +- classes/configuration.class.php | 54 ++++++--- classes/functions.php | 5 +- classes/gelato.class.php | 14 ++- classes/pagination.class.php | 195 ++++++++++++++++++++++++++++++ classes/pagination.php | 138 --------------------- classes/user.class.php | 3 +- config-sample.php | 3 +- db/gelato_db.sql | 33 ++++- index.php | 25 ++-- install.php | 61 +++++++--- login.php | 7 +- readme.txt | 15 ++- rss.php | 8 +- themes/tumblr/template_header.htm | 3 +- update.php | 71 +++++++++++ 23 files changed, 648 insertions(+), 252 deletions(-) create mode 100644 admin/options.php create mode 100644 classes/pagination.class.php delete mode 100644 classes/pagination.php create mode 100644 update.php diff --git a/admin/admin.php b/admin/admin.php index 95b34c7..a774cf4 100644 --- a/admin/admin.php +++ b/admin/admin.php @@ -1,7 +1,8 @@ isAdmin()) { gelato :: admin users + diff --git a/admin/ajax.php b/admin/ajax.php index 1f96ad9..c8baa9d 100644 --- a/admin/ajax.php +++ b/admin/ajax.php @@ -1,7 +1,8 @@ closeSession() ?> - - - - gelato - - - - - + + + + gelato :: logout + + + + + + - -
- gelato CMS -
- -
-
-
-

Closing session

-

+

+ +
+ +
+ + +
+

+

Ending session...

+ -

-

Ending session...

+

Has happened an error when closing the session.

-

Has happened an error when closing the session.

- -

+

+
+ + +
+
+
-
-

- gelato CMS :: PHP/MySQL Tumblelog Content Management System. -

-
-
-
\ No newline at end of file diff --git a/admin/css/style.css b/admin/css/style.css index 57817b5..3f04841 100644 --- a/admin/css/style.css +++ b/admin/css/style.css @@ -1,6 +1,7 @@ /* =========================== - gelato CMS development version + gelato CMS - A PHP based tumblelog CMS + development version http://www.gelatocms.com/ gelato CMS is a free software licensed under GPL (General public license) diff --git a/admin/index.php b/admin/index.php index 0f7de66..dd66070 100644 --- a/admin/index.php +++ b/admin/index.php @@ -1,7 +1,8 @@ isAdmin()) { + gelato :: control panel @@ -315,6 +317,7 @@ if ($user->isAdmin()) { @@ -407,8 +410,12 @@ if ($user->isAdmin()) { break; } } - - echo pagination($tumble->getPostsNumber(), $limit, isset($page_num) ? $page_num : 1, "index.php", 2); + + $p = new pagination; + $p->items($tumble->getPostsNumber()); + $p->limit($limit); + $p->currentPage(isset($page_num) ? $page_num : 1); + $p->show(); } else { diff --git a/admin/options.php b/admin/options.php new file mode 100644 index 0000000..148d5db --- /dev/null +++ b/admin/options.php @@ -0,0 +1,128 @@ + +isAdmin()) { + + if(isset($_POST["btnsubmit"])) { + unset($_POST["btnsubmit"]); + $tumble->saveOption($_POST["rich_text"], "rich_text"); + $tumble->saveOption($_POST["urlFriendly"], "rich_text"); + } else { +?> + + + + gelato :: options + + + + + + + + + + +
+ +
+ +
+ +

 

+The configuration has been modified successfully.
"; + } + } + if (isset($_GET["error"])) { + if ($_GET["error"]==1) { + echo "
Error on the database server: ".$_GET["des"]."
"; + } + } +?> +
+ +
+
+
    +
  • + +
  • +
  • + +
  • +
+
+

+ +

+
+ +
+ + +
+
+ +
+ + +urlGelato."/login.php"); +} +?> \ No newline at end of file diff --git a/admin/settings.php b/admin/settings.php index 4ec121a..4532ac4 100644 --- a/admin/settings.php +++ b/admin/settings.php @@ -1,7 +1,8 @@ isAdmin()) { gelato :: settings + \n"; - $gelato_includes .= "\t\n"; - $gelato_includes .= "\turlGelato."/admin/css/slimbox.css\" />\n"; + $gelato_includes = "\n"; + $gelato_includes .= "\t\n"; $gelato_includes .= "\turlGelato."/images/favicon.ico\" />\n"; + $gelato_includes .= "\turlGelato."/rss.php\"/>\n"; $gelato_includes .= "\turlGelato."/themes/".$conf->template."/style.css\"/>\n"; - $gelato_includes .= "\turlGelato."/rss.php\"/>"; + $gelato_includes .= "\turlGelato."/admin/css/slimbox.css\" />\n"; + $gelato_includes .= "\t\n"; + $gelato_includes .= "\t"; $input = array("{Gelato_includes}","{Title}", "{Description}", "{URL_Tumble}", "{Template_name}"); $output = array($gelato_includes, $conf->title, $conf->description, $conf->urlGelato, $conf->template); @@ -164,7 +167,15 @@ } } - echo pagination($tumble->getPostsNumber(), $limit, isset($page_num) ? $page_num : 1, array($conf->urlGelato."/index.php/page/[...]/","[...]"), 2); + $p = new pagination; + $p->Items($tumble->getPostsNumber()); + $p->limit($limit); + + $p->urlFriendly('[...]'); + $p->target($conf->urlGelato."/index.php/page/[...]/"); + + $p->currentPage(isset($page_num) ? $page_num : 1); + $p->show(); } else { diff --git a/install.php b/install.php index 6accfe9..395f0dd 100644 --- a/install.php +++ b/install.php @@ -1,7 +1,8 @@ - gelato :: installation - + + gelato :: installation