FCKeditor

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
megabob3
Power Poster
Power Poster
Posts: 498
Joined: Sat Jan 08, 2005 11:11 pm

FCKeditor

Post by megabob3 »

FCKeditor module all seems OK

Pls try this http://www.awakening.it/uploads/FCKeditor.zip

Pls controls if FCKeditor save this line:
{cms_module module="onemodule"}
in
{cms_module module="onemodule"}


For a directly view of this WYSIWYG go here:
www.awakening.it/test

user: admin
pass: admin



My next step is go on Singapore like module.

Bye :)
jah
Forum Members
Forum Members
Posts: 147
Joined: Thu Dec 30, 2004 9:09 am

FCKEditor image upload

Post by jah »

It is great that you are working with FCKEditor and I tried your online installation.

It seems to work, but I'm not able to upload and insert images. Neither can I create folders in the upload menu. I tried to upload an image but it did not show up. Maybe it was uploaded to another folder?
jah
Forum Members
Forum Members
Posts: 147
Joined: Thu Dec 30, 2004 9:09 am

FCKEditor image upload

Post by jah »

It is great that you are working with FCKEditor and I tried your online installation.

It seems to work, but I'm not able to upload and insert images. Neither can I create folders in the upload menu. I tried to upload an image but it did not show up. Maybe it was uploaded to another folder?
megabob3
Power Poster
Power Poster
Posts: 498
Joined: Sat Jan 08, 2005 11:11 pm

Re: FCKEditor image upload

Post by megabob3 »

jah wrote:It is great that you are working with FCKEditor and I tried your online installation.

It seems to work, but I'm not able to upload and insert images. Neither can I create folders in the upload menu. I tried to upload an image but it did not show up. Maybe it was uploaded to another folder?
Yep i findid a solution for quotes, but now appears this one :P

I am doing new chenges :D
megabob3
Power Poster
Power Poster
Posts: 498
Joined: Sat Jan 08, 2005 11:11 pm

FCKeditor

Post by megabob3 »

Ok :D


I started all from the beginning
resolved quotes inside this files:
FCKeditor/editor/js/fckeditorcode***.js

comment inside line 22
/*'"':'quot',*/

Resolved also uploading imgae

try it directly from
www.awakening.it/test

user: admin
pass: admin

and download it from
http://www.awakening.it/uploads/FCKeditor.zip


who can pls test installing it on your project, and if find problem on uploading images, pls post the file "log.txt" from this folder
"modules\FCKeditor\editor\filemanager\browser\default\connectors\php"

Bye :)
Greg
Power Poster
Power Poster
Posts: 598
Joined: Sun Sep 26, 2004 6:15 pm

FCKeditor

Post by Greg »

Tried this version megabob3 ....
When I click 'browse server' the popoup window comes up empty.
I click browse to upload a file -- takes about 2 miniutes before the next window pops up -- I click upload -- it says upload in progress --- hangs there.

Log.txt shows the following:
GetRootPath():d:/aaawebsites
root_path | d:/aaawebsites/websites/gregbloorcms
uploads_path | d:/aaawebsites/websites/gregbloorcms/uploads
ultima | aaawebsites
Greg
megabob3
Power Poster
Power Poster
Posts: 498
Joined: Sat Jan 08, 2005 11:11 pm

FCKeditor

Post by megabob3 »

Greg wrote:Tried this version megabob3 ....
When I click 'browse server' the popoup window comes up empty.
I click browse to upload a file -- takes about 2 miniutes before the next window pops up -- I click upload -- it says upload in progress --- hangs there.

Log.txt shows the following:
GetRootPath():d:/aaawebsites
root_path | d:/aaawebsites/websites/gregbloorcms
uploads_path | d:/aaawebsites/websites/gregbloorcms/uploads
ultima | aaawebsites
Really strange, probably connector created a BIIIIIG LOOOP, but i don't view rigth the reason, what kind of Operating System and Apache version have you?. The LOG must be like this:

GetRootPath():d:/programmi/appserv/www
uploads_path | d:/programmi/appserv/www/test/uploads
root_path | d:/programmi/appserv/www/test
ultima | www
Pos 24
uploads_path[pos] /
UserFilesPath | /test/uploads/
UserFilesDirectory | d:/programmi/appserv/www/test/uploads/

however here a new connector, that must not create the LOOP
//////////////////////////////
log("GetRootPath():".$STR);

$config["uploads_path"] = str_replace( '\\', '/', $config["uploads_path"] );
$Log->log("uploads_path | ".$config["uploads_path"]);


$pos = strrpos($STR, "/");
$ult = substr($STR, $pos+1, strlen($STR)-$pos);
$Log->log("ultima | ".$ult);

$pos = strrpos($config["uploads_path"], $ult);

