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
1 answer

CakePHP 2.5.1 Number helper does not show currency symbol 'after'

I tried to set up a number format for living space in Cakephp, it should look like this: "100,00 m²" As I use this format often, I want to create a default format in my AppController beforeFilter(): CakeNumber::addFormat('AREA', array( …
Clausi
  • 28
  • 6
0
votes
0 answers

php url encode still being read as url not a string when being sent as a parameter

I have a folder outside of the webfoot and I am using the $this->response->file($path); to display the images inside. My controller code works fine when I just pass in the file name. But I need to pass it in as a part URL. This is where it breaks. I…
Keith Power
  • 13,891
  • 22
  • 66
  • 135
0
votes
1 answer

Search box with autocomplete at a view

I'm new to cakephp, I have followed a tutorial to implement search box with autocomplete and all went well, the search box at the View/Pages/home.ctp works as expected, but I really need to put that search box at my View/Terms/index.ctp, and I can…
Andrés Chandía
  • 999
  • 1
  • 16
  • 32
0
votes
1 answer

In CakePHP am getting this error: "Fixture invalid: Count of fields does not match count of values"

When I am running test cases I am getting the above error: "Fixture invalid: Count of fields does not match count of values". Can anyone say why I would be getting that? And how to fix it? I must note that for my fixtures, I am automatically…
antoniovassell
  • 1,012
  • 14
  • 24
0
votes
1 answer

cakephp foreach on find and the saveAll

When a user looks at their messages I wish to update each message to READ. I do this by setting the read field to 1/true. The saveAll does not seems to update the records after my find. I am not sure is the problem with my foreach loop or saveAll, I…
Keith Power
  • 13,891
  • 22
  • 66
  • 135
0
votes
1 answer

cakedc user plugin user_details

I am using CakeDC user plugin with cakephp 2.5. I see that it includes a user_details table. I want this use this table to store the full name of the user among other details. I have added a new entry into the user_details table with the correct…
Keith Power
  • 13,891
  • 22
  • 66
  • 135
-1
votes
1 answer

Getting null when using getLastInsertID in cakephp2.10

Getting empty value when calling getLastInsertID() in cakephp2.10 Mycode is $this->query("INSERT INTO $savedtbl(ref_name,productdetails_id,users_id,type,image,saved_date,template_name)…
Shamon S
  • 135
  • 1
  • 10
-1
votes
1 answer

cakephp pagination with complex query

I have a database structure given below id | Title | brand | ---+---------+-------+ 1 |product1 | Lg | 2 |pruduct2 | Lg | 3 |pruduct3 | Lg | 4 |pruduct4 | Lg | 5 |pruduct5 | Lg | 6 |pruduct6 |samsung| 7 |pruduct7 |samsung| 8…
Krishna
  • 1,540
  • 2
  • 11
  • 25
-1
votes
3 answers

CakePHP Controller Method Variables

I am trying to define a variable that will pass into the Action of a Controller as follows public function index($branch = null) { //padmanabha-nagar //jp-nagar $branch = "padmanabha-nagar"; …
Harsha M V
  • 54,075
  • 125
  • 354
  • 529
-1
votes
1 answer

Why $this->Agreement->save($data); not write data to DB?

This is my function Add in Payment Controller. It writes to Payments table, reads from Agreements but do not update Agreements. Why? public function add( $agreement_id = null ) { if ($this->request->is('post')) { …
tomas3man
  • 29
  • 7
-1
votes
1 answer

Paginate do not sort DESC

I can't display Agreements with agreement_number less than 7 and order it by agreement_number DESC. I have read Pagination CakePHP Cook Book and can't find where my code is wrong. It display only less than 7, but always ASC. I have found similar…
tomas3man
  • 29
  • 7
-3
votes
1 answer

Initialize PDF.js in website

I am trying to integrate PDF.js in my website, but am unable to get it done correctly. This is what the screen shows: I can not see the PDF file on the screen, but when I press Print, the print menu does show the PDF file in it. Other functionality…
Parixit
  • 3,829
  • 3
  • 37
  • 61
-3
votes
2 answers

Undefined Variable in Element View

I am using cakephp 2.5, why am I getting an error while trying to echo the content of an Element in another view. the error says Notice (8): Undefined variable: job [APP\View\Elements\latestjobs.ctp, line 9]
1 2 3
15
16