PHP + PNG

Giorgos Pallas gpall at auth.gr
Sun Oct 21 13:32:01 EEST 2001


Geia se olous!
Mathainw php teleutaia, kai exw to eksis provlima :

exw se ena katalogo tou web server to arxeio test.html :
<html>
<body>
<img SRC=xartis.php3>
</body>
</html>

Sto xartis.php3 thelw na fortwnw mia png eikona, na kanw kati
ypologismous, kai basei autwn na sxediazw grammes stin eikona. Ela omws
pou an to xartis.php3 arxizei etsi :
<?php

$png = ImageCreateFromPNG("trafficmap.png");
header("content-type: image/png");
ImagePng($png);
ImageDestroy($png);

blah blah, ypologismoi (xwris omws tis entoles gia tis grammes)

?>

otan kalw to test.html, kanonikotata emfanizetai i eikona png.
Omws auto den ginetai na meinei etsi giati aploustata, prwta prepei na
kanw tous ypologismous kai meta na emfanizw tin png. Omws an balw tis
grammes
$png = ImageCreateFromPNG("trafficmap.png");
header("content-type: image/png");
ImagePng($png);
ImageDestroy($png);

sto telos tou php kwdika, den paizei (bgazei sto browser to eikonidio me
to X -> den brethike i eikona.

Exei kaneis kamia idea giati ginetai auto;

euxaristw
Pallas Giwrgos

[0]. to kanonikotata einai sxetiko, an dei exei kaneis oreksi na dei
auta ta dyo link :
http://noc.auth.gr/network/monitor/gr_map/XARTHS/trafficmap.png [i
kanoniki eikona]
http://noc.auth.gr/network/monitor/gr_map/XARTHS/test.html [ ...kai
deste pws emfanizete apo tin php...san na ebgale ilara...]



More information about the Linux-greek-users mailing list