Questions tagged [cakephp-2.5]

This tag relates to the 2.5.x branch of the CakePHP MVC framework.

CakePHP 2.5 was released on May 12, 2014.

CakePHP 2.5 is a fully API compatible upgrade from 2.4.

You should add the generic tag in addition to this one.

Useful links:

238 questions
0
votes
2 answers

CakePHP routing not work with switching language?

I have : Router::connect('/:language/:controller/:action/*', array(), array('language' => 'en|zh')); Router::connect('/:language/:controller', array('action' => 'index'), array('language' => 'en|zh')); Router::connect('/:language',…
Siemhong
  • 381
  • 1
  • 3
  • 19
0
votes
1 answer

CakePHP URLs having .html extension

We are converting an exisiting HTML site into a CMS using CakePHP. Since SEO of the site has been mapped with keywords and indexed by Google the static pages i want to have urls to have the extention .html I had a look at the Document here But am…
Harsha M V
  • 54,075
  • 125
  • 354
  • 529
0
votes
1 answer

Create log file with custom name

How to create log file with custom file name in cakephp 2.5.1. I am written following code $this->log("Data : ".print_r($this->data,true),'debug'); It create's debug.log file in tmp/log folder but when I write custom name like $this->log("Data :…
Sadikhasan
  • 18,365
  • 21
  • 80
  • 122
0
votes
1 answer

Cakephp 2.5.2 Auth always returns false

The Auth is returning false. Hashed password matches the hashed password in database, but still returns false. Here is the model: App::uses('AppModel', 'Model'); class User extends AppModel { public $validate = array( 'username'…
user1915462
  • 13
  • 2
  • 6
0
votes
2 answers

How should I declare my tree behavior in my model to preserve scope in CakePHP 2.5.x?

I'll be straightforward: I want to manage multiple (Link) trees according to their respective menu_id. As long as there is only one tree: no problem. Things get messed up when I start another tree in my link model with a different menu id. I whish…
0
votes
0 answers

Why I have to join tables using find('list')

There is a strange thing in my project. I have association like this. Novelty->belongsTo->Category And this is model: App::uses('AppModel', 'Model'); class Category extends AppModel { public $actsAs = array('Tree','Containable'); public…
Sebastian Piskorski
  • 4,026
  • 3
  • 23
  • 29
0
votes
2 answers

CakePHP Error: Plugin Migrations could not be found

I installed CakeDC Migration Plugin and trying the command cake Migrations.migration generate, but got the error Error: Plugin Migrations could not be found. The plugin installation path is app\Plugin\Migrations. I have added the path to the system…
Sithu
  • 4,752
  • 9
  • 64
  • 110
0
votes
1 answer

How to delete multi level cookie in CakePHP 2.5.3?

I have made multi level cookie like this: $cookie_data = array( 'value1' => 1, 'value2' => 2, 'value3' => array( 'value1' => 1, 'value2' => 2 ) ); $this->Cookie->write('mycookie', $cookie_data); Everything works fine…
dipo
  • 33
  • 4
0
votes
1 answer

Netbeans 8.0.1 PHPCake auto completion

I have problem with auto completion and overriding methods by inserting them. I am pretty sure that earlier on i could easily Alt+Insert methods from extended classes. Now after last update they are gone. Is any one experiencing same issue? Maybe I…
Piotr
  • 671
  • 6
  • 17
0
votes
2 answers

Only change the extension of an url, keep query-string

I have a search form, that uses get-parameters to determine what is searched and I want to have the search results as rss-feed. So I'm using the route rss-extension to have those available and want to generate a link to the rss feed for that…
Ayonix
  • 1,872
  • 1
  • 15
  • 14
0
votes
1 answer

Is there something wrong with cakephp plugin naming convention?

I'm using cakephp 2.5.4 and I tried to create a plugin named ContactManager. I created the folder ContactManager inside Plugin, than created both classes ContactManagerAppController and ContactManagerAppModel inside Plugin/ContactManager/Controller…
Ali
  • 154
  • 1
  • 5
  • 14
0
votes
2 answers

How can I run PHPUnit with CakePHP tests without the Cake console?

I want to automate CakePHP tests with Grunt, and found grunt.loadNpmTasks('grunt-phpunit');, which can automate PHPUnit, but I'm sure it can't handle cake test. I'm also satisfied with a solution that runs cake test from Grunt, but I'm really…
Tamás Barta
  • 1,617
  • 1
  • 19
  • 23
0
votes
2 answers

CakePHP $this->Auth->Login() always returning false

Been trying to figure this out for plenty of hours, but without success. $this->request->data['Login'] array contains the right username and hash which matches the entry in the database. $this->Auth->login(); is always returning false for some…
user1961685
  • 80
  • 1
  • 9
0
votes
1 answer

Paginator sort on afterFind field

I'm trying to show a list of our client's various time zones and their local time that is derived from that. Right now in my Client model I have the following function (doAfterFind) that is just a wrapper around afterFind that gives a consistent…
0
votes
1 answer

CakePHP, don't know how to select category name from table product and category

I am very new in cakephp I have two table tb_product and tb_category I want to select like sql below. How can I do it with cakephp? SQL: SELECT tb_product.id, tb_product.name, tb_category.name FROM tb_product INNER JOIN tb_category WHERE…
Siemhong
  • 381
  • 1
  • 3
  • 19