Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> Gdzie jest bład?
wozniak
post
Post #1





Grupa: Zarejestrowani
Postów: 278
Pomógł: 0
Dołączył: 21.11.2003

Ostrzeżenie: (0%)
-----


Gdzie jest bład?
  1. <?
  2.  
  3. echo"<form method=\"post\" enctype=\"multipart/form-data\" action=\"11.php?a=1\">";
  4. ?>
  5. <p><input type="file" name="file" size="20"><input type="submit" value="Prześlij" name="B1"><input type="reset" value="Resetuj" name="B2"></p>
  6. </form>
  7.  
  8.  
  9. <?php
  10.  
  11. if(isset($a)){
  12.  
  13. print(" to: $aaa");
  14. $file = '$aaa';
  15.  
  16. $size = getimagesize( $file );
  17.  
  18. $src = imagecreatefromjpeg( $file );
  19. $dst = imagecreatetruecolor( 100, 150 );
  20.  
  21. imagecopyresized( $dst, $src, 0, 0, 0, 0, 100, 150, $size[ 0 ], $size[ 1 ] );
  22.  
  23. imagejpeg( $dst, './small_' . basename( $file ) );
  24.  
  25. imagedestroy( $src );
  26. imagedestroy( $dst );
  27. }
  28.  
  29. ?>


Pokazuje:
Cytat
to: C:/Serwer/temp/file-uploads\php143.tmp
Warning: getimagesize($aaa) [function.getimagesize]: failed to open stream: No such file or directory in C:\Serwer\httpd-users\1\11.php on line 16

Warning: imagecreatefromjpeg($aaa) [function.imagecreatefromjpeg]: failed to open stream: No such file or directory in C:\Serwer\httpd-users\1\11.php on line 18

Warning: imagecopyresized(): supplied argument is not a valid Image resource in C:\Serwer\httpd-users\1\11.php on line 21

Warning: imagedestroy(): supplied argument is not a valid Image resource in C:\Serwer\httpd-users\1\11.php on line 25
Go to the top of the page
+Quote Post

Posty w temacie


Reply to this topicStart new topic
1 Użytkowników czyta ten temat (1 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 21.08.2025 - 01:44