/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/browser.css |
---|
New file |
0,0 → 1,84 |
/* |
* FCKeditor - The text editor for internet |
* Copyright (C) 2003-2006 Frederico Caldeira Knabben |
* |
* Licensed under the terms of the GNU Lesser General Public License: |
* http://www.opensource.org/licenses/lgpl-license.php |
* |
* For further information visit: |
* http://www.fckeditor.net/ |
* |
* "Support Open Source software. What about a donation today?" |
* |
* File Name: browser.css |
* CSS styles used by all pages that compose the File Browser. |
* |
* File Authors: |
* Frederico Caldeira Knabben (fredck@fckeditor.net) |
*/ |
body |
{ |
background-color: #f1f1e3; |
} |
form |
{ |
margin: 0px 0px 0px 0px ; |
padding: 0px 0px 0px 0px ; |
} |
.Frame |
{ |
background-color: #f1f1e3; |
border-color: #f1f1e3; |
border-right: thin inset; |
border-top: thin inset; |
border-left: thin inset; |
border-bottom: thin inset; |
} |
body.FileArea |
{ |
background-color: #ffffff; |
} |
body, td, input, select |
{ |
font-size: 11px; |
font-family: 'Microsoft Sans Serif' , Arial, Helvetica, Verdana; |
} |
.ActualFolder |
{ |
font-weight: bold; |
font-size: 14px; |
} |
.PopupButtons |
{ |
border-top: #d5d59d 1px solid; |
background-color: #e3e3c7; |
padding: 7px 10px 7px 10px; |
} |
.Button, button |
{ |
border-right: #737357 1px solid; |
border-top: #737357 1px solid; |
border-left: #737357 1px solid; |
color: #3b3b1f; |
border-bottom: #737357 1px solid; |
background-color: #c7c78f; |
} |
.FolderListCurrentFolder img |
{ |
background-image: url(images/FolderOpened.gif); |
} |
.FolderListFolder img |
{ |
background-image: url(images/Folder.gif); |
} |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/frmupload.html |
---|
New file |
0,0 → 1,109 |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> |
<!-- |
* FCKeditor - The text editor for internet |
* Copyright (C) 2003-2006 Frederico Caldeira Knabben |
* |
* Licensed under the terms of the GNU Lesser General Public License: |
* http://www.opensource.org/licenses/lgpl-license.php |
* |
* For further information visit: |
* http://www.fckeditor.net/ |
* |
* "Support Open Source software. What about a donation today?" |
* |
* File Name: frmupload.html |
* Page used to upload new files in the current folder. |
* |
* File Authors: |
* Frederico Caldeira Knabben (fredck@fckeditor.net) |
--> |
<html xmlns="http://www.w3.org/1999/xhtml"> |
<head> |
<link href="browser.css" type="text/css" rel="stylesheet" /> |
<script type="text/javascript" src="js/common.js"></script> |
<script type="text/javascript"> |
function SetCurrentFolder( resourceType, folderPath ) |
{ |
var sUrl = oConnector.ConnectorUrl + 'Command=FileUpload' ; |
sUrl += '&Type=' + resourceType ; |
sUrl += '&CurrentFolder=' + escape( folderPath ) ; |
document.getElementById('frmUpload').action = sUrl ; |
} |
function OnSubmit() |
{ |
if ( document.getElementById('NewFile').value.length == 0 ) |
{ |
alert( 'Please select a file from your computer' ) ; |
return false ; |
} |
// Set the interface elements. |
document.getElementById('eUploadMessage').innerHTML = 'Upload a new file in this folder (Upload in progress, please wait...)' ; |
document.getElementById('btnUpload').disabled = true ; |
return true ; |
} |
function OnUploadCompleted( errorNumber, data ) |
{ |
// Reset the Upload Worker Frame. |
window.parent.frames['frmUploadWorker'].location = '../../../../../fckblank.html' ; |
// Reset the upload form (On IE we must do a little trick to avout problems). |
if ( document.all ) |
document.getElementById('NewFile').outerHTML = '<input id="NewFile" name="NewFile" style="WIDTH: 100%" type="file">' ; |
else |
document.getElementById('frmUpload').reset() ; |
// Reset the interface elements. |
document.getElementById('eUploadMessage').innerHTML = 'Upload a new file in this folder' ; |
document.getElementById('btnUpload').disabled = false ; |
switch ( errorNumber ) |
{ |
case 0 : |
window.parent.frames['frmResourcesList'].Refresh() ; |
break ; |
case 1 : // Custom error. |
alert( data ) ; |
break ; |
case 201 : |
window.parent.frames['frmResourcesList'].Refresh() ; |
alert( 'A file with the same name is already available. The uploaded file has been renamed to "' + data + '"' ) ; |
break ; |
case 202 : |
alert( 'Invalid file' ) ; |
break ; |
default : |
alert( 'Error on file upload. Error number: ' + errorNumber ) ; |
break ; |
} |
} |
window.onload = function() |
{ |
window.top.IsLoadedUpload = true ; |
} |
</script> |
</head> |
<body bottommargin="0" topmargin="0"> |
<form id="frmUpload" action="" target="frmUploadWorker" method="post" enctype="multipart/form-data" onsubmit="return OnSubmit();"> |
<table height="100%" cellspacing="0" cellpadding="0" width="100%" border="0"> |
<tr> |
<td nowrap="nowrap"> |
<span id="eUploadMessage">Upload a new file in this folder</span><br> |
<table cellspacing="0" cellpadding="0" width="100%" border="0"> |
<tr> |
<td width="100%"><input id="NewFile" name="NewFile" style="WIDTH: 100%" type="file"></td> |
<td nowrap="nowrap"> <input id="btnUpload" type="submit" value="Upload"></td> |
</tr> |
</table> |
</td> |
</tr> |
</table> |
</form> |
</body> |
</html> |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/js/common.js |
---|
New file |
0,0 → 1,51 |
/* |
* FCKeditor - The text editor for internet |
* Copyright (C) 2003-2006 Frederico Caldeira Knabben |
* |
* Licensed under the terms of the GNU Lesser General Public License: |
* http://www.opensource.org/licenses/lgpl-license.php |
* |
* For further information visit: |
* http://www.fckeditor.net/ |
* |
* "Support Open Source software. What about a donation today?" |
* |
* File Name: common.js |
* Common objects and functions shared by all pages that compose the |
* File Browser dialog window. |
* |
* File Authors: |
* Frederico Caldeira Knabben (fredck@fckeditor.net) |
*/ |
function AddSelectOption( selectElement, optionText, optionValue ) |
{ |
var oOption = document.createElement("OPTION") ; |
oOption.text = optionText ; |
oOption.value = optionValue ; |
selectElement.options.add(oOption) ; |
return oOption ; |
} |
var oConnector = window.parent.oConnector ; |
var oIcons = window.parent.oIcons ; |
function StringBuilder( value ) |
{ |
this._Strings = new Array( value || '' ) ; |
} |
StringBuilder.prototype.Append = function( value ) |
{ |
if ( value ) |
this._Strings.push( value ) ; |
} |
StringBuilder.prototype.ToString = function() |
{ |
return this._Strings.join( '' ) ; |
} |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/js/fckxml.js |
---|
New file |
0,0 → 1,116 |
/* |
* FCKeditor - The text editor for internet |
* Copyright (C) 2003-2006 Frederico Caldeira Knabben |
* |
* Licensed under the terms of the GNU Lesser General Public License: |
* http://www.opensource.org/licenses/lgpl-license.php |
* |
* For further information visit: |
* http://www.fckeditor.net/ |
* |
* "Support Open Source software. What about a donation today?" |
* |
* File Name: fckxml.js |
* Defines the FCKXml object that is used for XML data calls |
* and XML processing. |
* This script is shared by almost all pages that compose the |
* File Browser frameset. |
* |
* File Authors: |
* Frederico Caldeira Knabben (fredck@fckeditor.net) |
*/ |
var FCKXml = function() |
{} |
FCKXml.prototype.GetHttpRequest = function() |
{ |
// Gecko / IE7 |
if ( typeof(XMLHttpRequest) != 'undefined' ) |
return new XMLHttpRequest() ; |
// IE6 |
try { return new ActiveXObject("Msxml2.XMLHTTP") ; } |
catch(e) {} |
// IE5 |
try { return new ActiveXObject("Microsoft.XMLHTTP") ; } |
catch(e) {} |
} |
FCKXml.prototype.LoadUrl = function( urlToCall, asyncFunctionPointer ) |
{ |
var oFCKXml = this ; |
var bAsync = ( typeof(asyncFunctionPointer) == 'function' ) ; |
var oXmlHttp = this.GetHttpRequest() ; |
oXmlHttp.open( "GET", urlToCall, bAsync ) ; |
if ( bAsync ) |
{ |
oXmlHttp.onreadystatechange = function() |
{ |
if ( oXmlHttp.readyState == 4 ) |
{ |
oFCKXml.DOMDocument = oXmlHttp.responseXML ; |
if ( oXmlHttp.status == 200 || oXmlHttp.status == 304 ) |
asyncFunctionPointer( oFCKXml ) ; |
else |
alert( 'XML request error: ' + oXmlHttp.statusText + ' (' + oXmlHttp.status + ')' ) ; |
} |
} |
} |
oXmlHttp.send( null ) ; |
if ( ! bAsync ) |
{ |
if ( oXmlHttp.status == 200 || oXmlHttp.status == 304 ) |
this.DOMDocument = oXmlHttp.responseXML ; |
else |
{ |
alert( 'XML request error: ' + oXmlHttp.statusText + ' (' + oXmlHttp.status + ')' ) ; |
} |
} |
} |
FCKXml.prototype.SelectNodes = function( xpath ) |
{ |
if ( navigator.userAgent.indexOf('MSIE') >= 0 ) // IE |
return this.DOMDocument.selectNodes( xpath ) ; |
else // Gecko |
{ |
var aNodeArray = new Array(); |
var xPathResult = this.DOMDocument.evaluate( xpath, this.DOMDocument, |
this.DOMDocument.createNSResolver(this.DOMDocument.documentElement), XPathResult.ORDERED_NODE_ITERATOR_TYPE, null) ; |
if ( xPathResult ) |
{ |
var oNode = xPathResult.iterateNext() ; |
while( oNode ) |
{ |
aNodeArray[aNodeArray.length] = oNode ; |
oNode = xPathResult.iterateNext(); |
} |
} |
return aNodeArray ; |
} |
} |
FCKXml.prototype.SelectSingleNode = function( xpath ) |
{ |
if ( navigator.userAgent.indexOf('MSIE') >= 0 ) // IE |
return this.DOMDocument.selectSingleNode( xpath ) ; |
else // Gecko |
{ |
var xPathResult = this.DOMDocument.evaluate( xpath, this.DOMDocument, |
this.DOMDocument.createNSResolver(this.DOMDocument.documentElement), 9, null); |
if ( xPathResult && xPathResult.singleNodeValue ) |
return xPathResult.singleNodeValue ; |
else |
return null ; |
} |
} |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/connectors/test.html |
---|
New file |
0,0 → 1,177 |
<!-- |
* FCKeditor - The text editor for internet |
* Copyright (C) 2003-2006 Frederico Caldeira Knabben |
* |
* Licensed under the terms of the GNU Lesser General Public License: |
* http://www.opensource.org/licenses/lgpl-license.php |
* |
* For further information visit: |
* http://www.fckeditor.net/ |
* |
* "Support Open Source software. What about a donation today?" |
* |
* File Name: test.html |
* Test page for the File Browser connectors. |
* |
* File Authors: |
* Frederico Caldeira Knabben (fredck@fckeditor.net) |
--> |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> |
<html xmlns="http://www.w3.org/1999/xhtml"> |
<head> |
<title>FCKeditor - Connectors Tests</title> |
<meta name="vs_targetSchema" content="http://schemas.microsoft.com/intellisense/ie5" /> |
<script type="text/javascript"> |
function BuildBaseUrl( command ) |
{ |
var sUrl = |
document.getElementById('cmbConnector').value + |
'?Command=' + command + |
'&Type=' + document.getElementById('cmbType').value + |
'&CurrentFolder=' + document.getElementById('txtFolder').value ; |
return sUrl ; |
} |
function SetFrameUrl( url ) |
{ |
if ( document.all ) |
eRunningFrame.document.location = url ; |
else |
document.getElementById('eRunningFrame').src = url ; |
document.getElementById('eUrl').innerHTML = url ; |
} |
function GetFolders() |
{ |
SetFrameUrl( BuildBaseUrl( 'GetFolders' ) ) ; |
return false ; |
} |
function GetFoldersAndFiles() |
{ |
SetFrameUrl( BuildBaseUrl( 'GetFoldersAndFiles' ) ) ; |
return false ; |
} |
function CreateFolder() |
{ |
var sFolder = prompt( 'Type the folder name:', 'Test Folder' ) ; |
if ( ! sFolder ) |
return ; |
var sUrl = BuildBaseUrl( 'CreateFolder' ) ; |
sUrl += '&NewFolderName=' + escape( sFolder ) ; |
SetFrameUrl( sUrl ) ; |
return false ; |
} |
function OnUploadCompleted( errorNumber, fileName ) |
{ |
switch ( errorNumber ) |
{ |
case 0 : |
alert( 'File uploaded with no errors' ) ; |
break ; |
case 201 : |
GetFoldersAndFiles() |
alert( 'A file with the same name is already available. The uploaded file has been renamed to "' + fileName + '"' ) ; |
break ; |
case 202 : |
alert( 'Invalid file' ) ; |
break ; |
default : |
alert( 'Error on file upload. Error number: ' + errorNumber ) ; |
break ; |
} |
} |
this.frames.frmUpload = this ; |
function SetAction() |
{ |
var sUrl = BuildBaseUrl( 'FileUpload' ) ; |
document.getElementById('eUrl').innerHTML = sUrl ; |
document.getElementById('frmUpload').action = sUrl ; |
} |
</script> |
</head> |
<body> |
<table height="100%" cellspacing="0" cellpadding="0" width="100%" border="0"> |
<tr> |
<td> |
<table cellspacing="0" cellpadding="0" border="0"> |
<tr> |
<td> |
Connector:<br /> |
<select id="cmbConnector" name="cmbConnector"> |
<option value="asp/connector.asp" selected="selected">ASP</option> |
<option value="aspx/connector.aspx">ASP.Net</option> |
<option value="cfm/connector.cfm">ColdFusion</option> |
<option value="lasso/connector.lasso">Lasso</option> |
<option value="perl/connector.cgi">Perl</option> |
<option value="php/connector.php">PHP</option> |
<option value="py/connector.py">Python</option> |
</select> |
</td> |
<td> |
</td> |
<td> |
Current Folder<br /> |
<input id="txtFolder" type="text" value="/" name="txtFolder" /></td> |
<td> |
</td> |
<td> |
Resource Type<br /> |
<select id="cmbType" name="cmbType"> |
<option value="File" selected="selected">File</option> |
<option value="Image">Image</option> |
<option value="Flash">Flash</option> |
<option value="Media">Media</option> |
<option value="Invalid">Invalid Type (for testing)</option> |
</select> |
</td> |
</tr> |
</table> |
<br /> |
<table cellspacing="0" cellpadding="0" border="0"> |
<tr> |
<td valign="top"> |
<a href="#" onclick="GetFolders();">Get Folders</a></td> |
<td> |
</td> |
<td valign="top"> |
<a href="#" onclick="GetFoldersAndFiles();">Get Folders and Files</a></td> |
<td> |
</td> |
<td valign="top"> |
<a href="#" onclick="CreateFolder();">Create Folder</a></td> |
<td> |
</td> |
<td valign="top"> |
<form id="frmUpload" action="" target="eRunningFrame" method="post" enctype="multipart/form-data"> |
File Upload<br /> |
<input id="txtFileUpload" type="file" name="NewFile" /> |
<input type="submit" value="Upload" onclick="SetAction();" /> |
</form> |
</td> |
</tr> |
</table> |
<br /> |
URL: <span id="eUrl"></span> |
</td> |
</tr> |
<tr> |
<td height="100%" valign="top"> |
<iframe id="eRunningFrame" src="../../../../fckblank.html" name="eRunningFrame" width="100%" |
height="100%"></iframe> |
</td> |
</tr> |
</table> |
</body> |
</html> |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/connectors/php/connector.php |
---|
New file |
0,0 → 1,109 |
<?php |
/* |
* FCKeditor - The text editor for internet |
* Copyright (C) 2003-2006 Frederico Caldeira Knabben |
* |
* Licensed under the terms of the GNU Lesser General Public License: |
* http://www.opensource.org/licenses/lgpl-license.php |
* |
* For further information visit: |
* http://www.fckeditor.net/ |
* |
* "Support Open Source software. What about a donation today?" |
* |
* File Name: connector.php |
* This is the File Manager Connector for PHP. |
* |
* File Authors: |
* Frederico Caldeira Knabben (fredck@fckeditor.net) |
*/ |
ob_start() ; |
include('config.php') ; |
include('util.php') ; |
include('io.php') ; |
include('basexml.php') ; |
include('commands.php') ; |
if ( !$Config['Enabled'] ) |
SendError( 1, 'This connector is disabled. Please check the "editor/filemanager/browser/default/connectors/php/config.php" file' ) ; |
// Get the "UserFiles" path. |
$GLOBALS["UserFilesPath"] = '' ; |
if ( isset( $Config['UserFilesPath'] ) ) |
$GLOBALS["UserFilesPath"] = $Config['UserFilesPath'] ; |
else if ( isset( $_GET['ServerPath'] ) ) |
$GLOBALS["UserFilesPath"] = $_GET['ServerPath'] ; |
else |
$GLOBALS["UserFilesPath"] = '/UserFiles/' ; |
if ( ! ereg( '/$', $GLOBALS["UserFilesPath"] ) ) |
$GLOBALS["UserFilesPath"] .= '/' ; |
if ( strlen( $Config['UserFilesAbsolutePath'] ) > 0 ) |
{ |
$GLOBALS["UserFilesDirectory"] = $Config['UserFilesAbsolutePath'] ; |
if ( ! ereg( '/$', $GLOBALS["UserFilesDirectory"] ) ) |
$GLOBALS["UserFilesDirectory"] .= '/' ; |
} |
else |
{ |
// Map the "UserFiles" path to a local directory. |
$GLOBALS["UserFilesDirectory"] = GetRootPath() . $GLOBALS["UserFilesPath"] ; |
} |
DoResponse() ; |
function DoResponse() |
{ |
if ( !isset( $_GET['Command'] ) || !isset( $_GET['Type'] ) || !isset( $_GET['CurrentFolder'] ) ) |
return ; |
// Get the main request informaiton. |
$sCommand = $_GET['Command'] ; |
$sResourceType = $_GET['Type'] ; |
$sCurrentFolder = $_GET['CurrentFolder'] ; |
// Check if it is an allowed type. |
if ( !in_array( $sResourceType, array('File','Image','Flash','Media') ) ) |
return ; |
// Check the current folder syntax (must begin and start with a slash). |
if ( ! ereg( '/$', $sCurrentFolder ) ) $sCurrentFolder .= '/' ; |
if ( strpos( $sCurrentFolder, '/' ) !== 0 ) $sCurrentFolder = '/' . $sCurrentFolder ; |
// Check for invalid folder paths (..) |
if ( strpos( $sCurrentFolder, '..' ) ) |
SendError( 102, "" ) ; |
// File Upload doesn't have to Return XML, so it must be intercepted before anything. |
if ( $sCommand == 'FileUpload' ) |
{ |
FileUpload( $sResourceType, $sCurrentFolder ) ; |
return ; |
} |
CreateXmlHeader( $sCommand, $sResourceType, $sCurrentFolder ) ; |
// Execute the required command. |
switch ( $sCommand ) |
{ |
case 'GetFolders' : |
GetFolders( $sResourceType, $sCurrentFolder ) ; |
break ; |
case 'GetFoldersAndFiles' : |
GetFoldersAndFiles( $sResourceType, $sCurrentFolder ) ; |
break ; |
case 'CreateFolder' : |
CreateFolder( $sResourceType, $sCurrentFolder ) ; |
break ; |
} |
CreateXmlFooter() ; |
exit ; |
} |
?> |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/connectors/php/basexml.php |
---|
New file |
0,0 → 1,71 |
<?php |
/* |
* FCKeditor - The text editor for internet |
* Copyright (C) 2003-2006 Frederico Caldeira Knabben |
* |
* Licensed under the terms of the GNU Lesser General Public License: |
* http://www.opensource.org/licenses/lgpl-license.php |
* |
* For further information visit: |
* http://www.fckeditor.net/ |
* |
* "Support Open Source software. What about a donation today?" |
* |
* File Name: basexml.php |
* These functions define the base of the XML response sent by the PHP |
* connector. |
* |
* File Authors: |
* Frederico Caldeira Knabben (fredck@fckeditor.net) |
*/ |
function SetXmlHeaders() |
{ |
ob_end_clean() ; |
// Prevent the browser from caching the result. |
// Date in the past |
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT') ; |
// always modified |
header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT') ; |
// HTTP/1.1 |
header('Cache-Control: no-store, no-cache, must-revalidate') ; |
header('Cache-Control: post-check=0, pre-check=0', false) ; |
// HTTP/1.0 |
header('Pragma: no-cache') ; |
// Set the response format. |
header( 'Content-Type:text/xml; charset=utf-8' ) ; |
} |
function CreateXmlHeader( $command, $resourceType, $currentFolder ) |
{ |
SetXmlHeaders() ; |
// Create the XML document header. |
echo '<?xml version="1.0" encoding="utf-8" ?>' ; |
// Create the main "Connector" node. |
echo '<Connector command="' . $command . '" resourceType="' . $resourceType . '">' ; |
// Add the current folder node. |
echo '<CurrentFolder path="' . ConvertToXmlAttribute( $currentFolder ) . '" url="' . ConvertToXmlAttribute( GetUrlFromPath( $resourceType, $currentFolder ) ) . '" />' ; |
} |
function CreateXmlFooter() |
{ |
echo '</Connector>' ; |
} |
function SendError( $number, $text ) |
{ |
SetXmlHeaders() ; |
// Create the XML document header |
echo '<?xml version="1.0" encoding="utf-8" ?>' ; |
echo '<Connector><Error number="' . $number . '" text="' . htmlspecialchars( $text ) . '" /></Connector>' ; |
exit ; |
} |
?> |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/connectors/php/util.php |
---|
New file |
0,0 → 1,37 |
<?php |
/* |
* FCKeditor - The text editor for internet |
* Copyright (C) 2003-2006 Frederico Caldeira Knabben |
* |
* Licensed under the terms of the GNU Lesser General Public License: |
* http://www.opensource.org/licenses/lgpl-license.php |
* |
* For further information visit: |
* http://www.fckeditor.net/ |
* |
* "Support Open Source software. What about a donation today?" |
* |
* File Name: util.php |
* This is the File Manager Connector for ASP. |
* |
* File Authors: |
* Frederico Caldeira Knabben (fredck@fckeditor.net) |
*/ |
function RemoveFromStart( $sourceString, $charToRemove ) |
{ |
$sPattern = '|^' . $charToRemove . '+|' ; |
return preg_replace( $sPattern, '', $sourceString ) ; |
} |
function RemoveFromEnd( $sourceString, $charToRemove ) |
{ |
$sPattern = '|' . $charToRemove . '+$|' ; |
return preg_replace( $sPattern, '', $sourceString ) ; |
} |
function ConvertToXmlAttribute( $value ) |
{ |
return utf8_encode( htmlspecialchars( $value ) ) ; |
} |
?> |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/connectors/php/commands.php |
---|
New file |
0,0 → 1,218 |
<?php |
/* |
* FCKeditor - The text editor for internet |
* Copyright (C) 2003-2006 Frederico Caldeira Knabben |
* |
* Licensed under the terms of the GNU Lesser General Public License: |
* http://www.opensource.org/licenses/lgpl-license.php |
* |
* For further information visit: |
* http://www.fckeditor.net/ |
* |
* "Support Open Source software. What about a donation today?" |
* |
* File Name: commands.php |
* This is the File Manager Connector for PHP. |
* |
* File Authors: |
* Frederico Caldeira Knabben (fredck@fckeditor.net) |
*/ |
function GetFolders( $resourceType, $currentFolder ) |
{ |
// Map the virtual path to the local server path. |
$sServerDir = ServerMapFolder( $resourceType, $currentFolder ) ; |
// Array that will hold the folders names. |
$aFolders = array() ; |
$oCurrentFolder = opendir( $sServerDir ) ; |
while ( $sFile = readdir( $oCurrentFolder ) ) |
{ |
if ( $sFile != '.' && $sFile != '..' && is_dir( $sServerDir . $sFile ) ) |
$aFolders[] = '<Folder name="' . ConvertToXmlAttribute( $sFile ) . '" />' ; |
} |
closedir( $oCurrentFolder ) ; |
// Open the "Folders" node. |
echo "<Folders>" ; |
natcasesort( $aFolders ) ; |
foreach ( $aFolders as $sFolder ) |
echo $sFolder ; |
// Close the "Folders" node. |
echo "</Folders>" ; |
} |
function GetFoldersAndFiles( $resourceType, $currentFolder ) |
{ |
// Map the virtual path to the local server path. |
$sServerDir = ServerMapFolder( $resourceType, $currentFolder ) ; |
// Arrays that will hold the folders and files names. |
$aFolders = array() ; |
$aFiles = array() ; |
$oCurrentFolder = opendir( $sServerDir ) ; |
while ( $sFile = readdir( $oCurrentFolder ) ) |
{ |
if ( $sFile != '.' && $sFile != '..' ) |
{ |
if ( is_dir( $sServerDir . $sFile ) ) |
$aFolders[] = '<Folder name="' . ConvertToXmlAttribute( $sFile ) . '" />' ; |
else |
{ |
$iFileSize = filesize( $sServerDir . $sFile ) ; |
if ( $iFileSize > 0 ) |
{ |
$iFileSize = round( $iFileSize / 1024 ) ; |
if ( $iFileSize < 1 ) $iFileSize = 1 ; |
} |
$aFiles[] = '<File name="' . ConvertToXmlAttribute( $sFile ) . '" size="' . $iFileSize . '" />' ; |
} |
} |
} |
// Send the folders |
natcasesort( $aFolders ) ; |
echo '<Folders>' ; |
foreach ( $aFolders as $sFolder ) |
echo $sFolder ; |
echo '</Folders>' ; |
// Send the files |
natcasesort( $aFiles ) ; |
echo '<Files>' ; |
foreach ( $aFiles as $sFiles ) |
echo $sFiles ; |
echo '</Files>' ; |
} |
function CreateFolder( $resourceType, $currentFolder ) |
{ |
$sErrorNumber = '0' ; |
$sErrorMsg = '' ; |
if ( isset( $_GET['NewFolderName'] ) ) |
{ |
$sNewFolderName = $_GET['NewFolderName'] ; |
if ( strpos( $sNewFolderName, '..' ) !== FALSE ) |
$sErrorNumber = '102' ; // Invalid folder name. |
else |
{ |
// Map the virtual path to the local server path of the current folder. |
$sServerDir = ServerMapFolder( $resourceType, $currentFolder ) ; |
if ( is_writable( $sServerDir ) ) |
{ |
$sServerDir .= $sNewFolderName ; |
$sErrorMsg = CreateServerFolder( $sServerDir ) ; |
switch ( $sErrorMsg ) |
{ |
case '' : |
$sErrorNumber = '0' ; |
break ; |
case 'Invalid argument' : |
case 'No such file or directory' : |
$sErrorNumber = '102' ; // Path too long. |
break ; |
default : |
$sErrorNumber = '110' ; |
break ; |
} |
} |
else |
$sErrorNumber = '103' ; |
} |
} |
else |
$sErrorNumber = '102' ; |
// Create the "Error" node. |
echo '<Error number="' . $sErrorNumber . '" originalDescription="' . ConvertToXmlAttribute( $sErrorMsg ) . '" />' ; |
} |
function FileUpload( $resourceType, $currentFolder ) |
{ |
$sErrorNumber = '0' ; |
$sFileName = '' ; |
if ( isset( $_FILES['NewFile'] ) && !is_null( $_FILES['NewFile']['tmp_name'] ) ) |
{ |
global $Config ; |
$oFile = $_FILES['NewFile'] ; |
// Map the virtual path to the local server path. |
$sServerDir = ServerMapFolder( $resourceType, $currentFolder ) ; |
// Get the uploaded file name. |
$sFileName = $oFile['name'] ; |
// Replace dots in the name with underscores (only one dot can be there... security issue). |
if ( $Config['ForceSingleExtension'] ) |
$sFileName = preg_replace( '/\\.(?![^.]*$)/', '_', $sFileName ) ; |
$sOriginalFileName = $sFileName ; |
// Get the extension. |
$sExtension = substr( $sFileName, ( strrpos($sFileName, '.') + 1 ) ) ; |
$sExtension = strtolower( $sExtension ) ; |
$arAllowed = $Config['AllowedExtensions'][$resourceType] ; |
$arDenied = $Config['DeniedExtensions'][$resourceType] ; |
if ( ( count($arAllowed) == 0 || in_array( $sExtension, $arAllowed ) ) && ( count($arDenied) == 0 || !in_array( $sExtension, $arDenied ) ) ) |
{ |
$iCounter = 0 ; |
while ( true ) |
{ |
$sFilePath = $sServerDir . $sFileName ; |
if ( is_file( $sFilePath ) ) |
{ |
$iCounter++ ; |
$sFileName = RemoveExtension( $sOriginalFileName ) . '(' . $iCounter . ').' . $sExtension ; |
$sErrorNumber = '201' ; |
} |
else |
{ |
move_uploaded_file( $oFile['tmp_name'], $sFilePath ) ; |
if ( is_file( $sFilePath ) ) |
{ |
$oldumask = umask(0) ; |
chmod( $sFilePath, 0777 ) ; |
umask( $oldumask ) ; |
} |
break ; |
} |
} |
} |
else |
$sErrorNumber = '202' ; |
} |
else |
$sErrorNumber = '202' ; |
echo '<script type="text/javascript">' ; |
echo 'window.parent.frames["frmUpload"].OnUploadCompleted(' . $sErrorNumber . ',"' . str_replace( '"', '\\"', $sFileName ) . '") ;' ; |
echo '</script>' ; |
exit ; |
} |
?> |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/connectors/php/config.php |
---|
New file |
0,0 → 1,51 |
<?php |
/* |
* FCKeditor - The text editor for internet |
* Copyright (C) 2003-2006 Frederico Caldeira Knabben |
* |
* Licensed under the terms of the GNU Lesser General Public License: |
* http://www.opensource.org/licenses/lgpl-license.php |
* |
* For further information visit: |
* http://www.fckeditor.net/ |
* |
* "Support Open Source software. What about a donation today?" |
* |
* File Name: config.php |
* Configuration file for the File Manager Connector for PHP. |
* |
* File Authors: |
* Frederico Caldeira Knabben (fredck@fckeditor.net) |
*/ |
global $Config ; |
// SECURITY: You must explicitelly enable this "connector". (Set it to "true"). |
$Config['Enabled'] = false ; |
// Path to user files relative to the document root. |
$Config['UserFilesPath'] = '/UserFiles/' ; |
// Fill the following value it you prefer to specify the absolute path for the |
// user files directory. Usefull if you are using a virtual directory, symbolic |
// link or alias. Examples: 'C:\\MySite\\UserFiles\\' or '/root/mysite/UserFiles/'. |
// Attention: The above 'UserFilesPath' must point to the same directory. |
$Config['UserFilesAbsolutePath'] = '' ; |
// Due to security issues with Apache modules, it is reccomended to leave the |
// following setting enabled. |
$Config['ForceSingleExtension'] = true ; |
$Config['AllowedExtensions']['File'] = array() ; |
$Config['DeniedExtensions']['File'] = array('php','php2','php3','php4','php5','phtml','pwml','inc','asp','aspx','ascx','jsp','cfm','cfc','pl','bat','exe','com','dll','vbs','js','reg','cgi','htaccess') ; |
$Config['AllowedExtensions']['Image'] = array('jpg','gif','jpeg','png') ; |
$Config['DeniedExtensions']['Image'] = array() ; |
$Config['AllowedExtensions']['Flash'] = array('swf','fla') ; |
$Config['DeniedExtensions']['Flash'] = array() ; |
$Config['AllowedExtensions']['Media'] = array('swf','fla','jpg','gif','jpeg','png','avi','mpg','mpeg') ; |
$Config['DeniedExtensions']['Media'] = array() ; |
?> |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/connectors/php/io.php |
---|
New file |
0,0 → 1,97 |
<?php |
/* |
* FCKeditor - The text editor for internet |
* Copyright (C) 2003-2006 Frederico Caldeira Knabben |
* |
* Licensed under the terms of the GNU Lesser General Public License: |
* http://www.opensource.org/licenses/lgpl-license.php |
* |
* For further information visit: |
* http://www.fckeditor.net/ |
* |
* "Support Open Source software. What about a donation today?" |
* |
* File Name: io.php |
* This is the File Manager Connector for ASP. |
* |
* File Authors: |
* Frederico Caldeira Knabben (fredck@fckeditor.net) |
*/ |
function GetUrlFromPath( $resourceType, $folderPath ) |
{ |
if ( $resourceType == '' ) |
return RemoveFromEnd( $GLOBALS["UserFilesPath"], '/' ) . $folderPath ; |
else |
return $GLOBALS["UserFilesPath"] . $resourceType . $folderPath ; |
} |
function RemoveExtension( $fileName ) |
{ |
return substr( $fileName, 0, strrpos( $fileName, '.' ) ) ; |
} |
function ServerMapFolder( $resourceType, $folderPath ) |
{ |
// Get the resource type directory. |
$sResourceTypePath = $GLOBALS["UserFilesDirectory"] . $resourceType . '/' ; |
// Ensure that the directory exists. |
CreateServerFolder( $sResourceTypePath ) ; |
// Return the resource type directory combined with the required path. |
return $sResourceTypePath . RemoveFromStart( $folderPath, '/' ) ; |
} |
function GetParentFolder( $folderPath ) |
{ |
$sPattern = "-[/\\\\][^/\\\\]+[/\\\\]?$-" ; |
return preg_replace( $sPattern, '', $folderPath ) ; |
} |
function CreateServerFolder( $folderPath ) |
{ |
$sParent = GetParentFolder( $folderPath ) ; |
// Check if the parent exists, or create it. |
if ( !file_exists( $sParent ) ) |
{ |
$sErrorMsg = CreateServerFolder( $sParent ) ; |
if ( $sErrorMsg != '' ) |
return $sErrorMsg ; |
} |
if ( !file_exists( $folderPath ) ) |
{ |
// Turn off all error reporting. |
error_reporting( 0 ) ; |
// Enable error tracking to catch the error. |
ini_set( 'track_errors', '1' ) ; |
// To create the folder with 0777 permissions, we need to set umask to zero. |
$oldumask = umask(0) ; |
mkdir( $folderPath, 0777 ) ; |
umask( $oldumask ) ; |
$sErrorMsg = $php_errormsg ; |
// Restore the configurations. |
ini_restore( 'track_errors' ) ; |
ini_restore( 'error_reporting' ) ; |
return $sErrorMsg ; |
} |
else |
return '' ; |
} |
function GetRootPath() |
{ |
$sRealPath = realpath( './' ) ; |
$sSelfPath = $_SERVER['PHP_SELF'] ; |
$sSelfPath = substr( $sSelfPath, 0, strrpos( $sSelfPath, '/' ) ) ; |
return substr( $sRealPath, 0, strlen( $sRealPath ) - strlen( $sSelfPath ) ) ; |
} |
?> |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/frmactualfolder.html |
---|
New file |
0,0 → 1,63 |
<!-- |
* FCKeditor - The text editor for internet |
* Copyright (C) 2003-2006 Frederico Caldeira Knabben |
* |
* Licensed under the terms of the GNU Lesser General Public License: |
* http://www.opensource.org/licenses/lgpl-license.php |
* |
* For further information visit: |
* http://www.fckeditor.net/ |
* |
* "Support Open Source software. What about a donation today?" |
* |
* File Name: frmactualfolder.html |
* This page shows the actual folder path. |
* |
* File Authors: |
* Frederico Caldeira Knabben (fredck@fckeditor.net) |
--> |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> |
<html> |
<head> |
<link href="browser.css" type="text/css" rel="stylesheet"> |
<script type="text/javascript"> |
function OnResize() |
{ |
divName.style.width = "1px" ; |
divName.style.width = tdName.offsetWidth + "px" ; |
} |
function SetCurrentFolder( resourceType, folderPath ) |
{ |
document.getElementById('tdName').innerHTML = folderPath ; |
} |
window.onload = function() |
{ |
window.top.IsLoadedActualFolder = true ; |
} |
</script> |
</head> |
<body bottomMargin="0" topMargin="0"> |
<table height="100%" cellSpacing="0" cellPadding="0" width="100%" border="0"> |
<tr> |
<td> |
<button style="WIDTH: 100%" type="button"> |
<table cellSpacing="0" cellPadding="0" width="100%" border="0"> |
<tr> |
<td><img height="32" alt="" src="images/FolderOpened32.gif" width="32"></td> |
<td> </td> |
<td id="tdName" width="100%" nowrap class="ActualFolder">/</td> |
<td> </td> |
<td><img height="8" src="images/ButtonArrow.gif" width="12"></td> |
<td> </td> |
</tr> |
</table> |
</button> |
</td> |
</tr> |
</table> |
</body> |
</html> |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/frmresourceslist.html |
---|
New file |
0,0 → 1,150 |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> |
<!-- |
* FCKeditor - The text editor for internet |
* Copyright (C) 2003-2006 Frederico Caldeira Knabben |
* |
* Licensed under the terms of the GNU Lesser General Public License: |
* http://www.opensource.org/licenses/lgpl-license.php |
* |
* For further information visit: |
* http://www.fckeditor.net/ |
* |
* "Support Open Source software. What about a donation today?" |
* |
* File Name: frmresourceslist.html |
* This page shows all resources available in a folder in the File Browser. |
* |
* File Authors: |
* Frederico Caldeira Knabben (fredck@fckeditor.net) |
--> |
<html xmlns="http://www.w3.org/1999/xhtml"> |
<head> |
<link href="browser.css" type="text/css" rel="stylesheet" /> |
<script type="text/javascript" src="js/common.js"></script> |
<script type="text/javascript"> |
var oListManager = new Object() ; |
oListManager.Clear = function() |
{ |
document.body.innerHTML = '' ; |
} |
oListManager.GetFolderRowHtml = function( folderName, folderPath ) |
{ |
// Build the link to view the folder. |
var sLink = '<a href="#" onclick="OpenFolder(\'' + folderPath.replace( /'/g, '\\\'') + '\');return false;">' ; |
return '<tr>' + |
'<td width="16">' + |
sLink + |
'<img alt="" src="images/Folder.gif" width="16" height="16" border="0"></a>' + |
'</td><td nowrap colspan="2"> ' + |
sLink + |
folderName + |
'</a>' + |
'</td></tr>' ; |
} |
oListManager.GetFileRowHtml = function( fileName, fileUrl, fileSize ) |
{ |
// Build the link to view the folder. |
var sLink = '<a href="#" onclick="OpenFile(\'' + fileUrl.replace( /'/g, '\\\'') + '\');return false;">' ; |
// Get the file icon. |
var sIcon = oIcons.GetIcon( fileName ) ; |
return '<tr>' + |
'<td width="16">' + |
sLink + |
'<img alt="" src="images/icons/' + sIcon + '.gif" width="16" height="16" border="0"></a>' + |
'</td><td> ' + |
sLink + |
fileName + |
'</a>' + |
'</td><td align="right" nowrap> ' + |
fileSize + |
' KB' + |
'</td></tr>' ; |
} |
function OpenFolder( folderPath ) |
{ |
// Load the resources list for this folder. |
window.parent.frames['frmFolders'].LoadFolders( folderPath ) ; |
} |
function OpenFile( fileUrl ) |
{ |
window.top.opener.SetUrl( fileUrl ) ; |
window.top.close() ; |
window.top.opener.focus() ; |
} |
function LoadResources( resourceType, folderPath ) |
{ |
oListManager.Clear() ; |
oConnector.ResourceType = resourceType ; |
oConnector.CurrentFolder = folderPath ; |
oConnector.SendCommand( 'GetFoldersAndFiles', null, GetFoldersAndFilesCallBack ) ; |
} |
function Refresh() |
{ |
LoadResources( oConnector.ResourceType, oConnector.CurrentFolder ) ; |
} |
function GetFoldersAndFilesCallBack( fckXml ) |
{ |
if ( oConnector.CheckError( fckXml ) != 0 ) |
return ; |
// Get the current folder path. |
var oNode = fckXml.SelectSingleNode( 'Connector/CurrentFolder' ) ; |
var sCurrentFolderPath = oNode.attributes.getNamedItem('path').value ; |
var sCurrentFolderUrl = oNode.attributes.getNamedItem('url').value ; |
// var dTimer = new Date() ; |
var oHtml = new StringBuilder( '<table id="tableFiles" cellspacing="1" cellpadding="0" width="100%" border="0">' ) ; |
// Add the Folders. |
var oNodes = fckXml.SelectNodes( 'Connector/Folders/Folder' ) ; |
for ( var i = 0 ; i < oNodes.length ; i++ ) |
{ |
var sFolderName = oNodes[i].attributes.getNamedItem('name').value ; |
oHtml.Append( oListManager.GetFolderRowHtml( sFolderName, sCurrentFolderPath + sFolderName + "/" ) ) ; |
} |
// Add the Files. |
var oNodes = fckXml.SelectNodes( 'Connector/Files/File' ) ; |
for ( var i = 0 ; i < oNodes.length ; i++ ) |
{ |
var oNode = oNodes[i] ; |
var sFileName = oNode.attributes.getNamedItem('name').value ; |
var sFileSize = oNode.attributes.getNamedItem('size').value ; |
// Get the optional "url" attribute. If not available, build the url. |
var oFileUrlAtt = oNodes[i].attributes.getNamedItem('url') ; |
var sFileUrl = oFileUrlAtt != null ? oFileUrlAtt.value : sCurrentFolderUrl + sFileName ; |
oHtml.Append( oListManager.GetFileRowHtml( sFileName, sFileUrl, sFileSize ) ) ; |
} |
oHtml.Append( '</table>' ) ; |
document.body.innerHTML = oHtml.ToString() ; |
// window.top.document.title = 'Finished processing in ' + ( ( ( new Date() ) - dTimer ) / 1000 ) + ' seconds' ; |
} |
window.onload = function() |
{ |
window.top.IsLoadedResourcesList = true ; |
} |
</script> |
</head> |
<body class="FileArea" bottommargin="10" leftmargin="10" topmargin="10" rightmargin="10"> |
</body> |
</html> |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/frmresourcetype.html |
---|
New file |
0,0 → 1,61 |
<!-- |
* FCKeditor - The text editor for internet |
* Copyright (C) 2003-2006 Frederico Caldeira Knabben |
* |
* Licensed under the terms of the GNU Lesser General Public License: |
* http://www.opensource.org/licenses/lgpl-license.php |
* |
* For further information visit: |
* http://www.fckeditor.net/ |
* |
* "Support Open Source software. What about a donation today?" |
* |
* File Name: frmresourcetype.html |
* This page shows the list of available resource types. |
* |
* File Authors: |
* Frederico Caldeira Knabben (fredck@fckeditor.net) |
--> |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> |
<html> |
<head> |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"> |
<link href="browser.css" type="text/css" rel="stylesheet"> |
<script type="text/javascript" src="js/common.js"></script> |
<script language="javascript"> |
function SetResourceType( type ) |
{ |
window.parent.frames["frmFolders"].SetResourceType( type ) ; |
} |
var aTypes = [ |
['File','File'], |
['Image','Image'], |
['Flash','Flash'], |
['Media','Media'] |
] ; |
window.onload = function() |
{ |
for ( var i = 0 ; i < aTypes.length ; i++ ) |
{ |
if ( oConnector.ShowAllTypes || aTypes[i][0] == oConnector.ResourceType ) |
AddSelectOption( document.getElementById('cmbType'), aTypes[i][1], aTypes[i][0] ) ; |
} |
} |
</script> |
</head> |
<body bottomMargin="0" topMargin="0"> |
<table height="100%" cellSpacing="0" cellPadding="0" width="100%" border="0"> |
<tr> |
<td nowrap> |
Resource Type<BR> |
<select id="cmbType" style="WIDTH: 100%" onchange="SetResourceType(this.value);"> |
</select> |
</td> |
</tr> |
</table> |
</body> |
</html> |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/ButtonArrow.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/ButtonArrow.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/FolderOpened.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/FolderOpened.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/exe.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/exe.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/rdp.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/rdp.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/htm.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/htm.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/ai.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/ai.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/vsd.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/vsd.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/swf.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/swf.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/mp3.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/mp3.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/xml.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/xml.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/zip.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/zip.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/fla.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/fla.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/mdb.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/mdb.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/ppt.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/ppt.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/html.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/html.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/cs.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/cs.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/doc.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/doc.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/gif.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/gif.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/xls.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/xls.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/pdf.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/pdf.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/dll.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/dll.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/default.icon.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/default.icon.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/js.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/js.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/swt.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/swt.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/bmp.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/bmp.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/avi.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/avi.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/txt.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/txt.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/jpg.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/jpg.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/htm.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/htm.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/ai.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/ai.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/vsd.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/vsd.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/swf.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/swf.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/mp3.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/mp3.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/xml.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/xml.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/zip.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/zip.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/fla.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/fla.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/mdb.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/mdb.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/ppt.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/ppt.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/html.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/html.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/gif.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/gif.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/doc.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/doc.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/cs.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/cs.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/xls.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/xls.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/pdf.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/pdf.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/dll.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/dll.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/default.icon.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/default.icon.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/js.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/js.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/swt.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/swt.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/bmp.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/bmp.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/txt.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/txt.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/avi.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/avi.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/jpg.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/jpg.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/exe.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/exe.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/rdp.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/icons/32/rdp.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/Folder.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/Folder.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/FolderOpened32.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/FolderOpened32.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/spacer.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/spacer.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/Folder32.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/Folder32.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/FolderUp.gif |
---|
Cannot display: file marked as a binary type. |
svn:mime-type = application/octet-stream |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/images/FolderUp.gif |
---|
New file |
Property changes: |
Added: svn:mime-type |
+application/octet-stream |
\ No newline at end of property |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/browser.html |
---|
New file |
0,0 → 1,148 |
<!-- |
* FCKeditor - The text editor for internet |
* Copyright (C) 2003-2006 Frederico Caldeira Knabben |
* |
* Licensed under the terms of the GNU Lesser General Public License: |
* http://www.opensource.org/licenses/lgpl-license.php |
* |
* For further information visit: |
* http://www.fckeditor.net/ |
* |
* "Support Open Source software. What about a donation today?" |
* |
* File Name: browser.html |
* This page compose the File Browser dialog frameset. |
* |
* File Authors: |
* Frederico Caldeira Knabben (fredck@fckeditor.net) |
--> |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> |
<html> |
<head> |
<title>FCKeditor - Resources Browser</title> |
<link href="browser.css" type="text/css" rel="stylesheet"> |
<script type="text/javascript" src="js/fckxml.js"></script> |
<script language="javascript"> |
function GetUrlParam( paramName ) |
{ |
var oRegex = new RegExp( '[\?&]' + paramName + '=([^&]+)', 'i' ) ; |
var oMatch = oRegex.exec( window.top.location.search ) ; |
if ( oMatch && oMatch.length > 1 ) |
return unescape( oMatch[1] ) ; |
else |
return '' ; |
} |
var oConnector = new Object() ; |
oConnector.CurrentFolder = '/' ; |
var sConnUrl = GetUrlParam( 'Connector' ) ; |
// Gecko has some problems when using relative URLs (not starting with slash). |
if ( sConnUrl.substr(0,1) != '/' && sConnUrl.indexOf( '://' ) < 0 ) |
sConnUrl = window.location.href.replace( /browser.html.*$/, '' ) + sConnUrl ; |
oConnector.ConnectorUrl = sConnUrl + ( sConnUrl.indexOf('?') != -1 ? '&' : '?' ) ; |
var sServerPath = GetUrlParam( 'ServerPath' ) ; |
if ( sServerPath.length > 0 ) |
oConnector.ConnectorUrl += 'ServerPath=' + escape( sServerPath ) + '&' ; |
oConnector.ResourceType = GetUrlParam( 'Type' ) ; |
oConnector.ShowAllTypes = ( oConnector.ResourceType.length == 0 ) ; |
if ( oConnector.ShowAllTypes ) |
oConnector.ResourceType = 'File' ; |
oConnector.SendCommand = function( command, params, callBackFunction ) |
{ |
var sUrl = this.ConnectorUrl + 'Command=' + command ; |
sUrl += '&Type=' + this.ResourceType ; |
sUrl += '&CurrentFolder=' + escape( this.CurrentFolder ) ; |
if ( params ) sUrl += '&' + params ; |
var oXML = new FCKXml() ; |
if ( callBackFunction ) |
oXML.LoadUrl( sUrl, callBackFunction ) ; // Asynchronous load. |
else |
return oXML.LoadUrl( sUrl ) ; |
} |
oConnector.CheckError = function( responseXml ) |
{ |
var iErrorNumber = 0 |
var oErrorNode = responseXml.SelectSingleNode( 'Connector/Error' ) ; |
if ( oErrorNode ) |
{ |
iErrorNumber = parseInt( oErrorNode.attributes.getNamedItem('number').value ) ; |
switch ( iErrorNumber ) |
{ |
case 0 : |
break ; |
case 1 : // Custom error. Message placed in the "text" attribute. |
alert( oErrorNode.attributes.getNamedItem('text').value ) ; |
break ; |
case 101 : |
alert( 'Folder already exists' ) ; |
break ; |
case 102 : |
alert( 'Invalid folder name' ) ; |
break ; |
case 103 : |
alert( 'You have no permissions to create the folder' ) ; |
break ; |
case 110 : |
alert( 'Unknown error creating folder' ) ; |
break ; |
default : |
alert( 'Error on your request. Error number: ' + iErrorNumber ) ; |
break ; |
} |
} |
return iErrorNumber ; |
} |
var oIcons = new Object() ; |
oIcons.AvailableIconsArray = [ |
'ai','avi','bmp','cs','dll','doc','exe','fla','gif','htm','html','jpg','js', |
'mdb','mp3','pdf','ppt','rdp','swf','swt','txt','vsd','xls','xml','zip' ] ; |
oIcons.AvailableIcons = new Object() ; |
for ( var i = 0 ; i < oIcons.AvailableIconsArray.length ; i++ ) |
oIcons.AvailableIcons[ oIcons.AvailableIconsArray[i] ] = true ; |
oIcons.GetIcon = function( fileName ) |
{ |
var sExtension = fileName.substr( fileName.lastIndexOf('.') + 1 ).toLowerCase() ; |
if ( this.AvailableIcons[ sExtension ] == true ) |
return sExtension ; |
else |
return 'default.icon' ; |
} |
</script> |
</head> |
<frameset cols="150,*" class="Frame" framespacing="3" bordercolor="#f1f1e3" frameborder="1"> |
<frameset rows="50,*" framespacing="0"> |
<frame src="frmresourcetype.html" scrolling="no" frameborder="0"> |
<frame name="frmFolders" src="frmfolders.html" scrolling="auto" frameborder="1"> |
</frameset> |
<frameset rows="50,*,50" framespacing="0"> |
<frame name="frmActualFolder" src="frmactualfolder.html" scrolling="no" frameborder="0"> |
<frame name="frmResourcesList" src="frmresourceslist.html" scrolling="auto" frameborder="1"> |
<frameset cols="150,*,0" framespacing="0" frameborder="0"> |
<frame name="frmCreateFolder" src="frmcreatefolder.html" scrolling="no" frameborder="0"> |
<frame name="frmUpload" src="frmupload.html" scrolling="no" frameborder="0"> |
<frame name="frmUploadWorker" src="../../../fckblank.html" scrolling="no" frameborder="0"> |
</frameset> |
</frameset> |
</frameset> |
</html> |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/frmfolders.html |
---|
New file |
0,0 → 1,192 |
<!-- |
* FCKeditor - The text editor for internet |
* Copyright (C) 2003-2006 Frederico Caldeira Knabben |
* |
* Licensed under the terms of the GNU Lesser General Public License: |
* http://www.opensource.org/licenses/lgpl-license.php |
* |
* For further information visit: |
* http://www.fckeditor.net/ |
* |
* "Support Open Source software. What about a donation today?" |
* |
* File Name: frmfolders.html |
* This page shows the list of folders available in the parent folder |
* of the current folder. |
* |
* File Authors: |
* Frederico Caldeira Knabben (fredck@fckeditor.net) |
--> |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> |
<html> |
<head> |
<link href="browser.css" type="text/css" rel="stylesheet"> |
<script type="text/javascript" src="js/common.js"></script> |
<script language="javascript"> |
var sActiveFolder ; |
var bIsLoaded = false ; |
var iIntervalId ; |
var oListManager = new Object() ; |
oListManager.Init = function() |
{ |
this.Table = document.getElementById('tableFiles') ; |
this.UpRow = document.getElementById('trUp') ; |
this.TableRows = new Object() ; |
} |
oListManager.Clear = function() |
{ |
// Remove all other rows available. |
while ( this.Table.rows.length > 1 ) |
this.Table.deleteRow(1) ; |
// Reset the TableRows collection. |
this.TableRows = new Object() ; |
} |
oListManager.AddItem = function( folderName, folderPath ) |
{ |
// Create the new row. |
var oRow = this.Table.insertRow(-1) ; |
oRow.className = 'FolderListFolder' ; |
// Build the link to view the folder. |
var sLink = '<a href="#" onclick="OpenFolder(\'' + folderPath + '\');return false;">' ; |
// Add the folder icon cell. |
var oCell = oRow.insertCell(-1) ; |
oCell.width = 16 ; |
oCell.innerHTML = sLink + '<img alt="" src="images/spacer.gif" width="16" height="16" border="0"></a>' ; |
// Add the folder name cell. |
oCell = oRow.insertCell(-1) ; |
oCell.noWrap = true ; |
oCell.innerHTML = ' ' + sLink + folderName + '</a>' ; |
this.TableRows[ folderPath ] = oRow ; |
} |
oListManager.ShowUpFolder = function( upFolderPath ) |
{ |
this.UpRow.style.display = ( upFolderPath != null ? '' : 'none' ) ; |
if ( upFolderPath != null ) |
{ |
document.getElementById('linkUpIcon').onclick = document.getElementById('linkUp').onclick = function() |
{ |
LoadFolders( upFolderPath ) ; |
return false ; |
} |
} |
} |
function CheckLoaded() |
{ |
if ( window.top.IsLoadedActualFolder |
&& window.top.IsLoadedCreateFolder |
&& window.top.IsLoadedUpload |
&& window.top.IsLoadedResourcesList ) |
{ |
window.clearInterval( iIntervalId ) ; |
bIsLoaded = true ; |
OpenFolder( sActiveFolder ) ; |
} |
} |
function OpenFolder( folderPath ) |
{ |
sActiveFolder = folderPath ; |
if ( ! bIsLoaded ) |
{ |
if ( ! iIntervalId ) |
iIntervalId = window.setInterval( CheckLoaded, 100 ) ; |
return ; |
} |
// Change the style for the select row (to show the opened folder). |
for ( var sFolderPath in oListManager.TableRows ) |
{ |
oListManager.TableRows[ sFolderPath ].className = |
( sFolderPath == folderPath ? 'FolderListCurrentFolder' : 'FolderListFolder' ) ; |
} |
// Set the current folder in all frames. |
window.parent.frames['frmActualFolder'].SetCurrentFolder( oConnector.ResourceType, folderPath ) ; |
window.parent.frames['frmCreateFolder'].SetCurrentFolder( oConnector.ResourceType, folderPath ) ; |
window.parent.frames['frmUpload'].SetCurrentFolder( oConnector.ResourceType, folderPath ) ; |
// Load the resources list for this folder. |
window.parent.frames['frmResourcesList'].LoadResources( oConnector.ResourceType, folderPath ) ; |
} |
function LoadFolders( folderPath ) |
{ |
// Clear the folders list. |
oListManager.Clear() ; |
// Get the parent folder path. |
var sParentFolderPath ; |
if ( folderPath != '/' ) |
sParentFolderPath = folderPath.substring( 0, folderPath.lastIndexOf( '/', folderPath.length - 2 ) + 1 ) ; |
// Show/Hide the Up Folder. |
oListManager.ShowUpFolder( sParentFolderPath ) ; |
if ( folderPath != '/' ) |
{ |
sActiveFolder = folderPath ; |
oConnector.CurrentFolder = sParentFolderPath |
oConnector.SendCommand( 'GetFolders', null, GetFoldersCallBack ) ; |
} |
else |
OpenFolder( '/' ) ; |
} |
function GetFoldersCallBack( fckXml ) |
{ |
if ( oConnector.CheckError( fckXml ) != 0 ) |
return ; |
// Get the current folder path. |
var oNode = fckXml.SelectSingleNode( 'Connector/CurrentFolder' ) ; |
var sCurrentFolderPath = oNode.attributes.getNamedItem('path').value ; |
var oNodes = fckXml.SelectNodes( 'Connector/Folders/Folder' ) ; |
for ( var i = 0 ; i < oNodes.length ; i++ ) |
{ |
var sFolderName = oNodes[i].attributes.getNamedItem('name').value ; |
oListManager.AddItem( sFolderName, sCurrentFolderPath + sFolderName + "/" ) ; |
} |
OpenFolder( sActiveFolder ) ; |
} |
function SetResourceType( type ) |
{ |
oConnector.ResourceType = type ; |
LoadFolders( '/' ) ; |
} |
window.onload = function() |
{ |
oListManager.Init() ; |
LoadFolders( '/' ) ; |
} |
</script> |
</head> |
<body class="FileArea" bottomMargin="10" leftMargin="10" topMargin="10" rightMargin="10"> |
<table id="tableFiles" cellSpacing="0" cellPadding="0" width="100%" border="0"> |
<tr id="trUp" style="DISPLAY: none"> |
<td width="16"><a id="linkUpIcon" href="#"><img alt="" src="images/FolderUp.gif" width="16" height="16" border="0"></a></td> |
<td nowrap width="100%"> <a id="linkUp" href="#">..</a></td> |
</tr> |
</table> |
</body> |
</html> |
/branches/livraison_aha/api/fckeditor/editor/filemanager/browser/default/frmcreatefolder.html |
---|
New file |
0,0 → 1,109 |
<!-- |
* FCKeditor - The text editor for internet |
* Copyright (C) 2003-2006 Frederico Caldeira Knabben |
* |
* Licensed under the terms of the GNU Lesser General Public License: |
* http://www.opensource.org/licenses/lgpl-license.php |
* |
* For further information visit: |
* http://www.fckeditor.net/ |
* |
* "Support Open Source software. What about a donation today?" |
* |
* File Name: frmcreatefolder.html |
* Page used to create new folders in the current folder. |
* |
* File Authors: |
* Frederico Caldeira Knabben (fredck@fckeditor.net) |
--> |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> |
<html> |
<head> |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"> |
<link href="browser.css" type="text/css" rel="stylesheet"> |
<script type="text/javascript" src="js/common.js"></script> |
<script language="javascript"> |
function SetCurrentFolder( resourceType, folderPath ) |
{ |
oConnector.ResourceType = resourceType ; |
oConnector.CurrentFolder = folderPath |
} |
function CreateFolder() |
{ |
var sFolderName ; |
while ( true ) |
{ |
sFolderName = prompt( 'Type the name of the new folder:', '' ) ; |
if ( sFolderName == null ) |
return ; |
else if ( sFolderName.length == 0 ) |
alert( 'Please type the folder name' ) ; |
else |
break ; |
} |
oConnector.SendCommand( 'CreateFolder', 'NewFolderName=' + escape( sFolderName) , CreateFolderCallBack ) ; |
} |
function CreateFolderCallBack( fckXml ) |
{ |
if ( oConnector.CheckError( fckXml ) == 0 ) |
window.parent.frames['frmResourcesList'].Refresh() ; |
/* |
// Get the current folder path. |
var oNode = fckXml.SelectSingleNode( 'Connector/Error' ) ; |
var iErrorNumber = parseInt( oNode.attributes.getNamedItem('number').value ) ; |
switch ( iErrorNumber ) |
{ |
case 0 : |
window.parent.frames['frmResourcesList'].Refresh() ; |
break ; |
case 101 : |
alert( 'Folder already exists' ) ; |
break ; |
case 102 : |
alert( 'Invalid folder name' ) ; |
break ; |
case 103 : |
alert( 'You have no permissions to create the folder' ) ; |
break ; |
case 110 : |
alert( 'Unknown error creating folder' ) ; |
break ; |
default : |
alert( 'Error creating folder. Error number: ' + iErrorNumber ) ; |
break ; |
} |
*/ |
} |
window.onload = function() |
{ |
window.top.IsLoadedCreateFolder = true ; |
} |
</script> |
</head> |
<body bottomMargin="0" topMargin="0"> |
<table height="100%" cellSpacing="0" cellPadding="0" width="100%" border="0"> |
<tr> |
<td> |
<button type="button" style="WIDTH: 100%" onclick="CreateFolder();"> |
<table cellSpacing="0" cellPadding="0" border="0"> |
<tr> |
<td><img height="16" alt="" src="images/Folder.gif" width="16"></td> |
<td> </td> |
<td nowrap>Create New Folder</td> |
</tr> |
</table> |
</button> |
</td> |
</tr> |
</table> |
</body> |
</html> |