Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> problem z ImageCreate(chyba)
gkeb
post
Post #1





Grupa: Zarejestrowani
Postów: 46
Pomógł: 0
Dołączył: 6.03.2004

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


mam taki kodzik w osobnym pliku (show.php):
[php:1:195ad7ee5f]<?php

header("Content-type: image/jpeg");
$im = ImageCreateFromJpeg("jakis_jpeg.jpg");
ImageJpeg($im,'',90);
ImageDestroy($im);

?>[/php:1:195ad7ee5f]

w jakims tam pliku html wpisuje
Kod
<IMG SRC="show.php">


teoretycznie w tym momencie powinien pokazac mi sie obrazek a sie nie pokazuje.probowalem z gifami i tez nie dziala
w phpinfo w sekcji gd wypisuje mi:
GD Support enabled
GD Version bundled (2.0.15 compatible)
FreeType Support enabled
FreeType Linkage with freetype
FreeType Version 2.1.5
GIF Read Support enabled
JPG Support enabled
PNG Support enabled
WBMP Support enabled
XBM Support enabled

co robie nie tak??
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi (1 - 9)
talee
post
Post #2





Grupa: Zarejestrowani
Postów: 105
Pomógł: 0
Dołączył: 7.09.2002
Skąd: Bydgoszcz

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


[manual:342b9476e0]imagejpeg[/manual:342b9476e0]

musisz to posłać do przeglądarki
Go to the top of the page
+Quote Post
gkeb
post
Post #3





Grupa: Zarejestrowani
Postów: 46
Pomógł: 0
Dołączył: 6.03.2004

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


tzn?? jak wyslac do przegladarki??
przeciez ImageJpeg wlasnie wystawia to co mu podam przez ImageCreate
tak mi sie wydaje (IMG:http://forum.php.pl/style_emoticons/default/rolleyes.gif)
Go to the top of the page
+Quote Post
talee
post
Post #4





Grupa: Zarejestrowani
Postów: 105
Pomógł: 0
Dołączył: 7.09.2002
Skąd: Bydgoszcz

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


fatal error, (IMG:http://forum.php.pl/style_emoticons/default/smile.gif) jest OK, to przez wczorajsze balety, myślę jak coś wymyśle to dam news
Go to the top of the page
+Quote Post
gkeb
post
Post #5





Grupa: Zarejestrowani
Postów: 46
Pomógł: 0
Dołączył: 6.03.2004

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


THX (IMG:http://forum.php.pl/style_emoticons/default/biggrin.gif)
ja sam tez postaram sie ta zagadke rozwiazac (czeka mnie dluuuuga noc (IMG:http://forum.php.pl/style_emoticons/default/smile.gif) (IMG:http://forum.php.pl/style_emoticons/default/aaevil.gif) (IMG:http://forum.php.pl/style_emoticons/default/smile.gif) (IMG:http://forum.php.pl/style_emoticons/default/aaevil.gif) )
Go to the top of the page
+Quote Post
talee
post
Post #6





Grupa: Zarejestrowani
Postów: 105
Pomógł: 0
Dołączył: 7.09.2002
Skąd: Bydgoszcz

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


to musi działać, ten sma kod ta sama konfiguracja GD pytanie co wyświetla ci sam show.php
Go to the top of the page
+Quote Post
Blaster
post
Post #7





Grupa: Zarejestrowani
Postów: 28
Pomógł: 0
Dołączył: 2.03.2004

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


Look this (IMG:http://forum.php.pl/style_emoticons/default/smile.gif)
<?php
$plik = 'Zima.jpg';
header('Content-type: image/jpeg');
header('Content-transfer-encoding: binary');
header('Content-length: '.filesize($plik));
readfile($plik);
?>
Go to the top of the page
+Quote Post
gkeb
post
Post #8





Grupa: Zarejestrowani
Postów: 46
Pomógł: 0
Dołączył: 6.03.2004

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


THX Blaster (IMG:http://forum.php.pl/style_emoticons/default/biggrin.gif)
Twoje rozwiazanie zadzialalo (IMG:http://forum.php.pl/style_emoticons/default/biggrin.gif) (IMG:http://forum.php.pl/style_emoticons/default/biggrin.gif)
ale nadal nie rozumiem gdzie w moim tkwi blad, jest oparte na manualu i nie dziala (IMG:http://forum.php.pl/style_emoticons/default/sad.gif)
Go to the top of the page
+Quote Post
Blaster
post
Post #9





Grupa: Zarejestrowani
Postów: 28
Pomógł: 0
Dołączył: 2.03.2004

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


HMmmz, u mnie to dziala :-) . Moze obrazek miales zly, lub sciezke zle podana ?
Go to the top of the page
+Quote Post
gkeb
post
Post #10





Grupa: Zarejestrowani
Postów: 46
Pomógł: 0
Dołączył: 6.03.2004

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


nie mam bladego pojecia. wiem ze powinno dzialac, plik grafiki jest w tym samym katalogu co skrypt php i strona html wiec nie powinno byc zadnego problemu (IMG:http://forum.php.pl/style_emoticons/default/sad.gif)
za to to drugie rozwiazanie Blaster jakie dales to dziala od razu (IMG:http://forum.php.pl/style_emoticons/default/smile.gif)
Go to the top of the page
+Quote Post

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

 



RSS Aktualny czas: 23.12.2025 - 21:11