cakephp websocket ratchet install error -


i trying install cakephp ratchet plugin in existing project. cakephp version 2.4.3. says follow this link has following steps:

 $ cd myproject/app/  $ curl -s https://getcomposer.org/installer | php  $ php composer.phar require --no-update opauth/opauth:dev-wip/1.0 opauth/twitter:dev-     wip/1.0  $ php composer.phar config vendor-dir vendor  $ php composer.phar install 

i not familiar composer , when last step,it shows following error....

your requirements not resolved installable set of packages.  problem 1 - requested package opauth/opauth not found in version, there may typo in package name. problem 2 - requested package opauth/twitter not found in version, there may typo in package name.  potential causes: - typo in package name - package not available in stable-enough version according minimum-stability setting 

edit: composer.json this

    { "require": { "opauth/opauth": "dev-wip/1.0",     "opauth/twitter": "dev-wip/1.0" }, "config": {     "vendor-dir": "vendor" }   } 

as mentioned in comment, ratchet plugin has nothing opauth, linked article on @ ceeram.github.io should serve example on how configure composer , cakephp bootstrap.

however, composer autoloading in cakephp i'd recommend refer cakephp cookbook, if you're not including cakephp via composer:

http://book.cakephp.org/2.0/en/installation/advanced-installation.html

long story short, "getting started / 2. composer" section of plugin docs want do, require ratchet plugin, make sure vendor dir points /app/vendor/, , include composer autoloader in bootstrap.php.

composer.json (assuming it's placed in /app)

{     "require": {         "wyrihaximus/ratchet": "dev-master"     },     "config": {         "vendor-dir": "vendor"     } } 

bootstrap.php (as per cookbook)

// load composer autoload. require app . '/vendor/autoload.php';  // remove , re-prepend cakephp's autoloader composer thinks // important. // see: http://goo.gl/kkvjo7 spl_autoload_unregister(array('app', 'load')); spl_autoload_register(array('app', 'load'), true, true); 

run composer install or composer update , should good.


Comments

Popular posts from this blog

apache - Remove .php and add trailing slash in url using htaccess not loading css -

javascript - jQuery show full size image on click -