首先,我收到一个警告和一个致命错误。警告:
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"?
然后我用break替换了continue,警告消失了。但即使在替换之后,致命的错误仍然会发生。致命错误:
PHP Fatal error: Uncaught Error: Call to undefined function each() in D:\xampp\php\pear\PHPUnit\Util\G
对于我的网站,我创建了一个表单,供参与者填写以进行一些培训。
我开始收到这个错误:
Fatal error: Call to undefined function escape() in load.php on line 10
我有两个php文件,包括在超文本标记语言,load.php和disp.php
disp.php
<form method="post" name="FORMA" id="RTABLE">
<table width="100%" cellspacing="3" cel
我最近在我的mediawiki安装中添加了UserMerge扩展。已按照说明找到。我启用了$wgShowExceptionDetails = true;它给了我这样的结果:
[f9bbe088] /wiki/index.php/Special:UserMerge Exception from line 376 of /wiki/includes/SpecialPage.php: Call to undefined method UserMerge::getPageTitle
Backtrace:
#0 /wiki/extensions/UserMerge/UserMerge_body.p
我使用的是Ubuntu 16.04,我正在尝试安装prestashop电子商务CMS,它需要php zip扩展来解压主CMS文件夹。
我已经安装了php-zip和php7.2-zip,我还重新启动了web服务器(apache2),但内容管理系统仍然显示以下消息
An error has occured:
You must install PHP zip extension first
下面是我安装的php zip包和我当前的php版本的结果:
eljaouhari@eljaouhari-HP-350-G1:/var/www/html$ php -v
PHP 7.2.5-1+ubuntu16.0
由于这是一个新问题,我假设可以创建一个新问题?
我之前的问题是:
Markus帮助我解决了问题,我已经联系了客户并为他们设置了VPS,我已经传输了文件和数据库,一切都运行得很好。除了相同的错误,只是这一次,我得到了一个不同的错误;
Fatal error: Call to undefined function imagecreatetruecolor() in /home/public_html/admin/library/functions.php on line 232
我假设这与同一件事有关,并且它需要重新编译php?有人能给我一些关于如何在Mac OS X上重新编译php的说明吗?我
我正试图在我的mac上运行,并为此安装了MAMP。我跟踪了,但是当我试图去http://localhost:8888/lwt/的时候,我得到的是:
本地主页无法工作
localhost当前无法处理此请求。
500
我在htdocs文件夹中创建了一个不同的文件夹,并在其中创建了一个php文件(index.php),并编写了一些代码来查看php是否正常工作:
<?php
echo "this is the start";
phpinfo();
echo "<br>this is the end";
?>
这一切都很好,而且很有效。我还
我的php脚本在作为安全页面和json_encode()被调用时会失败,但在其他情况下不会。代码是从一个更大的脚本中提取出来的,该脚本来自XHR。PHP版本5.2.0.,Apache/1.3.34 (Unix)。
问题的根源是: PHP,我的ISP,还是我?
要进行演示,请将此脚本命名为4-way:
=>工作,安全协议,不调用json_encode()。
=>失败,安全协议调用json_encode()。
在第一种情况下,您将看到一些html,然后php会响应结果。在第二种情况下,您将只看到html;没有php输出。
/*
Try these 2 links also from
为什么我会从下面的代码片段中得到这个“解析错误:语法错误,在upload2.php on line 5中出现意外的T_FUNCTION”:
<?php
$title = "Click to see the picture in full size";
$images = glob('./images/*.*', GLOB_BRACE);
usort($images, function($a, $b) {
return filemtime($a) < filemtime($b);
});
foreach($images as $image
我已经从ppl:ondrej/php安装了PHP7.2以及大多数所需的模块。我想安装phpMyAdmin,但出于某种原因,它希望安装PHP7.1和8.0中的模块。在没有错误版本的不必要模块的情况下,最干净的安装方法是什么?我在ondrej中找不到一个phpMyAdmin,所以这是来自焦点回购的4.4.9版本。
# apt install phpmyadmin
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additiona
刚刚开始在Ubuntu22.04上工作,我刚刚在我的Ubuntu上安装了lamp堆栈,它运行良好,但问题是当我从GitHub克隆回购时,当我试图通过浏览器运行该项目时,我看到一个"localhost is currently unable to handle this request." 500 server err,我可以在projects目录中创建一个简单的文件,并且没有错误地运行它,而且我也不能使用localhost/phpmyadmin,我在这里基本上得到了var/www/html的ls -la日志结果。
drwxr-xr-x 3 root root
我有一个问题的网站iv一直在使用easyphp服务器在本地工作。我现在已经把它上传到了一个was服务器上,之前一切正常,现在我得到了php错误,比如:
Call to undefined function session_status() in /home/site/public_html/index.php on line 2
这只是索引页面上的一个简单脚本,但所有其他页面都存在相同的会话错误问题,但它在本地工作,这使得它更加奇怪。
<?php
if (session_status() !== PHP_SESSION_ACTIVE) {session_start();}
托管网站,试图为联系人表单设置邮件程序,但页面返回错误,查看日志并发现以下内容:
PHP警告: stream_socket_enable_crypto():第368行/home/user/public_html/php/php-mailer/class.smtp.php中的对等证书CN=host5.xyz' did not match expected CN=localhost‘
已弃用:__autoload()已弃用,请在/home/user/public_html/php/php-mailer/PHPMailerAutoload.php的第45行改用spl_autoload_reg
我刚开始与一个有一年历史的Laravel项目合作,我的奖学金项目,一个主要的缺陷抑制进展是在路上。任何帮助都将不胜感激。下面的故事。
一旦Laravel启动并运行并尝试登录,我就会得到以下错误:
Class User contains 3 abstract methods and must therefore be declared abstract or
implement the remaining methods
(Illuminate\Auth\UserInterface::getRememberToken,
Illuminate\Auth\UserInterface::setRe
我有以下function.php: function getPublishedPosts() {
// use global $conn object in function
global $conn;
$sql = "SELECT * FROM posts WHERE published=true";
$result = mysqli_query($conn, $sql);
// fetch all posts as an associative array called $posts
$posts = mysqli_fetc
我使用的XAMPP有PHP 5.3.1,在htdocs文件夹中有restler结构
在我的htdocs文件夹中,我有index.php
<?php
require_once 'vendor/restler.php';
use Luracast\Restler\Restler;
$r = new Restler();
$r->addAPIClass('Say'); // repeat for more
$r->handle(); //serve the response
和say.php
<?php
class Say {
/*