Ver Mensaje Individual
  #3 (permalink)  
Antiguo 11/03/2010, 14:10
Yrnving
 
Fecha de Ingreso: febrero-2006
Mensajes: 148
Antigüedad: 18 años, 2 meses
Puntos: 0
Respuesta: Imagenes problema en arrastrarlas fuera del navegador o copiarlas.

OK explico mejor, tengo un codigo donde se crea una imagen:

Código PHP:
function positionTXT($size,$txt,$width,$height,$x,$y,$img,$title){
    global 
$marginTOP;
    
$txt_dimensions imagettfbbox($size,0,"ariblk.ttf",$txt);
    
$txt_length $txt_dimensions[2] + $txt_dimensions[0];
    while(
$txt_length>=333){
       
$size--;
       
$txt_dimensions imagettfbbox($size,0,"ariblk.ttf",$txt);
       
$txt_length $txt_dimensions[2] + $txt_dimensions[0];
    }
    
$txt_height abs($txt_dimensions[7] - $txt_dimensions[1]);
    
$txt_x = ($width-$txt_length)/2;  // centrarlo en x
    
$title_y = ($txt_height/2)+($size/2); 
    
$imagen imagecreate($width,$txt_height);
    
$title==1$maximo=($txt_height+10):$maximo=$txt_height;
    
imagecolorallocate($imagen,35,31,32);
    
$white=ImageColorAllocate($imagen,255,255,255);
    
imagefttext($imagen,$size,0,$txt_x,$title_y,$white,"ariblk.ttf" ,$txt);
    
imagecopyresized($img,$imagen,0,$y,0,0,$width,$maximo,$width,$txt_height);
    
$marginTOP+=$maximo+3;
}
$img_back=imagecreatefrompng("imagen.png");
if(
$txt==1){
   
positionTXT(14,strtoupper($linea[$i]),333,40,0,$marginTOP+8,$img_back,0);
}
header("Content-type: image/png");
imagepng($img_back);
imagedestroy($imagen); 
la imagen se muestra en una ventana donde tengo un formulario y un iframe, cuando el usuario presiona en "ver foto" sale la foto y se puede arrastrar fuera del navegador perfectamente igualmente se puede copiar y pegar.

pero cuando el usuario le agrega un texto, no se puede arrastrar ni tampoco copiar.