gpt4 book ai didi

coldfusion - cffile action ="rename"=== fileMove 在 CFScript 中吗?

转载 作者:行者123 更新时间:2023-12-03 22:48:01 26 4
gpt4 key购买 nike

是否 fileMove()做与 <cffile action="rename"> 完全相同的事情?

最佳答案

不,它们是不同的。没有可用于重命名文件的 CFML 脚本功能。所以,上面的用例只是实现文件重命名的一个技巧。

您必须指定相同的源文件夹和目标文件夹,但更改 中的文件名。

filemove("c:\userdata\files\myFile.docx", "c:\userdata\files\yourFile.docx");

关于coldfusion - cffile action ="rename"=== fileMove 在 CFScript 中吗?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15939255/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com