有人可以告诉我为什么这个功能根本不复制文件?PHP的“复制”不起作用
$pluginfile = get_bloginfo('template_url') . '/wp-content/plugins/supersqueeze/supersqueeze.php';
$urlparts = get_bloginfo('template_url');
$homeurl = home_url();
$urlstrip = str_replace($homeurl, '..', $urlparts);
$urldest = $urlstrip . '/supersqueeze.php';
function copyemz(){
global $pluginfile; global $urldest;
if([email protected]($pluginfile,$urldest)) {
$errors= error_get_last();
}
}
该文件是从/public_html/wp-admin/plugins.php
运行我需要它的文件在($ pluginfile)/public_html/wp-content/plugins/supersqueeze/supersqueeze.php
到($ urldest)/public_html/wp-content/themes/[active wordpress theme]
复制 - 当然替换[活跃wordpress主题]与主题的目录。
`$ errors`说什么? – ajreal 2011-01-11 06:25:19
删除@并告诉我们你得到了什么错误 – meze 2011-01-11 06:25:45