<?php
/**
*  Copyright 2008 Grestul Group 
*  Powered by Grestul
*  admin panel creator: Imad Jomaa
**/
?>
<?php session_start
();
require 
"inc/config.php";
if(!isset(
$_SESSION['loggedin'])) {
   
header('Location: index.php?error=1');
   exit();
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="content-type" content="text/html; charset=iso-8859-1" />
    <title><?php echo "$webad"?></title>
      <link href="inc/admin.css" rel="stylesheet" type="text/css" />
      <link href="inc/general.css" rel="stylesheet" type="text/css" />
</head>
<body>
<img src="inc/images/logo.png" class="logo" />
<div class="logout"><a href="close.php">Logout</a></div>
<div class="navi">
<a href="home.php"><img src="inc/images/homeoff.png" class="navihoff" /></a>
<a href="management.php"><img src="inc/images/manageoff.png" class="navioff" /></a>
<a href="stylehome.php"><img src="inc/images/styleon.png" class="navion" /></a>
</div>


        <div class="contentrep">
    <div class="infobar">
        <div class="infotext">
      Here, you can modify the General Configuration pages style that is located under the Management Tab. Be carefull
      while modifying the style and keep the orginal as a refrence.
      </div>
    </div>
        <div class="btite">
      Grestul Management - Main Administration Style
        </div>
      <div class="smalltite">
      You are currently modifying: General Config Style.
      </div>

  <div class="bodycontent">
<?php
if($_POST['Submit']){
echo 
'<div class="pass">';
echo 
"Template Updated!";
echo 
'</div>';
}
else
if(
$_POST['Submit']){
echo 
'<div class="fail">';
echo 
"Can't update the template! &mdash; make sure the file is CHMODded.";
echo 
'</div>';
}
?>
  <fieldset>
  <legend>General Config Style</legend>

<?php
if($_POST['Submit']){
$open fopen("inc/general.css","w+");
$styler $_POST['update'];
fwrite($open$styler);
fclose($open);
$file file("inc/general.css");
echo 
"<form action=\"".$PHP_SELF."\" method=\"post\">";
echo 
"<textarea Name=\"update\" cols=\"79\" rows=\"10\">";
foreach(
$file as $styler) {
echo 
stripslashes($styler);
}
echo 
"</textarea>";
echo 
"</fieldset>";
echo 
"<input name=\"Submit\" type=\"submit\" class=\"submit\" value=\"Update\" />\n
</form>"
;
}else if(
is_writable("inc/general.css")) {
$file file("inc/general.css");
echo 
"<form action=\"".$PHP_SELF."\" method=\"post\">";
echo 
"<textarea Name=\"update\" cols=\"79\" rows=\"10\">";
foreach(
$file as $styler) {
echo 
stripslashes($styler);

echo 
"</textarea>";
echo 
"</fieldset>";
echo 
"<input name=\"Submit\" type=\"submit\" class=\"submit\" value=\"Update\" />\n
</form>"
;
}
else {
echo 
'<div class="fail">';
echo 
"The general.css file isn't writable! Please CHMOD admin/inc/general.css to use this editor";
echo 
'</div>';
}
?> 

</div>        </div>
<div class="footer">
<!-- DO NOT CHANGE, REMOVE, OR HINDER WITH THE COPYRIGHT OR POWERED BY LINES BELOW -->
<!-- YOU AGREED TO THE AGREEMENT WHEN YOU DOWNLOADED AND INSTALLED OUR SOFTWARE -->
<!-- REMOVING THE LINES BELOW WILL FORCE US TO TAKE LEGAL ACTION -->
<!-- BE FAIR AND KEEP THE POWERED BY AND COPYRIGHT LINES. -->
Powered By: <a href="http://grestul.com" target="_blank">Grestul,</a> Copyright &copy; 2008 <a href="http://grestul.com" target="_blank">Grestul Group.</a>
</div>


</body>
</html>