Salve a tutti ho creato questo codice che mi crea un'immagine dato un codice. Il problema è che se lo eseguo su apache mi da i seguenti errori(però mi da il risultato):codice:<?php $Stringa = "A1289"; $lenght = strlen($Stringa); $photoFrame = imagecreatetruecolor(380,285); $bg = imagecolorallocate ( $photoFrame, 255, 255, 255 ); imagefill ( $photoFrame , 0, 0, $bg ); //$immagine = imagecreatetruecolor($larghezza, $altezza); //$sfondo = imagecolorallocatealpha($photoFrame, 0xFF, 0, 0, 0); $bianco = imagecolorallocatealpha($photoFrame, 0xFF, 0xFF, 0xFF, 0); $immaginefinale = "immaginecompleta.png"; //immagine finale che verra creata $lettere = array("A","B","C","D","E","F","G","H","I","J","0","1","2","3","4","5","6","7","8","9"); $lunghezzaarray = (sizeof($lettere)); $fotogrammaW = 65; //base fotogramma $fotogrammaH = 80; //altezza fotogramma for ($mul = 0; $mul <= $lenght; ++$mul) { for ($con = 0; $con <= $lunghezzaarray; ++$con) { if(isset($Stringa{$mul}) == $lettere[$con]){ $carica[$mul] = imagecreatefrompng($lettere[$con].'.png'); } } } //imagecopy($photoFrame, (imagecreatefrompng('testa.png')), 0, 0, 0, 0, 284, 21); imagecopy($photoFrame, $carica[0], 0, 50, 0, 0, $fotogrammaW, $fotogrammaH); //copia la prima immagine imagecopy($photoFrame, $carica[1], 76, 50, 0, 0, $fotogrammaW, $fotogrammaH); //copia la seconda immagine spostata di 150 imagecopy($photoFrame, $carica[2], 152, 50, 0, 0, $fotogrammaW, $fotogrammaH); //copia la terza immagine spostata di 300 imagecopy($photoFrame, $carica[3], 228, 50, 0, 0, $fotogrammaW, $fotogrammaH); //copia la quarta immagine spostata di 450 imagecopy($photoFrame, $carica[4], 304, 50, 0, 0, $fotogrammaW, $fotogrammaH); //copia la quinta immagine spostata di 600 imagepng($photoFrame, $immaginefinale); //crea l'immagine finale echo '[img]'.$immaginefinale.'[/img]'; ?>
Notice: Undefined offset: 20 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Undefined offset: 20 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Undefined offset: 20 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Undefined offset: 20 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Undefined offset: 20 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Uninitialized string offset: 5 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Undefined offset: 20 in C:\APACHE\CreateLable\createImg.php on line 26
Notice: Undefined offset: 20 in C:\APACHE\CreateLable\createImg.php on line 28
Warning: imagecreatefrompng(.png) [function.imagecreatefrompng]: failed to open stream: No such file or directory in C:\APACHE\CreateLable\createImg.php on line 28
Mentre se lo eseguo su MAMP SU MAC non mi da nessun errore
Grazie della disponibilità