如何才能让FTP、EMAIL、SESSION、IMAGE函数生效?能否详细解释!

wzs 2000-08-17 04:17:00
...全文
246 10 打赏 收藏 转发到动态 举报
写回复
用AI写文章
10 条回复
切换为时间正序
请发表友善的回复…
发表回复
flyby 2000-09-08
  • 打赏
  • 举报
回复
你用的是PHP4吧!
在 PHP.ini文件中有:
;Windows Extensions
;extension=php_nsmail.dll
extension=php_calendar.dll
;extension=php_dbase.dll
;extension=php_filepro.dll
;extension=php_gd.dll
;extension=php_dbm.dll
;extension=php_mssql.dll
;extension=php_zlib.dll
;extension=php_filepro.dll
extension=php_imap.dll
extension=php_ldap.dll
;extension=php_crypt.dll
;extension=php_msql2.dll
;extension=php_odbc.dll
; Note that MySQL support is now built in, so no dll is needed for it.
将对应项的";"去掉,将PHP文件包里的相应文件考到Windows/system下,最重要的是指定路径正确。
SimonDW 2000-08-26
  • 打赏
  • 举报
回复
要gd.dll才能支持image类函数。仔细看php的说明书吧。(有中文的)
www.phpuser.com有下.
tszzp 2000-08-22
  • 打赏
  • 举报
回复
The Header() function must be the first function to print any output of any kind.
The error says that the error occurs at line 3, which should be your header line, but that is line 2 in the script. Do you have any html text before the script?
If you plan to use this function to include an image in your html, you can forget it, because you can only make an image if you use the header() statement, and you can only use the header statement if you don't print anything before the header statement.
Ergo, you can't print the "<img src=" tag before printing the image.
You will have to make a seperate script for the image.
wzs 2000-08-19
  • 打赏
  • 举报
回复
这是错误信息:Warning: Cannot add header information - headers already sent by (output started at C:\Program Files\php-web\test.php:2) in C:\Program Files\php-web\test.php on line 3

Fatal error: Call to undefined function: imagecreate() in C:\Program Files\php-web\test.php on line 4
源程序:test.php
<?php
Header("Content-type: image/gif");
$im = imagecreate(400,30);
$black = ImageColorAllocate($im, 0,0,0);
$white = ImageColorAllocate($im, 255,255,255);
imageline($im, 1, 1, 350, 25, $black);
imagearc($im, 200, 15, 20, 20, 35, 190, $white);
imagestring($im, 5, 4, 10, "Graph TEST!!", $white);
ImageGif($im);
ImageDestroy($im);
?>

tszzp 2000-08-18
  • 打赏
  • 举报
回复
不会吧,我在我的应用程序中用是可以,要不把你们的代码贴出来看看.
hyzx2000 2000-08-18
  • 打赏
  • 举报
回复
我也有同样的问题,我发现即使extension里加了php3_zlib.dll,imagegif()、imagecreatefromgif()也会没定义,但是其他的图象函数都可用。
wzs 2000-08-18
  • 打赏
  • 举报
回复
我有下载也全都加上并去掉“;”但这家伙说“不知道你要做什么,这个函数没有定义”气死我了!
alan_turing 2000-08-18
  • 打赏
  • 举报
回复
另外,email()只能在unix下用
tszzp 2000-08-18
  • 打赏
  • 举报
回复
我估计是你没装一些动态链接库的原因,比如imagegif()就需要zlib.dll的支持,
你去下载你所需的dll,然后在你的配置文件中作相应的改动,即可。你试试看。
hyzx2000 2000-08-17
  • 打赏
  • 举报
回复
我这几天正在学PHP,也遇到很多问题,如email()函数出现不能connect的错误,imagegif()、imagecreatefromgif()未定义的错误,但imagecreate()可用。不过我是用的Windows下的Apache和PHP3。

21,886

社区成员

发帖
与我相关
我的任务
社区描述
从PHP安装配置,PHP入门,PHP基础到PHP应用
社区管理员
  • 基础编程社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