php-extension

Activating PHP extensions in Bluemix

邮差的信 提交于 2019-12-07 10:22:58
问题 This is a purely Bluemix question! I've got code running smoothly on a localhost but when I migrated it to Bluemix my DB connection failed me. Checking the logs I found the issue "Call to undefined function mysqli_init()" HTTP response 500. I have found out that extension have been disabled to make it smaller and have found some details about it: Buildpack options. Unfortunately I have tried that and failed. Maybe I have misunderstood the solution. Any Help would be greatly appreciated. EDIT:

Is the PHP Intl extension thread safe?

◇◆丶佛笑我妖孽 提交于 2019-12-07 08:14:08
问题 I've been reading about locales in PHP and it seems setlocale() has problems with threads. (I'm not too familiar with threads - the docs mention it is not thread safe) I'd like to give my project the ability to deal with certain number formats and the Intl extension seems interesting. http://php.net/manual/en/book.intl.php Should I expect the same problems that setlocale() has using the Intl extension? 回答1: Ok, I was curious about this myself as well, so I devised a test. First I tested

How to install php-mongo on CentOS 5.3?

一世执手 提交于 2019-12-07 03:58:42
问题 I've already installed mongoDB on my VPS. It works well. Now I want to install php driver to make php work with mongoDB. I followed Mongo Installation but cannot find information I need. This manual contains only this notice: If you are using CentOS or Redhat, Csoke Arpad created » RPMs for these distributions (PHP Mongo). I'm not familiar with ssh commands on CentOS and distributions (what is it?). Can anyone help me install this php extension? Please provide all ssh commands needed to

adding Imagick in xampp

℡╲_俬逩灬. 提交于 2019-12-07 03:22:22
问题 I have followed the following steps in http://bytehash.appspot.com/2012/02/Installing-imagick-for-php-in-windows-under-xampp i have downloaded the dll file for imagick and added this into xampp/php/ext folder and included it as follows: extension=php_imagick_ts.dll . I have also installed imagemagick and can confirm it is installed as i have run the following command: C:\>convert -version Version: ImageMagick 6.8.6-8 20 Copyright: Copyright (C) 1999-2 Features: DPC OpenMP Delegates: bzlib

Docker image build with PHP zip extension shows “bundled libzip is deprecated” warning

删除回忆录丶 提交于 2019-12-06 17:30:36
问题 I have a Dockerfile with a build command like this: #install some base extensions RUN apt-get install -y \ zlib1g-dev \ zip \ && docker-php-ext-install zip I get this warning from build output: WARNING: Use of bundled libzip is deprecated and will be removed. configure: WARNING: Some features such as encryption and bzip2 are not available. configure: WARNING: Use system library and --with-libzip is recommended. What is the correct way to install the zip extension without these warnings? My

Retrieve extension version in php

醉酒当歌 提交于 2019-12-06 17:25:42
问题 Is it possible to get extension version in php? get_loaded_extensions returns only loaded extentions names, but not versions :( 回答1: I believe this is what you're looking for: $version = phpversion("extensionName"); More information 回答2: At the command line, where extension is the extension name. php --re extension | head -1 If unsure of the extension name, list extensions with php -m . 回答3: http://php.net/manual/en/reflectionextension.getversion.php <?php $ext = new ReflectionExtension(

PHP extension wrapper for C++ [closed]

ぃ、小莉子 提交于 2019-12-06 11:26:11
This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center . Closed 6 years ago . I am new in this area of writing extension for PHP, however I need to create a wrapper class for C++ to PHP. I am currently using PHP 5.2.13. I read this article http://devzone.zend.com/article/4486-Wrapping-C-Classes-in-a-PHP-Extension , a tutorial on

Symfony ZipArchive PHP Extension Class Not Found

妖精的绣舞 提交于 2019-12-06 08:19:25
问题 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

How do I add an array as an Object Property to a class declared within a PHP extension?

点点圈 提交于 2019-12-06 05:13:42
问题 I want my PHP extension to declare a class equivalent to the following PHP: class MyClass { public $MyMemberArray; __construct() { $this->MyMemberArray = array(); } } I'm following the examples in "Advanced PHP Programming" and "Extending and Embedding PHP" and I'm able to declare a class that has integer properties in PHP_MINIT_FUNCTION . However, when I use the same approach to declare an array property in PHP_MINIT_FUNCTION , I get the following error message at runtime: PHP Fatal error:

No performance gain with APC on WampServer

北城余情 提交于 2019-12-06 01:55:16
I'm working on a Windows workstation, on which I use WampServer as my development platform, to write PHP applications which are then run on Linux. I'm pretty used to APC on Linux, which is blazing fast and a must have for me. However, I'm always surprised to get no performance gain when I use it on Windows. This leads to generation times close to 1 second per page, on applications relying heavily on the Zend Framework for example. Most of this time is spent parsing PHP files (I verified that by benchmarking include() s). The very same application can run 10x faster on Linux on MacOS. The