Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

perl cgi語法一問

0 views
Skip to first unread message

愛上阿呆的笨男人.

unread,
Mar 11, 2003, 12:31:55 AM3/11/03
to
請問複製檔案的.cgi語法 該如何寫.
假設.我要複製一個同檔名(test.txt)的檔案.至 c://work下
該如何寫.

請教各位大大.

--
[m [1;32m※ 來源:‧蛋捲廣場 bbs.tku.edu.tw‧[FROM: 163.13.138.102] [m

John Lin

unread,
Mar 11, 2003, 10:02:14 PM3/11/03
to
"愛上阿呆的笨男人."

> 請問複製檔案的.cgi語法 該如何寫.
> 假設.我要複製一個同檔名(test.txt)的檔案.至 c://work下

use File::Copy;
copy('test.txt','C:/work/test.txt') or die "can't copy: $!\n";

John Lin


真難

unread,
Mar 14, 2003, 7:39:01 AM3/14/03
to
《 在 jihghong. 的大作中提到: 》
: "愛上阿呆的笨男人."


請問 or die "can't copy: $!\n"; 是什麼意思阿...
不要複製.......不太懂也...

--
[m [1;35m※ 來源:‧蛋捲廣場 bbs.tku.edu.tw‧[FROM: 163.13.74.183] [m

Haru Ranman

unread,
Mar 14, 2003, 9:45:25 AM3/14/03
to
※ 引述《huangi...@bbs.tku.edu.tw (真難)》之銘言:
> 《 在 jihghong. 的大作中提到: 》
> : "愛上阿呆的笨男人."

> : use File::Copy;
> : copy('test.txt','C:/work/test.txt') or die "can't copy: $!\n";
> : John Lin
> 請問 or die "can't copy: $!\n"; 是什麼意思阿...
> 不要複製.......不太懂也...

就是如果copy不到 會印出"can't copy"的訊息....
--
※ Origin: 楓橋驛站<bbs.cs.nthu.edu.tw> ◆ From: pads1.cs.nthu.edu.tw

0 new messages