Pls Greg after test also this other connector
and post the two LOG files.
/////////////////
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);
if (function_exists('strripos')) {
$pos = strripos($config["uploads_path"], $ult);
$Log->log("strripos THEN");
} else {
$posi = 0;
$tok = strtok($config["uploads_path"], '/');
while ($tok) {
$Log->log($tok);
if (strcmp($tok,$ult)==0)
$pos = $posi+strlen($tok)-1;
else
$posi += strlen($tok)+1;
$tok = strtok("/");
}
$Log->log("strripos ELSE");
}
$Log->log("Pos | TOKTOK | ".$pos." --- config[uploads_path][pos] |".$config["uploads_path"][$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 ;
}
?>
///////////////////
Bye and infinite thx
