Foros del Web » Programando para Internet » PHP »

problema no se ve la imagen

Estas en el tema de problema no se ve la imagen en el foro de PHP en Foros del Web. no se ve la imagen cuando le doy al cargar la imagen, me pone que imagen subida pero no se encuentra en mi ftp ni ...
  #1 (permalink)  
Antiguo 09/10/2007, 17:12
 
Fecha de Ingreso: octubre-2007
Mensajes: 41
Antigüedad: 16 años, 6 meses
Puntos: 0
problema no se ve la imagen

no se ve la imagen cuando le doy al cargar la imagen, me pone que imagen subida pero no se encuentra en mi ftp ni se visualiza, aqui dejo el codigo a ver si alguien puede ayudarme, gracias

function DeliverSendEvent($option)
{
//Eingabe speichern
global $database, $mainframe, $mosConfig_sitename, $my, $acl, $Itemid, $mosConfig_mailfrom, $mosConfig_fromname;
require(ELPATH."/../../administrator/components/com_eventlist/config.eventlist.php");
require_once( $mainframe->getPath( 'class' ) );

$is_chef = (strtolower($my->usertype) == 'editor' || strtolower($my->usertype) == 'publisher' || strtolower($my->usertype) == 'manager' || strtolower($my->usertype) == 'administrator' || strtolower($my->usertype) == 'super administrator' );
$row = new eventlist_dates($database);

$_POST['titel'] = mosGetParam($_POST, 'titel');

//Bild
$userfile2=(isset($_FILES['userfile']['tmp_name']) ? $_FILES['userfile']['tmp_name'] : "");
$userfile_name = date("YmdGis").$_FILES['userfile']['name'];
$imagesize = $_FILES['userfile']['size'];

if (( $imageenabled == 2 ) || ( ($imageenabled == 1) && (!empty($userfile_name)) ) ) {
$base_Dir = ELPATH.'/../../images/eventlist/events/';
$sizelimit = $sizelimit*1024; //size limit in kb

if (empty($userfile_name)) {
mosRedirect("index.php?option=$option&Itemid=$Item id", _EVENTS_IMAGEEMPT." ");
}

if ($imagesize > $sizelimit) {
mosRedirect("index.php?option=$option&Itemid=$Item id", _EVENTS_IMAGESIZEBIG." ");
}

$filename = split("\.", $userfile_name);

if (eregi("[^0-9a-zA-Z_]", $filename[0])) {
mosRedirect("index.php?option=$option&Itemid=$Item id", _EVENTS_IMAGECHARACT." ");
}

if (file_exists($base_Dir.$userfile_name)) {
mosRedirect("index.php?option=$option&Itemid=$Item id", _EVENTS_IMAGEEXIST." ");
}

if ((strcasecmp(substr($userfile_name,-4),".gif")) && (strcasecmp(substr($userfile_name,-4),".jpg")) && (strcasecmp(substr($userfile_name,-4),".png")) && (strcasecmp(substr($userfile_name,-4),".bmp"))) {
mosRedirect("index.php?option=$option&Itemid=$Item id", _EVENTS_IMAGETYPE." ");
}

if (!move_uploaded_file ($_FILES['userfile']['tmp_name'],$base_Dir.$_FILES['userfile']['name']) || !mosChmod($base_Dir.$_FILES['userfile']['name'])) {
mosRedirect("index.php?option=$option&Itemid=$Item id", _EVENTS_IMAGEFAIL." ");
} else {
$file = $base_Dir.$userfile_name;
//chmod Bild
@chmod ($file, octdec($imagechmod));
//Vorbereiten auf Thumbnailerstellung
$thumbdir = $base_Dir.'small/';
$save = $thumbdir.$userfile_name ;
if ($imageprob = 1) {
$imageprob = TRUE;
} else {
$imageprob = FALSE;
}
if ($gddisabled == 1) {
evlist_imgd::thumb($file, $save, $imagewidth, $imagehight, $imageprob);
}
}
$_POST['datimage'] = $userfile_name ;
}
  #2 (permalink)  
Antiguo 09/10/2007, 17:17
Avatar de kaninox  
Fecha de Ingreso: septiembre-2005
Ubicación: In my House
Mensajes: 3.597
Antigüedad: 18 años, 7 meses
Puntos: 49
Re: problema no se ve la imagen

pos si no se ve con tu codigo no solucionamos nada, debe solo ser problema de directorios, usas algun ajax o include, mira que trabajan distintos a la hora de llamar cosas :º, puedes tener un archivo en el cual la carpeta esta dentro, imagenes/ pero si lo estas llamando de un div de otra pagina externa debes poner la ruta completa carpeta/imagenes/
bueno....igual le hechare una miradilla a tu codigo :P
pero trataste imprimiendo solo el nombre ???? de la variable
__________________
Gokuh Salvo al mundo. PUNTO!!!!
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 13:32.