“`这表示PHP版本为7.3.12。 方法二:通过创建并运行一个PHP脚本来查看打开任意文本编辑器,创建一个以“.php”为后缀的文件,例如“check_php_version.php”,并在文件中写入以下代码:“`php“`保存并关闭文件,然后在命令行中执行以下命令:“`php check_php_version.php“`回车后,会显示当前PHP的版本号,例如:“...
4. 使用在线工具:还可以使用一些在线工具来检查PHP的版本。只需在搜索引擎中搜索”PHP version checker”,然后选择一个合适的工具,按照其提示进行检查。 通过这些方法之一,您可以轻松地检查PHP的版本。请注意,对于不同的操作系统和Web服务器,可能会有略微不同的方法来检查PHP版本。 Worktile&PingCode市场小伙伴 如何...
3、通过 PHP 脚本查看 PHP 版本: 创建一个名为check_php_version.php的文件,并将以下代码复制到文件中: “`php <?php echo "PHP version: " . phpversion(); ?> “` 将该文件上传到你的网站根目录或虚拟主机的根目录下。 在浏览器中输入以下地址并按回车键访问: “` http://yourdomain.com/check_ph...
如果不能存取 CLI, 那麼便要用 PHP 檢查,用 PHP 檢查可以用 phpinfo() 或者 php-version() 函式,以下用 phpversion() 作為例子,建立一個 php script, 加入以下內容: <?php echo "PHP Version: " . phpversion(); ?> 1 2 3 <?php echo"PHP Version: ".phpversion(); ?> 用瀏覽器開啟以上 php...
<?phpfunctioncheckPHPVersion($minVersion){$current= PHP_VERSION;if(version_compare($current,$minVersion,'<')) {die("需要PHP{$minVersion}或更高版本(当前:{$current})"); }echo"PHP版本满足要求:{$current}"; }checkPHPVersion('7.4.0');?> ...
There you will see the domain and the PHP version set up for it:Another way to check PHP version is PHPinfo() function, commonly used to check the current state of PHP configuration. It can also be used for debugging purposes as it contains all EGPCS (Environment, GET, POST,...
$php_version = phpversion(); if (version_compare($php_version, $ver) < 0) { throw new Exception("This plugin requires at least version $ver of PHP. You are running an older version ($php_version). Please upgrade!"); } } 然后使用下面的代码检查: check_php_version('5.3.0'); 检查...
探索适用于 Web 项目的 PhpStorm IDE。 一个开箱即用的工具满足所有 PHP、JavaScript 和 SQL 编码的需求
Check the box next to the website(s) this PHP version will apply to. Choose the PHP Version, then click Apply. Please note: If a domain is set to Inherit, it will automatically take on whatever PHP setting is assigned to the main domain. Generate php.ini To generate a new php.ini ...
To check exactly which PHP version is used for a certain website, create a simple PHP info file (for example systeminfo.php) in the /home/customer/www/yourdomainname.com/public_html folder, containing the following code: <?php phpinfo(); ?> Then open the file in a browser: http://...