while (($config["uploads_path"][$pos] != "/")&&($pos log("Pos ".$pos);
$Log->log("uploads_path[pos] ".$config["uploads_path"][$pos]);


$usrfp = substr($config["uploads_path"], $pos)."/";

$GLOBALS["UserFilesPath"] = $usrfp ;

$GLOBALS["UserFilesDirectory"] = str_replace( '\\', '/', GetRootPath() ) . str_replace( '\\', '/', $GLOBALS["UserFilesPath"] ) ;
$Log->log("UserFilesPath | ".$GLOBALS["UserFilesPath"]);
$Log->log("UserFilesDirectory | ".$GLOBALS["UserFilesDirectory"]);
$Log->close();

}

// Map the "UserFiles" path to a local directory.
$GLOBALS["UserFilesDirectory"] = str_replace( '\\', '/', GetRootPath() ).str_replace( '\\', '/', $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 the current folder syntax (must begin and start with a slash).
if ( ! ereg( '/$', $sCurrentFolder ) ) $sCurrentFolder .= '/' ;
if ( strpos( $sCurrentFolder, '/' ) !== 0 ) $sCurrentFolder = '/' . $sCurrentFolder ;

// File Upload doesn't have to Return XML, so it must be intercepted before anything.
if ( $sCommand == 'FileUpload' )
{
FileUpload( $sResourceType, $sCurrentFolder ) ;
return ;
}

// 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' ) ;

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 ;
}
?>
////////////////////////////

I changed LOG files, it must be like this now:

GetRootPath():d:/programmi/appserv/www
uploads_path | d:/programmi/appserv/www/test/uploads
ultima | www
Pos 24
uploads_path[pos] /
UserFilesPath | /test/uploads/
UserFilesDirectory | d:/programmi/appserv/www/test/uploads/


Pls try it :D and thx
Greg
Power Poster
Power Poster
Posts: 598
Joined: Sun Sep 26, 2004 6:15 pm

FCKeditor

Post by Greg »

Still not showing any files. No idea where they are going. If I upload the same file it says it already exists.
Latest log
GetRootPath():d:/aaawebsites
uploads_path | d:/aaawebsites/websites/gregbloorcms/uploads
ultima | aaawebsites
Pos 44
uploads_path[pos]
UserFilesPath | /
UserFilesDirectory | d:/aaawebsites/
Greg
megabob3
Power Poster
Power Poster
Posts: 498
Joined: Sat Jan 08, 2005 11:11 pm

FCKeditor

Post by megabob3 »

Greg wrote:Still not showing any files. No idea where they are going. If I upload the same file it says it already exists.
Latest log
GetRootPath():d:/aaawebsites
uploads_path | d:/aaawebsites/websites/gregbloorcms/uploads
ultima | aaawebsites
Pos 44
uploads_path[pos]
UserFilesPath | /
UserFilesDirectory | d:/aaawebsites/
Yeah thx, now i must understand because "Pos" isn't around 13 or 14 (i did not count the right, but 44 must not be).

Pls say me, Apache version and operating system (i guess Windows).

However next time isn't necessary try an UPLOAD or MAKE a DIRECTORY, it's enough open 'browse server' and the LOG file is created :D

If all it's OK inside 'browse server' popup you must see the file of "uploads_path".

Bye and thx

I have :roll: :roll: :roll:
Greg
Power Poster
Power Poster
Posts: 598
Joined: Sun Sep 26, 2004 6:15 pm

FCKeditor

Post by Greg »

I am using Apache 1.3.33 Windows XP with SP2 MySQL 4.0.20 and PHP 4.3.10
Greg
megabob3
Power Poster
Power Poster
Posts: 498
Joined: Sat Jan 08, 2005 11:11 pm

FCKeditor

Post by megabob3 »

Greg wrote:I am using Apache 1.3.33 Windows XP with SP2 MySQL 4.0.20 and PHP 4.3.10
:roll: :roll: :roll: :roll: :roll:

I must understand why the control skip "/".

Probably, i will write a new connector, for create a new LOG, for understand better, see you next time ;)


Bye and thx Greg :).
megabob3
Power Poster
Power Poster
Posts: 498
Joined: Sat Jan 08, 2005 11:11 pm

FCKeditor

Post by megabob3 »

Hi Greg pls try this connector.php

/////////////////////////////////
log("GetRootPath():".$STR);

$config["uploads_path"] = trim(str_replace( '\\', '/', $config["uploads_path"] ));
$Log->log("uploads_path | ".$config["uploads_path"]);


$pos = strrpos($STR, "/");
$ult = trim(substr($STR, $pos+1, strlen($STR)-$pos));
$Log->log("ultima | ".$ult);

$pos = strrpos($config["uploads_path"], $ult);
$Log->log("Pos | prima | ".$pos);
$Log->log("+++++++++++++++++++++++++++");

