Flash post: Mac, PHP and “Warning: PHP Startup: Unable to load dynamic library”

I’m on Mac OS X Yosemite (Version 10.10.1) and I’m using PHP 5.5.14.
In a nutshell, every time I write

php -v

on the shell I’ve a list of errors like the following example shows

Warning: PHP Startup: Unable to load dynamic library '/usr/local/php5/lib/php/extensions/no-debug-non-zts-20121212/php_bz2.dll' - dlopen(/usr/local/php5/lib/php/extensions/no-debug-non-zts-20121212/php_bz2.dll, 9): image not found in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library '/usr/local/php5/lib/php/extensions/no-debug-non-zts-20121212/php_curl.dll' - dlopen(/usr/local/php5/lib/php/extensions/no-debug-non-zts-20121212/php_curl.dll, 9): image not found in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library '/usr/local/php5/lib/php/extensions/no-debug-non-zts-20121212/php_gd2.dll' - dlopen(/usr/local/php5/lib/php/extensions/no-debug-non-zts-20121212/php_gd2.dll, 9): image not found in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library '/usr/local/php5/lib/php/extensions/no-debug-non-zts-20121212/php_mbstring.dll' - dlopen(/usr/local/php5/lib/php/extensions/no-debug-non-zts-20121212/php_mbstring.dll, 9): image not found in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library '/usr/local/php5/lib/php/extensions/no-debug-non-zts-20121212/php_mysql.dll' - dlopen(/usr/local/php5/lib/php/extensions/no-debug-non-zts-20121212/php_mysql.dll, 9): image not found in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library '/usr/local/php5/lib/php/extensions/no-debug-non-zts-20121212/php_openssl.dll' - dlopen(/usr/local/php5/lib/php/extensions/no-debug-non-zts-20121212/php_openssl.dll, 9): image not found in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library '/usr/local/php5/lib/php/extensions/no-debug-non-zts-20121212/php_pdo_mysql.dll' - dlopen(/usr/local/php5/lib/php/extensions/no-debug-non-zts-20121212/php_pdo_mysql.dll, 9): image not found in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library '/usr/local/php5/lib/php/extensions/no-debug-non-zts-20121212/php_pdo_sqlite.dll' - dlopen(/usr/local/php5/lib/php/extensions/no-debug-non-zts-20121212/php_pdo_sqlite.dll, 9): image not found in Unknown on line 0
PHP 5.5.14 (cli) (built: Jun 28 2014 10:29:43)
Copyright (c) 1997-2014 The PHP Group

This is clearly a problem due to PHP no able to load some libraries previously activated on the php.ini file somewhere, over there.. Over there that I brought it here down to you.
Continue reading

RESTful client-server with MVC Design Pattern

Few months ago I’ve created a Service Oriented Architecture from scratch using the MVC paradigm.
The API is based on three parameters to demonstrate you can create your own with as many parameters you prefer*.

http://restful_client-server/category/keyword/pub_year

where

  1. {category}
    The value ‘book’ is the only available for this parameter

  2. {keyword}
    Any string, any keyword for the book search

  3. {pub_year}
    The published year in the following format 0000

For example, with the following request you’ll get all the books with “RESTful” in the title and with publish year “2014”

http://restful_client-server/book/RESTful/2014

Continue reading

Xdebug problem: Xdebug doesn’t format output as expected

xdebug-logo

Xdebug is a PHP extension which provides debugging and profiling capabilities.
( Wikipedia http://en.wikipedia.org/wiki/Xdebug )

The test architecture I’m using has the following features

  • Ubuntu Server 12.04
  • Apache/2.2.22
  • PHP 5.3.10
  • Zend Engine v2.3.0
  • Xdebug v2.2.5

Continue reading