Tagged Questions
0
votes
0answers
14 views
How to store data for a form builder web application?
I'm making an app that will allow users to design their own forms. Once they have built their forms they will enter data. The forms are unique to a project, with things like users logins and groups ...
0
votes
1answer
18 views
CakePHP Using “Group By” in Virtual Field Not Working
I have the following virtual field on my Page model
function __construct($id = false, $table = null, $ds = null) {
$this->virtualFields['fans'] = 'SELECT COUNT(Favorite.id) FROM favorites AS ...
1
vote
3answers
36 views
Mysql join query on same table
I have table like
CREATE TABLE IF NOT EXISTS `categories` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`title` varchar(255) NOT NULL,
`parent_id` int(11) NOT NULL DEFAULT '0',
`status` ...
0
votes
1answer
18 views
CakePHP containable for join not searching additional table
I'm trying to join two tables and I found this post on accomplishing it using containables.
The tables I'm trying to join are orders and order_items. Here's the code in my Order and Order_Item ...
0
votes
2answers
20 views
Adding a user from index doesn't work using CakePhp
I'm using CakePhp 2.3 and am trying to allow a user to create an account from the home page. I'm new to cakephp and so far I've followed implementation described here: ...
0
votes
1answer
21 views
cakephp 1.3 : how to omit virtual fields from a find query
I'm trying to convert the output of a Model->find query into SQL to be input into a database completely separate from the current MySQL database being used by the cakePHP system. My problem is that I ...
1
vote
2answers
38 views
Can't insert multiple data against an id into multiple fields in a table in mySQL?
Scenario: I have a form in my PHP page, inserting data into mySQL database.
Suppose, to each types of T-shirt, there are color variations, size variations and others like this. So in my database, I ...
0
votes
0answers
45 views
PHP Framework - Need to create Facebook type Web and mobile app [closed]
I am new bee in PHP, As of now i have in a confusion which framework should I used for my project.
Below are the basic requirement for my project. (The app is just look like Facebook)
Minimum 2 ...
0
votes
1answer
28 views
CakePHP skipping over field in select * statement
First of all, I just want to say that I understand not using CakePHP's built in functionality to find data can result in vulnerabilities. However, there is absolutely no input going into this query ...
0
votes
2answers
22 views
cakePHP: updating mysql table using WHERE clause with multiple conditions
I want to write this SQL statement in cakePHP syntax:
UPDATE students SET status = 'graduated' WHERE age = '23' AND major = 'math';
Now, the way I am trying to do this in cake is
...
1
vote
2answers
32 views
CakePHP SQL conversion - basic ORDER BY
I have a table where I'd like to get all id's that equal 26 first, then have the rest sorted in descending order, so something like:
row id
--- --
1 26
2 26
3 26
4 27
5 ...
-2
votes
1answer
44 views
How to define a variable inside $_GET in php
<?php
$var = "sub";
echo $_GET['{$var}'];
?>
i want this working when i called mydomain.com?sub=hii .
is there any other way to make this work?
I want to use random $var value from my ...
3
votes
1answer
31 views
CakePHP returning multiple records from a habtm
I have a habtm relation between questions and categories. This habtm relation is standard and setup in the respective models. I now have the following issue. In a controller action I have an array of ...
0
votes
1answer
27 views
CakePHP hasOne belongsTo relationship, edit/add same action
Using CakePHP 2.3. I am creating an application in which there is a Users table and a Profiles table. The association is like this: User hasOne Profile / Profile belongsTo User.
However, I would not ...
0
votes
1answer
32 views
Column not found: 1054 Unknown column 'Comment.deferred_id' in 'field list'
So I am pretty new to this and I am creating a web application with Cakephp framework and a MySQL database. I had a column in my "Comment" table called deferred_id which referenced the id in my ...