pear

PEAR on Windows: How to change pear.ini location

本小妞迷上赌 提交于 2019-12-03 14:54:25
问题 I am trying to install a PEAR package into my recent XAMPP PHP installation (PHP 5.3.1) on Windows 7 64-bit. Installing new packages fails because PEAR tries to access c:\windows\pear.ini instead of the existing c:\path_to_xampp\php\pear.ini . This results (rightly) in a permission denied error. I am logged on as Administrator, but the Windows directory enjoys some additional protection IIRC. Rather than fiddle with write rights in the windows directory, I would like to use the existing pear

PECL install failed

假如想象 提交于 2019-12-03 13:19:36
问题 after upgrading from PHP5.2.6 to php 5.3. it seams, I also have to reinstall the PHP memcache-module. So I downloaded the newest version of memcache (3.0.6) and followed this documentation: http://www.php.net/manual/en/install.pecl.pear.php pecl install memcache Which results in the following error-message: No releases available for package "pecl.php.net/memcache" install failed what's going on here? By the way: the server is not connected to the Internet, but that shouldn't be a problem,

Pear Mail, how to send plain/text + text/html in UTF-8

偶尔善良 提交于 2019-12-03 12:03:07
问题 I'm trying to send an email in both text and html, but I can't correctly send the right headers. In particular, I'd like to set the Content-Type header, but I can't find how to set it separately for html and text parts. This is my code: $headers = array( 'From' => 'info@mydomain.com', 'Return-Path' => 'info@mydomain.com', 'Subject' => 'mysubject', 'text_encoding' => '7bit', 'text_charset' => 'UTF-8', 'html_charset' => 'UTF-8', 'head_charset' => 'UTF-8', 'Content-Type' => 'text/html; charset

How can I remove completely PHPUnit using the PEAR Installer?

烂漫一生 提交于 2019-12-03 11:09:17
问题 I installed PHPUnit using the PEAR installer a few days ago (I also installed Selenium RC for testing in PHP purpose). Now I want to uninstall it (also delete all related folders and files) I ran the following command: pear uninstall phpunit/PHPUnit and the console displayed: phpunit/PHPUnit not installed I checked the PHPUnit folder, it was still there? Was it uninstalled? I try to reinstall a new PHPUnit, but the console displayed: No releases available for package "pear.phpunit.de/PHPUnit"

dot(.)s are missing here & there in the mail html while sending PEAR Mail_Mime emails

白昼怎懂夜的黑 提交于 2019-12-03 10:51:02
I am sending a mail using PEAR's mail and mail_mime packages and sample code as below: $sendStart=array(); require_once('Mail.php'); require_once('Mail/mime.php'); $sendStart['mail'] =& Mail::factory('mail'); $sendStart['mime'] = new Mail_mime("\n"); $sendStart['mime']->setHTMLBody($html); $sendStart['headers']['Subject']=$title; $sendStart['headers']['X-SMTPAPI']='{"category": ["MailID-XXX"]}'; $body=$sendStart['mime']->get(array( 'html_charset'=>'UTF-8', 'text_charset'=>'UTF-8', 'head_charset'=>'UTF-8' )); //echo ($sendStart['mime']->_htmlbody); exit; $sendStart['mail']->send('xxx@example

How to Ignore Line Length PHP_CodeSniffer

荒凉一梦 提交于 2019-12-03 10:40:45
问题 I have been using PHP_CodeSniffer with jenkins, my build.xml was configured for phpcs as below <target name="phpcs"> <exec executable="phpcs"> <arg line="--report=checkstyle --report-file=${basedir}/build/logs/checkstyle.xml --standard=Zend ${source}"/> </exec> </target> And I would like to ignore the following warning FOUND 0 ERROR(S) AND 1 WARNING(S) AFFECTING 1 LINE(S) -------------------------------------------------------------------------------- 117 | WARNING | Line exceeds 80

Pear install for macports PHP5

青春壹個敷衍的年華 提交于 2019-12-03 10:04:54
I have PHP5 installed via macports in /opt/local/..the default location for macports. There's no portfile for pear. If I do a standard pear install from the pear site what directory location should pear be placed in to work with PHP? While the curl option works, it won't update as you update your ports. An alternative: sudo port install php5 +pear This will install the variant of php5 with pear, in the same location as downloading above, and it will update as you update macports. I had a similar issue just now, and went for installing PEAR in exactly the directory you mentioned. curl -O http:/

How to set up your own PEAR Channel?

时间秒杀一切 提交于 2019-12-03 06:36:10
I am looking for instructions on how to setup a PEAR channel for our project so that we can deploy it with the pear installer. I have searched the web for a while and cannot find any straightforward information. I followed this tutorial for a while, but I am having a hell of a time getting this to work. Does anyone know how to do this? Is there a simpler way? It looks like you are one of the few people who want to do this. That tutorial you linked to appears to be the latest (!) but the package is still somewhat in development . The documentation in that package is also non-existent. It looks

PEAR package install fails

本小妞迷上赌 提交于 2019-12-03 06:31:33
i try to install packages from pear.phpqatools.org/phpqatools First of all command pear config-get php_dir returns D:\Users\xampp\php\pear and I do not have rights to install on C drive. Then according the instructions from http://phpqatools.org/ I enter : pear config-set auto_discover 1 pear install pear.phpqatools.org/phpqatools I have also tried to enter: pear install --alldeps pear.phpqatools.org/phpqatools But result of all these attempts is a failure... This is a log: Package "pear.phpqatools.org/phpqatools" dependency "pear.phpunit.de/PHPUnit" has no releases Unknown remote channel:

how to use php pear mail

心不动则不痛 提交于 2019-12-03 05:06:19
问题 How to include mail.php for using PHP Pear Mail. I'm using the following code in test.php file: require_once "Mail.php"; $from = "<test@gmail.com>"; $to = "<testing@gmail.com>"; $subject = "Hi!"; $body = "Hi,\n\nHow are you?"; $host = "ssl://smtp.gmail.com"; $port = "465"; $username = "<testtest@gmail.com>"; $password = "testtest"; $headers = array ('From' => $from, 'To' => $to, 'Subject' => $subject); $smtp = Mail::factory('smtp', array ('host' => $host, 'port' => $port, 'auth' => true,