如何在 XAMPP for Windows 上安装 V8Js for PHP?

2024-04-12php开发问题
7

本文介绍了如何在 XAMPP for Windows 上安装 V8Js for PHP?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

问题描述

现在已经工作了几天,试图找到一种在 XAMPP for windows 上安装 V8Js 的简单方法,但没有成功.

Been working for days now trying to find an easy way to install V8Js on XAMPP for windows, yet with no success.

我已经下载了带有 PHP 7.2.0 VC15 的最新 XAMPP 版本,并按照这篇博文中的说明进行操作 - https://blog.xenokore.com/how-to-install-v8js-for-php-on-windows/ - 但无济于事.我在 phpinfo 中没有看到 V8Js 的提及,当我尝试使用它时,我得到一个错误

I have downloaded the latest XAMPP version with PHP version 7.2.0 VC15, and followed the instructions in this blog post - https://blog.xenokore.com/how-to-install-v8js-for-php-on-windows/ - but to no avail. I don't see a mention to V8Js in the phpinfo, and when I try to use it I get an ERROR

Error: Class 'V8Js' not found in...

我已经从这里下载了 dll 文件 - https://blog.xenokore.com/how-to-install-v8js-for-php-on-windows/ - 并使用了最新的 7.2.1 VC15 x86 ts 版本,但没有成功.

I have downloaded the dll files from here - https://blog.xenokore.com/how-to-install-v8js-for-php-on-windows/ - and used the latest 7.2.1 VC15 x86 ts version with no success.

谁能提供一些帮助?

推荐答案

你需要从这里下载最新的php版本https://www.apachelounge.com/viewtopic.php?t=6359

You need to download lasted php version from here instead https://www.apachelounge.com/viewtopic.php?t=6359

然后将 php_v8js.dllphpext 移动到本地的同一目录中.

Then move a php_v8js.dll from phpext into same directory on your local.

但是 php 根目录中的 5 个文件必须移到您的 apachein

But with 5 files additional from root directory of php have to move into your apachein instead

  • icui18n.dll
  • icuuc.dll
  • v8.dll
  • v8_libbase.dll
  • v8_libplatform.dll

确保将它包含在您的 php.ini 中,方法是添加以下行:

Be sure to have it in your php.ini, by adding the following line:

extension=php_v8js.dll

然后尝试重启apache或者通过命令php -m查看,玩得开心.

Then try to restart apache or check by command php -m, have fun.

这篇关于如何在 XAMPP for Windows 上安装 V8Js for PHP?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

The End

相关推荐

PHP实现DeepL翻译API调用
DeepL的翻译效果还是很强大的,如果我们要用php实现DeepL翻译调用,该怎么办呢?以下是代码示例,希望能够帮到需要的朋友。 在这里需要注意,这个DeepL的账户和api申请比较难,不支持中国大陆申请,需要拥有香港或者海外信用卡才行,没账号的话,目前某宝可以...
2025-08-20 php开发问题
168

PHP通过phpspreadsheet导入Excel日期数据处理方法
PHP通过phpspreadsheet导入Excel日期,导入系统后,全部变为了4开头的几位数字,这是为什么呢?原因很简单,将Excel的时间设置问文本,我们就能看到该日期本来的数值,上图对应的数值为: 要怎么解决呢?进行数据转换就行,这里可以封装方法,或者用第三方的...
2024-10-23 php开发问题
287

mediatemple - 无法使用 codeigniter 发送电子邮件
mediatemple - can#39;t send email using codeigniter(mediatemple - 无法使用 codeigniter 发送电子邮件)...
2024-08-23 php开发问题
11

Laravel Gmail 配置错误
Laravel Gmail Configuration Error(Laravel Gmail 配置错误)...
2024-08-23 php开发问题
16

将 PHPMailer 用于 SMTP 的问题
Problem with using PHPMailer for SMTP(将 PHPMailer 用于 SMTP 的问题)...
2024-08-23 php开发问题
4

关于如何在 GoDaddy 服务器中使用 PHPMailer 设置 SMTP 的问题
Issue on how to setup SMTP using PHPMailer in GoDaddy server(关于如何在 GoDaddy 服务器中使用 PHPMailer 设置 SMTP 的问题)...
2024-08-23 php开发问题
17