2

I am trying to install and run a CakePHP 3.0 project on a shared host.
However, CakePHP 3.0 requires php-intl extension, but the hosting provider has denied me to install/enable intl extension on the shared hosting.

How can I run CakePHP 3.0 without intl extension ?

Is there anyway to disable it in CakePHP? Or is there any alternative that I can use ?

I am into a big trouble. Please help...

hg8
  • 1,082
  • 2
  • 15
  • 28
Mohit Gupta
  • 109
  • 1
  • 1
  • 11

8 Answers8

4

if there are still problem to install php_intl, try next plugin: https://github.com/hraq/cake-intl

That won't give any intl functionality, but will allow you to use Cake in server where can't use php_intl for some reason.

4

In both XAMPP and WAMP, mcrypt and mbstring extensions are working by default.

In XAMPP, intl extension is included but you have to uncomment extension=php_intl.dll in php.ini and restart the server through the XAMPP Control Panel.

In WAMP, the intl extension is “activated” by default but not working. To make it work you have to go to php folder (by default) C:\wamp\bin\php\php{version}, copy all the files that looks like icu*.dll and paste them into the apache bin directory C:\wamp\bin\apache\apache{version}\bin. Then restart all services and it should be OK.

http://book.cakephp.org/3.0/en/installation.html#requirements

ashkufaraz
  • 5,179
  • 6
  • 51
  • 82
  • Thank you for your answer in using the intl extension with WAMP. I couldn't figure out why it wasn't working since it is enabled by default. Copying the files to the apache bin directory fixed it. – CertifiedGeek Sep 09 '15 at 15:05
3

You have three options:

1). Don't use CakePHP.

2). Don't use that host.

3). Write a compatibility class that covers all the aspects of php-intl that get used in a way that complies with your host's restrictions.

This is simply because your host will not support something it doesn't already support. It may be possible for you to call them and ask politely for them to allow you to use that extension - but it is not likely they will provide a solution for you.

Therefore, without that extension, you cannot use Cake-PHP - and the only other option would be to write your own compat class - which, since that would be a huge PITA - I only included that to emphasize that you should only consider the other two options.

rm-vanda
  • 3,122
  • 3
  • 23
  • 34
1

CakePHP 3 doesn't work without, Intl extension is required, look to cookbook: http://book.cakephp.org/3.0/en/installation.html#requirements

kicaj
  • 2,881
  • 5
  • 42
  • 68
0

Yes you need INTL to run cakephp 3.

You can try following :

http://coolestguidesontheplanet.com/upgrade-to-php-5-4-or-5-5-mac-osx-10-8-mountain-lion/

Then change path in php.ini, for example

extension_dir = "/usr/local/php5-5.4.32-20140828-070730/lib/php/extensions/no-debug-non-zts-20100525"

extension = mcrypt.so

extension = intl.so

Invincible
  • 1,418
  • 18
  • 23
0

Just open php.ini file and look around below this line: [ExtensionList]

You must see this line: extension=php_intl.dll. if not, please add it :)

  • 1
    The OP mentioned that they are not able to install or enable php_intl.dll. – Nathan Tuggy Mar 29 '15 at 03:40
  • 1. ext_intl is required for cakePHP 2. if you use PHP 5.3 or higher, php_intl.dll is existed in php install folder. 3. check your php.ini file to make sure it have the line: extension=php_intl.dll. – Leo Chau Mar 29 '15 at 12:50
0

if you have a bitnami mamp image (for Mac OS) then uncomment the php_intl.so line in php.ini instead of php_intl.dll

ChicagoSky
  • 1,290
  • 3
  • 22
  • 50
-1

Solution

  1. Open /xampp/php/php.ini
  2. Change ;extension=php_intl.dll to extension=php_intl.dll (remove the semicolon)
  3. run composer update