php-extension

PHP mbstring doesn't work with Apache on Windows

梦想与她 提交于 2019-12-04 19:58:00
I have to get PHP 5.4 (32 bit, TS) with mbstring running with Apache 2.4 (32 bit) on Windows. In my httpd.conf I set this: PHPIniDir "c:/php54" LoadModule php5_module "c:/php54/php5apache2_4.dll" AddHandler application/x-httpd-php .php And in my php.ini: extension_dir = "ext" ... extension=php_mbstring.dll Now, when I execute php -m it correctly says that mbstring is loaded: ... libxml mbstring mcrypt ... And php -i spits out a section about mbstring: mbstring Multibyte Support => enabled Multibyte string engine => libmbfl HTTP input encoding translation => disabled libmbfl version => 1.3.2 ..

zeromq php extension for windows

社会主义新天地 提交于 2019-12-04 15:59:34
I am using Zend server configured with IIS 7.5. I searched for edit: zeromq php extension, I found these http://valokuva.org/builds/ and http://snapshot.zero.mq/ I have tried to add extension in php.ini and when I enable it form zend admin it shows an error "The system could not load this extension" and in logs "PHP Startup: Unable to load dynamic library 'C:\Program Files\Zend\ZendServer\lib\phpext\php_zmq.dll' - The specified module could not be found. in Unknown on line 0". I have tried to build extension (.dll) from source but it also didn't work. On http://www.zeromq.org/bindings:php its

Symfony ZipArchive PHP Extension Class Not Found

安稳与你 提交于 2019-12-04 12:36:40
I tried this code var_dump(class_exists('ZipArchive')); $zip = new ZipArchive(); well, the output is like this. bool(true) Fatal error: Class 'MyProject\ProjectBundle\Controller\ZipArchive' not found in \path\to\my\Controller.php on line 83 Anyone can help me how to solve this? I have installed php-pear php5-dev libcurl3-openssl-dev libevent-dev pecl-http all i need have been installed and i have put the extension to my php.ini then restart my apache But i still get that error. Then I tried this $z = new /ZipArchive(); from this page and then i got this error : Parse error: syntax error,

How to automatically enable php extensions in Homestead on vagrant up

白昼怎懂夜的黑 提交于 2019-12-04 09:15:43
问题 Im using Laravel 5.3 in Homestead with Vagrant 1.8.7 running on VirtualBox. I have need to enable some php extensions. I know that I could ssh into the box and edit the php.ini to enable the extension but this seems like a very anti-vagrant way to do this. I want to tell Vagrant to provision the box with specific php extensions enabled so that I can simply call vagrant up --provision and the box will be ready to go (kinda the point of vagrant right?) So, How can we automatically enable php

How to install php extension using pecl for specific php version, when several php versions installed in system?

妖精的绣舞 提交于 2019-12-04 07:48:28
问题 I have installed both php5.6 and php7.0 from PPA on Ubuntu according to this manual http://lornajane.net/posts/2016/php-7-0-and-5-6-on-ubuntu But I didn't get how to install extensions using pecl for php5.6 or php7.0. For example I have already installed version of libevent or amqp in php5.6. Now when I type pecl install libevent and my active php version is php7.0 (using update-alternatives --set php /usr/bin/php7.0), pecl returns message that libevent` already installed. But it was

Detect if the FreeType PHP extension is installed on the server

梦想的初衷 提交于 2019-12-04 02:52:36
问题 How do I test to see if the FreeType extension is installed on a server running PHP? I wanted to make a simple CAPTCHA system on my site, so I used imagettftext() and it worked fine. But what if the server didn't have the FreeType library installed? So is there a way to somehow detect FreeType library through code, and if it is not present, fall back to something like imagestring()? If I can't use imagettftext() I may have to look at alternatives to draw big font text as the imagestring max

Convert PHP Class in apache module

本秂侑毒 提交于 2019-12-02 21:30:00
问题 I have write a sophisticate system in php5 (many classes that use static method and include other files) Now I want to distribuite that ant i would choose the module way, so i like to create a module like myFramework.so and include it in Apache (maybe) and after, when i write some php app, I'll use method and/or classes. Now i write <?php include("myFramework.php"); myClass::callMymethod(); ?> The problem is I won't to share my source code and i don't think that obfuscation of code is the

PHP. Extension. Call existing PHP function

随声附和 提交于 2019-12-02 19:10:43
So I decided to write an extension for php. Everything seems to be fine except I'm stuck on a tiny problem. I have php-5.4.9 source codes. There is file ext/standard/mail.c with awesome function PHPAPI int php_mail(char *to, char *subject, char *message, char *headers, char *extra_cmd TSRMLS_DC) In my extension, in acme.c I have includes ... #include "php.h" #include "ext/standard/php_mail.h" #include "php_ini.h" ... So php_mail feels good and works fine. But, obviously, I want to use the code from mail.c starting on line 101 and ending on 189 ( http://pastie.org/5444192 5-93 corresponding

Problems adding cURL to OAuth request engine support

一个人想着一个人 提交于 2019-12-02 09:44:17
问题 I've recently been setting up a new environment for a web application I'm working on and I've run into this following issue that I cannot figure out. Currently I have a docker-composer setup based off of https://hub.docker.com/r/ruslangetmansky/docker-apache-php/ Where I have my API, APP and DB running and need them to talk between each other. During the initialisation of this, I'm currently doing the following command: command: bash -c 'apt-get update && apt-get -y install curl libcurl3

Problems adding cURL to OAuth request engine support

一世执手 提交于 2019-12-02 07:03:06
I've recently been setting up a new environment for a web application I'm working on and I've run into this following issue that I cannot figure out. Currently I have a docker-composer setup based off of https://hub.docker.com/r/ruslangetmansky/docker-apache-php/ Where I have my API, APP and DB running and need them to talk between each other. During the initialisation of this, I'm currently doing the following command: command: bash -c 'apt-get update && apt-get -y install curl libcurl3 libcurl3-dev php5-curl php5-oauth && rm -rf /var/lib/apt/lists/* && composer install && /sbin/entrypoint.sh