【问题标题】:PhpPowerpoint Manual InstallPhpPowerpoint 手动安装
【发布时间】:2015-03-25 12:47:42
【问题描述】:

我正在尝试手动安装 PhpPowerpoint(不使用 composer)

我已经安装了具有 document_root D:\wamp\www\

的 WAMP

我已将 PhpPowerpoint 文件夹复制到以下路径 D:\wamp\www\php\PhpOffice\

使用手动安装代码(代码在文件D:\wamp\www\php\agile\expMSPowerpoint.php):

require_once '../PhpOffice/PhpPowerpoint/Autoloader.php';
PhpOffice\PhpPowerpoint\Autoloader::register();
$objPHPPowerPoint = new PhpPowerpoint(); <<<< Error in this line

我得到了错误:

致命错误:第 435 行的 D:\wamp\www\php\agile\expMSPowerpoint.php 中找不到类“PhpPowerpoint”

任何安装它的帮助将不胜感激

【问题讨论】:

    标签: php phppowerpoint


    【解决方案1】:

    我建议使用 PHP realpath http://php.net/manual/en/function.realpath.php

    来自手册页:

    realpath() 扩展所有符号链接并解析对 输入路径中的“/./”、“/../”和额外的“/”字符并返回 规范化的绝对​​路径名。

    【讨论】:

    • 另外,您可能需要检查 PhpPowerpoint 的代码和目录是否可以执行并且对您的 Web 服务器用户可用。否则,尝试它的完整路径,看看它是否有效——只是作为一个测试。
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2014-03-02
    • 2011-06-13
    • 2018-08-02
    相关资源
    最近更新 更多