如何在WAMP上安装YAML扩展?

My environment is this:

Windows 7 64bit
Wamp 2.4
PHP 5.4.12

I have enabled the extension in the php.ini files at both locations viz. PHP and Apache:

extension=yaml.so

But yaml_parse is still shown as undefined.

Any advice on how to get YAML working on Wamp?

Make sure you have written extension=yaml.so without any quotes.

I have managed to solve this by following some hints from @Loenix.

You have to do as follows:

  1. Download the corresponding php_yaml.dll from the official website. PHP under WAMP is threaded (https://pecl.php.net/package/yaml)

  2. Extract the php_yaml.dll file and copy it to the following directory:

C:\wamp64\bin\php\php\ext

  1. Add the following text (without quotes) "extension=php_yaml.dll" in (and this is important) phpForApache.ini located in the C:\wamp64\bin\php\php\ directory

  2. Right click on the WAMP tray icon and click Refresh

For me, step 3 was the trick since I was editing the php.ini file in the /bin/php/php directory, which seems to not be taken into consideration.

Hope this helps!