Cita: aja... muy bonito todo... pero.... y el código? como pretendes recibir ayuda si no muestras nada
Se que tienes razón, deje la pregunta abierta para saber si a alguien le abria ocurrido la misma situación porque no estoy seguro si el problema es de código o del servidor o incluso del navegador. Las pocas respuestas que encontre sobre el error le echaban la culpa al navegador y además no genera ninguna advertencia dentro del código de php.
Para entrar más en detalle existen dos códigos, uno es el config.php y es le que dice en que carpeta es donde se colocaran las imagenes a subir y otro es el que gestiona la subida (image.php) y es supremamente largo y ese uno no lo modifica . Dejare ambos por si acaso.
config.php
Código PHP:
$_cur_dir = $_SERVER['DOCUMENT_ROOT']."/administrator/";
// The default language for errors is english to change to another type add lang to the lang folder e.g. fr_FR (french) to get language packs please download the class zip from the above authors link
$language = 'en_EN';
// server file directory to store images - IMPORTANT CHANGE PATH TO SUIT YOUR NEEDS!!!
//$server_image_directory = $_cur_dir.'/uploads/images'; //e.g. '/home/user/public_html/uploads';
$server_image_directory = $_cur_dir.'images'; //e.g. '/home/user/public_html/uploads';
// URL directory to stored images (relative or absoulte) - IMPORTANT CHANGE PATH TO SUIT YOUR NEEDS!!!
//$url_image_directory = '/uploads/images';
$url_image_directory = 'images';
// file_safe_name formats the filename (spaces changed to _) (default: true)
$handle->file_safe_name = true;
# file_auto_rename automatically renames file if it already exists (default: true)
$handle->file_auto_rename = true;
// image_resize determines is an image will be resized (default: false)
$handle->image_resize = true;
// image_ratio if true, resize image conserving the original sizes ratio, using image_x AND image_y as max sizes if true (default: false)
$handle->image_ratio = true;
// image_ratio_x if true, resize image, calculating image_x from image_y and conserving the original sizes ratio (default: false)
$handle->image_y = 400;
// image_ratio_y if true, resize image, calculating image_y from image_x and conserving the original sizes ratio (default: false)
$handle->image_x = 400;
// file_safe_name formats the filename (spaces changed to _) (default: true)
$handle->file_safe_name = true;
Y este es el código que gestiona la subida y cuando trata de acceder genera el error. Solo dejare el fragmento concerniente a la subida de archivos porque por longitud no me deja colocarlo todo
Código PHP:
<?php
include('./classes/class.upload.php');
if (isset($_POST['action']) && $_POST['action'] == 'image')
{
include('./config.php');
$handle = new upload($_FILES['image_field'], $language);
include('./config.php');
$handle->Process($server_image_directory);
if ($handle->uploaded)
{
if ($handle->processed)
{
echo "<script>setTimeout(\"document.getElementById('src').value='".$url_image_directory."/".$handle->file_dst_name."'\", 200)</script>";
echo "<script>setTimeout(\"ImageDialog.showPreviewImage(document.getElementById('src').value)\", 400)</script>";
}
else
{
$error_str = str_replace("'", "`", $handle->error);
echo "<script>alert('$error_str')</script>";
}
$handle->Clean();
}
else
{
$error_str = str_replace("'", "`", $handle->error);
echo "<script>alert('$error_str')</script>";
}
}
?>
</body>
</html>
Como pueden observar al final utiliza una clase llamada class.upload.php para subir la imagen la cual no coloco aca por su excesivo tamaño (mas de 4600 lineas). Igual si consideran que vale la pena buscar algún fragmento de código del mismo para mirar el problema comentenmelo.