Problems with Upload with DFP 2
I'm having problems with Digital File Pro 2, and that while the local mode Tood works well when trying to upload images to the remote hosting, pictures do not rise, the process is correct, but there is something that prevents the photos to upload your file and not displayed. In addition, the bar does not work as they get the error in the file that I send you herewith. Please indicate that it may be because the folders have write permissions and everything seems in order. Attached a file with the error and also the configuration of php on my remote server.
The code in the pages is the following:
<?php require_once('../../Connections/comite.php'); ?>
<?php require_once("../../WA_DigitalFilePro/HelperPHP.php"); ?>
<?php require_once( "../../WA_SecurityAssist/Helper_PHP.php" ); ?>
<?php
if (!WA_Auth_RulePasses("Logged in to administradores")){
WA_Auth_RestrictAccess("../../index.php");
}
?>
<?php
if (!function_exists("GetSQLValueString")) {
function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
{
if (PHP_VERSION < 6) {
$theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;
}
$theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);
switch ($theType) {
case "text":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "long":
case "int":
$theValue = ($theValue != "") ? intval($theValue) : "NULL";
break;
case "double":
$theValue = ($theValue != "") ? doubleval($theValue) : "NULL";
break;
case "date":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "defined":
$theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
break;
}
return $theValue;
}
}
$editFormAction = $_SERVER['PHP_SELF'];
if (isset($_SERVER['QUERY_STRING'])) {
$editFormAction .= "?" . htmlentities($_SERVER['QUERY_STRING']);
}
if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "form1")) {
$insertSQL = sprintf("INSERT INTO gritoimagenes (imagen_url) VALUES (%s)",
GetSQLValueString($_POST['imagen_url'], "text"));
mysql_select_db($database_comite, $comite);
$Result1 = mysql_query($insertSQL, $comite) or die(mysql_error());
$insertGoTo = "../../grito_en_imagenes.php";
if (isset($_SERVER['QUERY_STRING'])) {
$insertGoTo .= (strpos($insertGoTo, '?')) ? "&" : "?";
$insertGoTo .= $_SERVER['QUERY_STRING'];
}
header(sprintf("Location: %s", $insertGoTo));
}
mysql_select_db($database_comite, $comite);
$query_gritoimagenes = "SELECT * FROM gritoimagenes";
$gritoimagenes = mysql_query($query_gritoimagenes, $comite) or die(mysql_error());
$row_gritoimagenes = mysql_fetch_assoc($gritoimagenes);
$totalRows_gritoimagenes = mysql_num_rows($gritoimagenes);?>
<?php
// WA_UploadResult1 Params Start
$WA_UploadResult1_Params = array();
// WA_UploadResult1_1 Start
$WA_UploadResult1_Params["WA_UploadResult1_1"] = array(
'UploadFolder' => "../../images/grito/lg/",
'FileName' => "[FileName]",
'DefaultFileName' => "",
'ResizeType' => "0",
'ResizeWidth' => "120",
'ResizeHeight' => "120",
'ResizeFillColor' => "#FFFFFF" );
// WA_UploadResult1_1 End
// WA_UploadResult1_2 Start
$WA_UploadResult1_Params["WA_UploadResult1_2"] = array(
'UploadFolder' => "../../images/grito/tn/",
'FileName' => "[FileName]",
'DefaultFileName' => "",
'ResizeType' => "4",
'ResizeWidth' => "85",
'ResizeHeight' => "140",
'ResizeFillColor' => "#FFFFFF" );
// WA_UploadResult1_2 End
// WA_UploadResult1 Params End
?>
<?php
WA_DFP_SetupUploadStatusStruct("WA_UploadResult1");
if($_SERVER["REQUEST_METHOD"] == "POST"){
WA_DFP_UploadFiles("WA_UploadResult1", "uploadgrito", "0", "", "JPG:80", $WA_UploadResult1_Params);
}
?>