資源簡介
18731.rar
代碼片段和文件信息
“““
FCKeditor?-?The?text?editor?for?Internet?-?http://www.fckeditor.net
Copyright?(C)?2003-2007?Frederico?Caldeira?Knabben
==?BEGIN?LICENSE?==
Licensed?under?the?terms?of?any?of?the?following?licenses?at?your
choice:
?-?GNU?General?Public?License?Version?2?or?later?(the?“GPL“)
???http://www.gnu.org/licenses/gpl.html
?-?GNU?Lesser?General?Public?License?Version?2.1?or?later?(the?“LGPL“)
???http://www.gnu.org/licenses/lgpl.html
?-?Mozilla?Public?License?Version?1.1?or?later?(the?“MPL“)
???http://www.mozilla.org/MPL/MPL-1.1.html
==?END?LICENSE?==
This?is?the?integration?file?for?Python.
“““
import?cgi
import?os
import?string
def?escape(text?replace=string.replace):
????“““Converts?the?special?characters?‘<‘?‘>‘?and?‘&‘.
????RFC?1866?specifies?that?these?characters?be?represented
????in?HTML?as?<?>?and?&?respectively.?In?Python
????1.5?we?use?the?new?string.replace()?function?for?speed.
????“““
????text?=?replace(text?‘&‘?‘&‘)?#?must?be?done?1st
????text?=?replace(text?‘<‘?‘<‘)
????text?=?replace(text?‘>‘?‘>‘)
????text?=?replace(text?‘“‘?‘"‘)
????text?=?replace(text?“‘“?‘‘‘)
????return?text
#?The?FCKeditor?class
class?FCKeditor(object):
def?__init__(self?instanceName):
self.InstanceName?=?instanceName
self.basePath?=?‘/fckeditor/‘
self.Width?=?‘100%‘
self.Height?=?‘200‘
self.ToolbarSet?=?‘Default‘
self.Value?=?‘‘;
self.Config?=?{}
def?Create(self):
return?self.CreateHtml()
def?CreateHtml(self):
HtmlValue?=?escape(self.Value)
Html?=?““
if?(self.IsCompatible()):
File?=?“fckeditor.html“
link?=?“%seditor/%s?InstanceName=%s“?%?(
self.basePath
File
self.InstanceName
)
if?(self.ToolbarSet?is?not?None):
link?+=?“&ToolBar=%s“?%?self.ToolbarSet
#?Render?the?linked?hidden?field
Html?+=?“yle=\“display:none\“?/>“?%?(
self.InstanceName
self.InstanceName
HtmlValue
)
#?Render?the?configurations?hidden?field
Html?+=?“yle=\“display:none\“?/>“?%?(
self.InstanceName
self.GetConfigFieldString()
)
#?Render?the?editor?iframe
Html?+=?“rame?id=\“%s\__frame\“?src=\“%s\“?width=\“%s\“?height=\“%s\“?frameborder=\“0\“?scrolling=\“no\“> rame>“?%?(
self.InstanceName
link
self.Width
self.Height
)
else:
if?(self.Width.find(“%%“)?0):
WidthCSS?=?“%spx“?%?self.Width
else:
WidthCSS?=?self.Width
if?(self.Height.find(“%%“)?0):
HeightCSS?=?“%spx“?%?self.Height
else:
HeightCSS?=?self.Height
Html?+=?““?%?(
self.InstanceName
WidthCSS
HeightCSS
HtmlValue
)
Html?+=?“ “
return?Html
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
????..A..H.???????121??2007-10-16?16:42??18731\chapter-02\htdocs\.htaccess
?????文件???????1281??2007-10-16?16:44??18731\chapter-02\htdocs\index.php
?????文件????????370??2007-10-16?16:42??18731\chapter-02\httpd.conf
?????文件????????142??2007-10-16?16:42??18731\chapter-02\include\Controllers\IndexController.php
?????文件????????209??2007-12-12?13:37??18731\chapter-02\include\CustomControllerAction.php
?????文件??????12748??2007-10-16?16:40??18731\chapter-02\include\Smarty\Config_File.class.php
?????文件???????3562??2007-10-16?16:40??18731\chapter-02\include\Smarty\debug.tpl
?????文件???????1949??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.assemble_plugin_filepath.php
?????文件???????1258??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.assign_smarty_interface.php
?????文件???????2507??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.create_dir_structure.php
?????文件???????1583??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.display_debug_console.php
?????文件???????1002??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.get_include_path.php
?????文件????????360??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.get_microtime.php
?????文件???????2467??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.get_php_resource.php
?????文件???????1694??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.is_secure.php
?????文件???????1284??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.is_trusted.php
?????文件???????4429??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.load_plugins.php
?????文件???????2147??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.load_resource_plugin.php
?????文件???????2464??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.process_cached_inserts.php
?????文件???????1011??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.process_compiled_include.php
?????文件???????3604??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.read_cache_file.php
?????文件???????1444??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.rmdir.php
?????文件???????2286??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.rm_auto.php
?????文件???????2656??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.run_insert_handler.php
?????文件???????1602??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.smarty_include_php.php
?????文件???????3620??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.write_cache_file.php
?????文件???????3130??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.write_compiled_include.php
?????文件???????1081??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.write_compiled_resource.php
?????文件???????1524??2007-10-16?16:40??18731\chapter-02\include\Smarty\internals\core.write_file.php
?????文件???????2843??2007-10-16?16:40??18731\chapter-02\include\Smarty\plugins\block.textformat.php
............此處省略7137個文件信息
評論
共有 條評論