aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKevin Chabowski <kevin@kch42.de>2012-01-29 21:31:24 +0100
committerKevin Chabowski <kevin@kch42.de>2012-01-29 21:31:24 +0100
commit72345613cff72ca49608baa1c2956825858cfb43 (patch)
tree0bb5b6f853f5ae27b738c1e314a33be1e21e52c7
parentc51eaea0d750bc53e737bea426c154024d882b22 (diff)
downloadratatoeskr-cms-72345613cff72ca49608baa1c2956825858cfb43.tar.gz
ratatoeskr-cms-72345613cff72ca49608baa1c2956825858cfb43.tar.bz2
ratatoeskr-cms-72345613cff72ca49608baa1c2956825858cfb43.zip
Fixed a bug in the article editor.
when editing a already existing article, the status was always set to visible.
-rw-r--r--ratatoeskr/backend.php10
1 files changed, 4 insertions, 6 deletions
diff --git a/ratatoeskr/backend.php b/ratatoeskr/backend.php
index 76e8d25..469d966 100644
--- a/ratatoeskr/backend.php
+++ b/ratatoeskr/backend.php
@@ -189,11 +189,6 @@ $backend_subactions = url_action_subactions(array(
/* Check Form */
$fail_reasons = array();
- $inputs = array(
- "date" => time(),
- "article_status" => ARTICLE_STATUS_LIVE
- );
-
if(isset($_POST["save_article"]))
{
if(!preg_match('/^[a-zA-Z0-9-_]+$/', @$_POST["urlname"]))
@@ -256,7 +251,10 @@ $backend_subactions = url_action_subactions(array(
{
/* New Article */
$ste->vars["pagetitle"] = $translation["new_article"];
-
+ $inputs = array(
+ "date" => time(),
+ "article_status" => ARTICLE_STATUS_LIVE
+ );
if(empty($fail_reasons) and isset($_POST["save_article"]))
{
$article = Article::create($inputs["urlname"]);