source: branches/dev/html/admin/design/css.php @ 17

Revision 17, 1.2 KB checked in by uehara, 17 years ago (diff)
Line 
1<?php
2/*
3 * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
4 *
5 * http://www.lockon.co.jp/
6 */
7require_once("../../require.php");
8
9class LC_Page {
10    var $arrForm;
11    var $arrHidden;
12
13    function LC_Page() {
14        $this->tpl_mainpage = 'design/css.tpl';
15        $this->tpl_subnavi  = 'design/subnavi.tpl';
16        $this->area_row = 30;
17        $this->tpl_subno = "css";
18        $this->tpl_mainno = "design";
19        $this->tpl_subtitle = 'CSSÊÔ½¸';
20    }
21}
22
23$objPage = new LC_Page();
24$objView = new SC_AdminView();
25
26// ǧ¾Ú²ÄÈݤÎȽÄê
27$objSess = new SC_Session();
28sfIsSuccess($objSess);
29
30$css_path = USER_PATH . "css/contents.css";
31
32// ¥Ç¡¼¥¿¹¹¿·½èÍý
33if ($_POST['mode'] == 'confirm'){
34    // ¥×¥ì¥Ó¥å¡¼Íѥƥó¥×¥ì¡¼¥È¤Ë½ñ¤­¹þ¤ß   
35    $fp = fopen($css_path,"w");
36    fwrite($fp, $_POST['css']);
37    fclose($fp);
38   
39    $objPage->tpl_onload="alert('ÅÐÏ¿¤¬´°Î»¤·¤Þ¤·¤¿¡£');";
40}
41
42// CSS¥Õ¥¡¥¤¥ë¤ÎÆɤ߹þ¤ß
43if(file_exists($css_path)){
44    $css_data = file_get_contents($css_path);
45}
46
47// ¥Æ¥­¥¹¥È¥¨¥ê¥¢¤Ëɽ¼¨
48$objPage->css_data = $css_data;
49
50// ²èÌ̤Îɽ¼¨
51$objView->assignobj($objPage);
52$objView->display(MAIN_FRAME);
53
54//---------------------------------------------------------------------------------------------------------------------------------------------------------
Note: See TracBrowser for help on using the repository browser.