Please Read

 
Post new topic   Reply to topic    Aprelium Forum Index -> PHP
View previous topic :: View next topic  
Author Message
Trix
-


Joined: 03 Apr 2003
Posts: 33

PostPosted: Sat Dec 06, 2003 12:12 am    Post subject: Please Read Reply with quote

i have this file and what it dows is generate a calendar type thing but whenevr i try to run it it asks me to download the file i have php installed and im 100% SURE because it runs other php scripts FINE! but like i said when i try to run this one it asks me to download .php file i have tried on 2 servers (abyss aPache) remotly and localy this is the script:

Code:
<?php

header("Content-type: image/jpg");

$im = ImageCreateFromJpeg("cal.jpg");
$white = imagecolorallocate($im, 255,255,255);
$black = imagecolorallocate($im, 0,0,0);
$month = date("M");
$day = date("j");
$time = date("h:i:s A");

imagettftext($im, 12, 0, 16, 44, $white, "fonts/ariblk.ttf",
"$month");
imagettftext($im, 25, 0, 36, 77, $black, "fonts/ariblk.ttf",
"$day");
imagettftext($im, 10, 0, 14, 93, $black, "fonts/ariblk.ttf",
"$time");

// imagepng($im);
  imagejpeg($im,'',50);
imagedestroy($im);
?>


i have gd enabled and all the paths r correct but it still doesnt work please help me!
Back to top View user's profile Send private message
TRUSTAbyss
-


Joined: 29 Oct 2003
Posts: 3752
Location: USA, GA

PostPosted: Sat Dec 06, 2003 4:17 am    Post subject: Reply with quote

Is this supposed to be link to as a image.

<img src="calender.php?">

How do u run this script because I cannot test it
without knowing how to use it , I have GD installed
and I would like to help you. 8)
Back to top View user's profile Send private message Visit poster's website
Trix
-


Joined: 03 Apr 2003
Posts: 33

PostPosted: Sun Dec 07, 2003 2:54 pm    Post subject: Reply with quote

hmm ok thnx i put it up as a image but now all it does is show cal.jpg without the date on it! loo: http://anime.bounceme.net/Sites/Cal/cal.htm
Back to top View user's profile Send private message
aprelium
-


Joined: 22 Mar 2002
Posts: 6800

PostPosted: Sun Dec 07, 2003 7:34 pm    Post subject: Reply with quote

Trix,

We suggest that you write the full path of the font instead of only fonts/ariblk.ttf .
_________________
Support Team
Aprelium - http://www.aprelium.com
Back to top View user's profile Send private message Send e-mail
Trix
-


Joined: 03 Apr 2003
Posts: 33

PostPosted: Sun Dec 07, 2003 9:44 pm    Post subject: Reply with quote

Hey thnx for the help guys but i have ttryed that alreadys and it still doesnt work :'(
Back to top View user's profile Send private message
aprelium
-


Joined: 22 Mar 2002
Posts: 6800

PostPosted: Mon Dec 08, 2003 4:32 am    Post subject: Reply with quote

Trix,

It may be interesting to check the documentation of imagettftext in http://www.php.net (and especially the user contributed notes).
_________________
Support Team
Aprelium - http://www.aprelium.com
Back to top View user's profile Send private message Send e-mail
Trix
-


Joined: 03 Apr 2003
Posts: 33

PostPosted: Mon Dec 08, 2003 8:52 am    Post subject: Reply with quote

my m8 has it working its just that his one is on a apache linux box and i tryed it on there and for some reason it still asked me to onload the code but now it doesnt do that it just displays ca.jpg with no differences
Back to top View user's profile Send private message
TRUSTAbyss
-


Joined: 29 Oct 2003
Posts: 3752
Location: USA, GA

PostPosted: Mon Dec 08, 2003 8:54 am    Post subject: Reply with quote

Trix , please tell me how to set this up
im offering you help 8)
Back to top View user's profile Send private message Visit poster's website
aprelium
-


Joined: 22 Mar 2002
Posts: 6800

PostPosted: Mon Dec 08, 2003 8:42 pm    Post subject: Reply with quote

Trix,

The issue is not with the web server. It is with your PHP installation. GD library is known to use other libraries such as FreeType. This may be the cause of the problem.
_________________
Support Team
Aprelium - http://www.aprelium.com
Back to top View user's profile Send private message Send e-mail
Trix
-


Joined: 03 Apr 2003
Posts: 33

PostPosted: Tue Dec 09, 2003 8:46 am    Post subject: Reply with quote

howdo i instal;l free type and all other libraries that gd2 mite ever call on?
Back to top View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Aprelium Forum Index -> PHP All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB phpBB Group