* Fixed issue 7052: Permission problem of RTE images
[Packages/TYPO3.CMS.git] / typo3 / file_edit.php
index 87f1635..3f7478d 100755 (executable)
@@ -2,7 +2,7 @@
 /***************************************************************
 *  Copyright notice
 *
 /***************************************************************
 *  Copyright notice
 *
-*  (c) 1999-2004 Kasper Skaarhoj (kasperYYYY@typo3.com)
+*  (c) 1999-2005 Kasper Skaarhoj (kasperYYYY@typo3.com)
 *  All rights reserved
 *
 *  This script is part of the TYPO3 project. The TYPO3 project is
 *  All rights reserved
 *
 *  This script is part of the TYPO3 project. The TYPO3 project is
@@ -41,7 +41,7 @@
  *   74: class SC_file_edit
  *   93:     function init()
  *  143:     function main()
  *   74: class SC_file_edit
  *   93:     function init()
  *  143:     function main()
- *  206:     function printContent()
+ *  205:     function printContent()
  *
  * TOTAL FUNCTIONS: 3
  * (This index is automatically created/updated by the extension "extdeveval")
  *
  * TOTAL FUNCTIONS: 3
  * (This index is automatically created/updated by the extension "extdeveval")
@@ -73,11 +73,23 @@ require_once(PATH_t3lib.'class.t3lib_basicfilefunc.php');
  */
 class SC_file_edit {
        var $content;           // Module content accumulated.
  */
 class SC_file_edit {
        var $content;           // Module content accumulated.
-       var $basicff;           // File processing object loaded here.
+
+       /**
+        * File processing object
+        *
+        * @var t3lib_basicFileFunctions
+        */
+       var $basicff;
        var $shortPath;
        var $title;
        var $icon;
        var $shortPath;
        var $title;
        var $icon;
-       var $doc;                       // Document template object
+
+       /**
+        * Document template object
+        *
+        * @var template
+        */
+       var $doc;
 
                // Internal, static: GPvar
        var $origTarget;                // Original input target
 
                // Internal, static: GPvar
        var $origTarget;                // Original input target
@@ -172,7 +184,7 @@ class SC_file_edit {
                                // Edit textarea:
                        $code.='
                                <div id="c-edit">
                                // Edit textarea:
                        $code.='
                                <div id="c-edit">
-                                       <textarea rows="30" name="file[editfile][0][data]" wrap="off"'.$this->doc->formWidthText(48,'width:98%;height:80%','off').'>'.
+                                       <textarea rows="30" name="file[editfile][0][data]" wrap="off"'.$this->doc->formWidthText(48,'width:98%;height:80%','off').' class="fixed-font enable-tab">'.
                                        t3lib_div::formatForTextarea($fileContent).
                                        '</textarea>
                                        <input type="hidden" name="file[editfile][0][target]" value="'.$this->target.'" />
                                        t3lib_div::formatForTextarea($fileContent).
                                        '</textarea>
                                        <input type="hidden" name="file[editfile][0][target]" value="'.$this->target.'" />
@@ -195,7 +207,6 @@ class SC_file_edit {
                $this->content.= $this->doc->sectionEnd();
                $this->content.=$code;
 
                $this->content.= $this->doc->sectionEnd();
                $this->content.=$code;
 
-               $this->content.=$this->doc->endPage();
        }
 
        /**
        }
 
        /**
@@ -204,6 +215,8 @@ class SC_file_edit {
         * @return      void
         */
        function printContent() {
         * @return      void
         */
        function printContent() {
+               $this->content.= $this->doc->endPage();
+               $this->content = $this->doc->insertStylesAndJS($this->content);
                echo $this->content;
        }
 }
                echo $this->content;
        }
 }