Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to install Yaf extension

2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/03 Report--

This article will give you a detailed explanation on how to install Yaf extension. The editor thinks it is very practical, so I share it with you for reference. I hope you can get something after reading this article.

Install Yaf

The latest version of Yaf supports PHP7.0 at least, so we need to ensure that the current PHP environment is above version 7.0, and the maximum version of Yaf that supports PHP5.X is 2.3.4. The author no longer recommends using the old version of Yaf. Since Yaf is famous for its high performance, and PHP7 is also famous for its high performance, why not let the strong join forces?

1. Compilation and installation

To compile and install, you first need to download the source code through Git.

First download the Yaf compilation installation package and open (https://github.com/laruence/y...

$> wget-c https://github.com/laruence/yaf/archive/yaf-3.0.5.tar.gz$ > tar xzvf yaf-3.0.5.tar.gz & & cd yaf-3.0.5 $> phpize$ >. / configure$ > make$ > sudo make install

Next, you need to manually modify the php.ini file to load the yaf.so file

2. Pecl installation

Yaf is installed directly through the pecl command. After the installation is successful, the php.ini file will be automatically configured, and there is no need to manually load yaf.so.

$> pecl install yaf

After the installation is complete, use the command to check whether the installation is successful

$> php-ri yaf

If you get the Yaf version number and configuration details, the installation is successful, as follows

$> php-- ri yafyafyaf support = > enabledVersion = > 3.0.5Supports = > Local Value = > Master Valueyaf.library = > no value = > no valueyaf.action_prefer = > Off = > Offyaf.lowcase_path = > Off = > Offyaf.use_spl_autoload = > Offyaf.forward_limit = > 5 = > 5yaf.name_suffix = > On = > Onyaf.name_separator = > no value = > no valueyaf.st_compatible = > Off = > Offyaf.environ = > product = > productyaf.use_namespace = > Off = > Off project configuration

Use the Yaf scaffolding tool to generate the basic framework

1. Go to the directory where the scaffolding tools are located in the Yaf source package

$> cd yaf-3.0.5/tools/cg/

two。 Generate basic framework code with scaffolding tools

$> php yaf_cg Yaf_First

Yaf_First is the name of the project. Readers can define it by themselves.

Copy the generated code to the build environment directory

This is the end of the article $> cp-r. / output/Yaf_First/* / home/wwwroot/default/ on "how to install Yaf extension". I hope the above content can be helpful to you, so that you can learn more knowledge. if you think the article is good, please share it for more people to see.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

  • How to realize paging in PHP+ajax

    This article is to share with you about how PHP+ajax implements paging. The editor thinks it is very practical, so share it with you as a reference and follow the editor to have a look. Details are as follows: HTML code is as follows: title

    © 2024 shulou.com SLNews company. All rights reserved.

    12
    Report