while (($config["uploads_path"][$pos] != "/")&&($pos log("Pos | dentro | ".$pos." --- config[uploads_path][pos] |".$config["uploads_path"][$pos]);
$pos++;
}
$Log->log("+++++++++++++++++++++++++++");
$Log->log("Pos | dopo | ".$pos." --- config[uploads_path][pos] |".$config["uploads_path"][$pos]);
$Log->log("uploads_path[pos] ".$config["uploads_path"][$pos]);


$usrfp = trim(substr($config["uploads_path"], $pos)."/");

$GLOBALS["UserFilesPath"] = $usrfp ;

$GLOBALS["UserFilesDirectory"] = trim(str_replace( '\\', '/', GetRootPath() ) . str_replace( '\\', '/', $GLOBALS["UserFilesPath"] )) ;
$Log->log("UserFilesPath | ".$GLOBALS["UserFilesPath"]);
$Log->log("UserFilesDirectory | ".$GLOBALS["UserFilesDirectory"]);
$Log->close();

}

// Map the "UserFiles" path to a local directory.
$GLOBALS["UserFilesDirectory"] = trim(str_replace( '\\', '/', GetRootPath() ).str_replace( '\\', '/', $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 the current folder syntax (must begin and start with a slash).
if ( ! ereg( '/$', $sCurrentFolder ) ) $sCurrentFolder .= '/' ;
if ( strpos( $sCurrentFolder, '/' ) !== 0 ) $sCurrentFolder = '/' . $sCurrentFolder ;

// File Upload doesn't have to Return XML, so it must be intercepted before anything.
if ( $sCommand == 'FileUpload' )
{
FileUpload( $sResourceType, $sCurrentFolder ) ;
return ;
}

// 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' ) ;

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 ;
}
?>
///////////////////////////////////


The LOG files must be like this:

GetRootPath():d:/programmi/appserv/www
uploads_path | d:/programmi/appserv/www/test/uploads
ultima | www
Pos | prima | 21
+++++++++++++++++++++++++++
Pos | dentro | 21 --- config[uploads_path][pos] |w
Pos | dentro | 22 --- config[uploads_path][pos] |w
Pos | dentro | 23 --- config[uploads_path][pos] |w
+++++++++++++++++++++++++++
Pos | dopo | 24 --- config[uploads_path][pos] |/
uploads_path[pos] /
UserFilesPath | /test/uploads/
UserFilesDirectory | d:/programmi/appserv/www/test/uploads/


Isn't necessary make an UPLOAD or create a DIR, open only the popup of server browser.

Bye and thx :)
Last edited by megabob3 on Fri Jan 21, 2005 4:23 pm, edited 1 time in total.
megabob3
Power Poster
Power Poster
Posts: 498
Joined: Sat Jan 08, 2005 11:11 pm

FCKeditor

Post by megabob3 »

On your machine probably connector.php had create this folder
"d:/aaawebsites/images"

Bye :)
Greg
Power Poster
Power Poster
Posts: 598
Joined: Sun Sep 26, 2004 6:15 pm

FCKeditor

Post by Greg »

Still nothing listed in the right frame, even created subdirectories don't show:
Logfile
GetRootPath():d:/aaawebsites
uploads_path | d:/aaawebsites/websites/gregbloorcms/uploads
ultima | aaawebsites
Pos | prima | 41
+++++++++++++++++++++++++++
Pos | dentro | 41 --- config[uploads_path][pos] |a
Pos | dentro | 42 --- config[uploads_path][pos] |d
Pos | dentro | 43 --- config[uploads_path][pos] |s
+++++++++++++++++++++++++++
Pos | dopo | 44 --- config[uploads_path][pos] |
uploads_path[pos]
UserFilesPath | /
UserFilesDirectory | d:/aaawebsites/
The plugin is creating d:/aaawebsites/Image
Greg
megabob3
Power Poster
Power Poster
Posts: 498
Joined: Sat Jan 08, 2005 11:11 pm

FCKeditor

Post by megabob3 »

Greg wrote:Still nothing listed in the right frame, even created subdirectories don't show:
Logfile
GetRootPath():d:/aaawebsites
uploads_path | d:/aaawebsites/websites/gregbloorcms/uploads
ultima | aaawebsites
Pos | prima | 41
+++++++++++++++++++++++++++
Pos | dentro | 41 --- config[uploads_path][pos] |a
Pos | dentro | 42 --- config[uploads_path][pos] |d
Pos | dentro | 43 --- config[uploads_path][pos] |s
+++++++++++++++++++++++++++
Pos | dopo | 44 --- config[uploads_path][pos] |
uploads_path[pos]
UserFilesPath | /
UserFilesDirectory | d:/aaawebsites/
The plugin is creating d:/aaawebsites/Image
41??!!!! incredible :shock:

Thx Greg i have something for work on it :)

"d:/aaawebsites/Image"???, next i will post also another javascript files to overwirte on your singapore directory ;)
Post Reply

Return to “Modules/Add-Ons”