|
@@ -23,10 +23,17 @@ $conf = new configuration();
|
23
|
23
|
|
24
|
24
|
if ($user->isAdmin()) {
|
25
|
25
|
|
26
|
|
- if(isset($_POST["btnsubmit"])) {
|
27
|
|
- unset($_POST["btnsubmit"]);
|
28
|
|
- $tumble->saveOption($_POST["rich_text"], "rich_text");
|
29
|
|
- $tumble->saveOption($_POST["urlFriendly"], "rich_text");
|
|
26
|
+ if(isset($_POST["btnsubmit"])) {
|
|
27
|
+ if (!$tumble->saveOption($_POST["rich_text"], "rich_text")) {
|
|
28
|
+ header("Location: ".$conf->urlGelato."/admin/options.php?error=1&des=".$conf->merror);
|
|
29
|
+ die();
|
|
30
|
+ }
|
|
31
|
+ if (!$tumble->saveOption($_POST["url_friendly"], "url_friendly")) {
|
|
32
|
+ header("Location: ".$conf->urlGelato."/admin/options.php?error=1&des=".$conf->merror);
|
|
33
|
+ die();
|
|
34
|
+ }
|
|
35
|
+ header("Location: ".$conf->urlGelato."/admin/options.php?modified=true");
|
|
36
|
+ die();
|
30
|
37
|
} else {
|
31
|
38
|
?>
|
32
|
39
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
@@ -92,12 +99,12 @@ if ($user->isAdmin()) {
|
92
|
99
|
<fieldset>
|
93
|
100
|
<ul>
|
94
|
101
|
<li><label for="rich_text"><?=__("Rich text editor:")?></label>
|
95
|
|
- <select name="rich_text" id="rich_text">
|
|
102
|
+ <select name="rich_text" id="rich_text">
|
96
|
103
|
<option value="1" <?php if($conf->richText) echo "selected"; ?>><?=__("Active")?></option>
|
97
|
104
|
<option value="0" <?php if(!$conf->richText) echo "selected"; ?>><?=__("Deactive")?></option>
|
98
|
105
|
</select>
|
99
|
106
|
</li>
|
100
|
|
- <li><label for="rich_text">URL friendly:</label>
|
|
107
|
+ <li><label for="url_friendly">URL friendly:</label>
|
101
|
108
|
<select name="url_friendly" id="url_friendly">
|
102
|
109
|
<option value="1" <?php if($conf->urlFriendly) echo "selected"; ?>><?=__("Active")?></option>
|
103
|
110
|
<option value="0" <?php if(!$conf->urlFriendly) echo "selected"; ?>><?=__("Deactive")?></option>
|