Re: CakePHP 3 - Where is custom datasource ?

2015-09-06 Thread Rahul Singh
Salines  writes:

> 
> 
> 
> Hi,
> 
> I have a large number of CakePHP 2 web applications, many of them use 
remote data over the DataSource. I'm reading the documentation of CakePHP 
3, but I can not find instructions for remote datesource.
> 
> My next project also requires a custom DataSource (ArangoDB), so I 
planned to build it with the new version of CakePHP.
> 
> Please do specify where and how to build a DataSource in CakePHP 3.
> 
> Thank You.
> 
> 
> 
> 


I needed the custom datasources too, so I created a ArangoModel for 
CakaPHP 3.x check the repo.

https://github.com/raulsi/CakePHP-ArangoDb.git



-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


I want to prevent users to access other users data. Now I am trying using isAuthorized() function, but not working. Getting '$controller does not implement an isAuthorized() method" error.

2014-03-25 Thread Rahul Dhavale
In app controller added '$this->Auth->authorize = 'Controller';' in before 
filter and added public function isAuthorized() {} function in users 
controller. I don't want to use ACL. 
e.g If logged in users edit profile url is 
http://localhost/abc/users/edit/1 then I want to prevent to acces 
users/edit/2 data. Please help me.

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Exists a Ticket System made in CakePHP

2013-11-18 Thread Rahul Dhavale
I want same. Is there any?

On Tuesday, April 21, 2009 2:29:19 PM UTC+5:30, byqsri wrote:
>
> I have my web application in Cakephp. 
> It has his registered users . 
> Now I would add a ticket system on my application only for registered 
> users. 
> I have searched a ticket system made in Cakephp but I haven't found 
> anything. 
> Is there someone that has found something made in Cakephp? 
> Thanks

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/groups/opt_out.


Cakephp Manual Auth login returns true, but not logged in another page

2013-06-21 Thread Rahul Reddy
In my cakephp(v 2.3.4) app, I am using the code below to manually login 
users after they register, as provided in the 
manual
.

if ($this->User->save($this->request->data)) {
$id = $this->User->id;
$this->request->data['User'] = 
array_merge($this->request->data['User'], array('id' => $id));
if($this->Auth->login($this->request->data['User'])) {
  $this->redirect('/homepage');
}
}

I am getting the $this->Auth->login($this->request->data['User']) response 
as true and it is getting redirected to the home page. But the user is not 
logged in homepage (or in any other page). Please help me in fixing this. 
Thanks in advance.

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/groups/opt_out.




Re: Urgently Require Cakephp developer

2012-08-11 Thread Rahul
Thanks for all the guys who applied , the requirement got filled now.

Thanks,

On Friday, August 10, 2012 11:00:08 PM UTC+5:30, Rahul wrote:
>
> Hi,
>
> I am looking for Cakephp developer preferably from India with 2 yrs exp 
> range.
>
> I have a long term project and handsome budget :)
> Please send me your cv at ra...@zimaudio.com.
>
> Thanks,
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en-US.




Urgently Require Cakephp developer

2012-08-10 Thread Rahul
Hi,

I am looking for Cakephp developer preferably from India with 2 yrs exp 
range.

I have a long term project and handsome budget :)
Please send me your cv at ra...@zimaudio.com.

Thanks,

-- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en-US.




gebo admin template

2012-08-10 Thread Rahul
Hi,

I am looking for some help to setup gebo admin template for my project, 
please share any useful links/info  .

gebo admin template is the paid one and help is required to port that in  
cakephp.

Thanks,

-- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en-US.




Re: how images stored in database

2012-08-01 Thread rahul
Hi abiram.
I want to store and retrieve image in database but i cant bcoz i am new to 
cakephp.
Can you help me.I am doing like this:
To upload an image i m doing this
Form->create('Movie');
echo $this->Form->inputs(array('title', 'genre', 'rating', 'format', 
'length'));
echo $this->Form->input('file', array('type' => 'file'));
echo $this->Form->end('Add');
?>
and to show image i m doing like this:
Html->image($movie['Movie']['image']); ?>

Am i doing in right way.

On Tuesday, February 12, 2008 3:46:12 PM UTC+5:30, abiram wrote:
>
> Hai i got answer it is images stored in database lke varchar and 
> retrive time this is like image()  ?> 
>
> On Feb 11, 2:39 pm, abiram  wrote: 
> > Hi all i want store images in database actually images stored in 
> > webroot img folder in database image path is entering it means only 
> > img names or overall path and how to retrive viewpage like 
> >  
> > and what path is save in database pls send answ

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php


Re: How to upload and retrieve an image from databse/dir?

2012-08-01 Thread rahul
Thanks nikhil for your quick reply.
Would you mind telling me how to save images inside directory?

On Wednesday, August 1, 2012 12:15:36 PM UTC+5:30, Nikhil Agrawal wrote:
>
> It will be better if you can save the image inside  *app/webroot/image/ 
> *folder 
> rather than saving the images in database . In datatbase you can save the 
> name of images .
>
> If you will be saving it in database you have to worry the type of image 
> and the size of image will can make the database huge.
> But, if you want to save it in database follow this link:
>
> http://vikasmahajan.wordpress.com/2010/07/07/inserting-and-displaying-images-in-mysql-using-php/
>
> On Tue, Jul 31, 2012 at 10:16 PM, rahul wrote:
>
>> Hi i am new to cakephp.I have created a registration form and i want when 
>> i fill this form and select
>> an image for a person i can save information with image in database.After 
>> saving information i will
>> be able to view that information along with that image.
>>
>> Can anyone help me?
>>
>> -- 
>> Our newest site for the community: CakePHP Video Tutorials 
>> http://tv.cakephp.org 
>> Check out the new CakePHP Questions site http://ask.cakephp.org and help 
>> others with their CakePHP related questions.
>>  
>>  
>>
>>
>

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php


How to upload and retrieve an image from databse/dir?

2012-07-31 Thread rahul
Hi i am new to cakephp.I have created a registration form and i want when i 
fill this form and select
an image for a person i can save information with image in database.After 
saving information i will
be able to view that information along with that image.

Can anyone help me?

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php


Re: Please help me! almost got crazy...with Tree behavior..

2011-01-31 Thread rahul jeevan
hi

wat is the actual problem

On Mon, Jan 31, 2011 at 11:15 AM, Jeremy Burns | Class Outfit <
jeremybu...@classoutfit.com> wrote:

> He had $actAs instead of $actsAs, so the behaviour wasn't loading. It's a
> common mistake.
>
>
> Jeremy Burns
> *Class Outfit*
> *
> *
> jeremybu...@classoutfit.com 
> http://www.classoutfit.com
>
> On 29 Jan 2011, at 11:59, satya prakash wrote:
>
> YOU ARE CHECH IN MODEL QUERYES AND CHECK SYNTAX ; OR ' OR " . THESE SOULD
> BE CHECK
>
> --
> Our newest site for the community: CakePHP Video Tutorials
> http://tv.cakephp.org
> Check out the new CakePHP Questions site http://ask.cakephp.org and help
> others with their CakePHP related questions.
>
>
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com For more options, visit this group
> at http://groups.google.com/group/cake-php
>
>
>  --
> Our newest site for the community: CakePHP Video Tutorials
> http://tv.cakephp.org
> Check out the new CakePHP Questions site http://ask.cakephp.org and help
> others with their CakePHP related questions.
>
>
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.comFor
>  more options, visit this group at
> http://groups.google.com/group/cake-php
>



-- 
rahul

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php


using cakephp for social webapp

2010-05-29 Thread Rahul R
helo everyone ,
I am newbie to cakephp .  i am trying to implement an interaction platform
between alumnis and students of my college . i coded significantly in php
and javascript , but couldnt come up with a channel concept. where is i
have  channels for every alumni not student , so that they can be asked
various questions in that particular channels . (similar to forum but not
exactly like that) . i would be glad i f you could help me getting started
with this using cakephp.


Thanking You

Rahul

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en


Editing/delete multiple records

2010-01-07 Thread rahul jain
Hi All

I am new to cakephp.
I am displaying list of categories along with check box placed next to
each category.
Now I want to edit/delete only those categories if the check box is
checked.
How can I achieve this in cakephp.
I will highly appreciate the help.

Thanks and Regards
Rahul Jain
Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en


Editing/delete multiple records

2010-01-06 Thread rahul jain
Hi All

I am new to cakephp.
I am displaying list of categories along with check box placed next to each
category.
Now I want to edit/delete only those categories if the check box is checked.

How can I achieve this in cakephp.
I will highly appreciate the help.

Thanks and Regards
Rahul Jain
Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en


Urgent help needed

2009-08-02 Thread Rahul
  'fldRemarks' => array('type' => 'string', 'length' => 
8),
'fldEmail' => array('type' => 'string', 'length' => 8),
'fldWebUrl' => array('type' => 'string', 'length' => 12)
);
}


function __get_users_norole($user_id)
{
  $ret = $this->query("SELECT id FROM user_roles
   WHERE user_id = '$user_id'");

  if( $ret[0]['user_roles']['id'] == '' )
{
 $user_list = $this->query("SELECT * 
FROM companies
   WHERE id = '$user_id'");
 return $user_list;

}

  return ;
}

function __assign_user_role($user_id,$role_id)
{
  $ret = $this->query("INSERT INTO user_roles(user_id,role_id) VALUES
('$user_id','$role_id')");
  return ;
}



}

?>

view




Please fill all the required fields.
flash() ;?>



create(null, array('action' => 
'user_register')); ?
>


Company Name
*


text('fldCompanyName'); ?>





Contact Person
*


text('fldContactPerson'); ?>






Company Password *


text('fldCompanyPass'); ?>




Confirm Password *


text('fldCompanyPassC'); ?>




Contact Person *


text('fldContactPerson'); ?>






Email address *


text('fldEmail'); ?>






Address*


textarea('fldAddress'); ?>




Phone*


text('fldPhone'); ?>




Mobile*


text('fldMobile'); ?>




Fax*


text('fldFax'); ?>




CST No*


    text('fldCSTNo'); ?>




TIN No*


text('fldTINNo'); ?>




Remarks*


text('fldRemarks'); ?>




WebSite*


text('fldWebUrl'); ?>




submit(); ?>



end(); ?>

 
 
 
 
 
 
 


 


Available Options

Add New Access
Details
View Access Details
Edit/Delete Access
Details


 










thanks ,
Rahul

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Web Service

2009-04-23 Thread Rahul Sinhaa

Hello guys ,

We have to start a new project using cake php framework.
The project is related to WEB Services.

We have to create a WEB SERVICE -server , I want you guys to help me
deciding on the WEB SERVICE method (SOAP, REST ..) since I am not sure
that which method will be the best match for CAKE PHP and their
limitations also.

Thanks in advance

-Rahul

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Paginate on Batch which hasMany Job which belongsTo Package

2008-07-25 Thread Rahul J

Hi Guys,

My problem here is performance. $this->Batch->paginate() runs just
fine, except when there are 100K Jobs.
I have tried unbinding and then binding Batch with hasOne Job, that
doesnt solve it either.
I need to go from Batch -> Job -> Package.

I'm using 1.2.0.6311 beta

Dire need of help.

Thanks!

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: How to extend CakePHP Debugger class

2008-06-18 Thread Rahul J

:(
I'll simplify: I want to have the ability to CATCH sql errors (in my
error handler) irrespective of DEBUG levels.
Currently the only way this happens is in showQuery (trigger_error in
dbo_source.php) and that too when DEBUG > 1. This is my opinion should
be triggered along with rest of PHP errors ie. >= 1

Can I overload/override any lib functions or classes in order to
achieve this. Please help!

Rahul J


On Jun 17, 2:50 pm, Rahul J <[EMAIL PROTECTED]> wrote:
> Because I want to implement my own custom PHP error handling.
> As an example, I want to be able to create different output when
> DEBUG=0,1,2 or 3.
> Currently when DEBUG=0, my custom error handler is not called at all.
> The operation stops in cake libs and is not allowed a chance in app.
>
> Rahul J
>
> On Jun 16, 10:16 pm, AD7six <[EMAIL PROTECTED]> wrote:
>
> > On Jun 16, 4:06 pm, Rahul J <[EMAIL PROTECTED]> wrote:
>
> > > Hi,
>
> > > I am trying to extend Debugger class (cake/libs/debugger.php) in my
> > > app directory in similar way as AppModel/Controller.
>
> > > class AppDebugger extends Debugger
>
> > > I've even tried renaming the file debugger.php and app_debugger.php
> > > but without luck. Its not working!
>
> > > I guess its something to do with the way Debugger methods are
> > > "invoked" statically, though I'm not sure about this.
> > > Can someone please enlighten me and tell me how to do this?
>
> > > Thanks!
>
> > Why do you want to do that?
>
> > AD

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: How to extend CakePHP Debugger class

2008-06-17 Thread Rahul J

Because I want to implement my own custom PHP error handling.
As an example, I want to be able to create different output when
DEBUG=0,1,2 or 3.
Currently when DEBUG=0, my custom error handler is not called at all.
The operation stops in cake libs and is not allowed a chance in app.

Rahul J

On Jun 16, 10:16 pm, AD7six <[EMAIL PROTECTED]> wrote:
> On Jun 16, 4:06 pm, Rahul J <[EMAIL PROTECTED]> wrote:
>
> > Hi,
>
> > I am trying to extend Debugger class (cake/libs/debugger.php) in my
> > app directory in similar way as AppModel/Controller.
>
> > class AppDebugger extends Debugger
>
> > I've even tried renaming the file debugger.php and app_debugger.php
> > but without luck. Its not working!
>
> > I guess its something to do with the way Debugger methods are
> > "invoked" statically, though I'm not sure about this.
> > Can someone please enlighten me and tell me how to do this?
>
> > Thanks!
>
> Why do you want to do that?
>
> AD

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



How to extend CakePHP Debugger class

2008-06-16 Thread Rahul J

Hi,

I am trying to extend Debugger class (cake/libs/debugger.php) in my
app directory in similar way as AppModel/Controller.

class AppDebugger extends Debugger

I've even tried renaming the file debugger.php and app_debugger.php
but without luck. Its not working!

I guess its something to do with the way Debugger methods are
"invoked" statically, though I'm not sure about this.
Can someone please enlighten me and tell me how to do this?

Thanks!

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: Calling MySQL5 Stored Procedures

2007-11-01 Thread Rahul

Hi

I haven't used stored procedure yet. But can we try this in cases
1. when stored procedure returns some value
$result = $this->Model->query("CALL 'stored-procedure-name'");
2. when stored procedure doesn't return any value
$this->Model->execute("CALL 'stored procedure name'");

Let me know weather it works..

Regards

On Oct 16, 8:11 pm, cmbg <[EMAIL PROTECTED]> wrote:
> Hi all,
>
> Just thought I'd post my workaround based on some of the posts here
> but I didn't see a consistent answer to the issue.  My environment is
> PHP 5.2.3, Apache 2.2.6, and MySQL 5.0.41-community.
>
> So, here's the problem, I have a stored procedure that I want to call
> in Cake.  When I try to run the $this->model->query("call
> sp_mine(params)"); or  $this->model->_call, I don't get anything back
> and an mysql error occurs.
>
>Error 1312 - PROCEDURE <...> can't return a result set in the given
> context: nothing returned
>
> To resolve this, I had to modify the connect call to the database in
> dbo_mysql.php to include a client flag, specifically
> CLIENT_MULTI_RESULTS or CLIENT_MULTI_STATEMENTS or 65536.  But after
> implementing this and calling my stored procedure I go another mysql
> error:
>
>   Error 2014 - Commands out of sync; you can't run this command now
>
> I get this for any query or execute that I attempt to call.  And per a
> post from blunt, I added this function
>
> function releaseDB() {
>  $db =& ConnectionManager::getDataSource($this->useDbConfig);
>  $db->disconnect();
>  $db->connect();
> }
>
> to my model_php5.php.  After every sp call, I call that method.
>
> If anyone has a better resolution or if it's fixed in the current cake
> version and I'm not doing something right, then let me know. :P
>
> Thanks,
> Beverly


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



How can I post a form to different controller/actions if the form has two submit buttons

2007-10-25 Thread Rahul



Hi
I am working on a Animal Inventory System.
In a particular area of my application, I have a form with two submit
buttons say one for "Flag" and other for "Delete".
My problem is - "I have to post the form along with its data to the
flag action of say Animal controller when the user clicks the "Flag"
submit button (after checking one or more animals from a DB populated
list).
Similarly I want to post the same form to the Animals/delete action
when the user clicks the "delete" submit button after checking one or
more animals from a DB populated list.

So how can I post the same form to different controller/actions
according to the click operation of respective submit button, if it
has two or more submit buttons.

Please, if Can anyone help me out of this problem..

Regards
Rahul


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



duplicate foreign key

2007-09-13 Thread Rahul

I have one table for say Record. I need to maintain two foreign key
say User_id for this record table. One user_id will hold the id of the
user who will create that record and another user_id will hold that
user id who will last modify the record.

In this case, record table must have two HasMany relationship with
another table say User.

How cake will handle this situation  whereas my MySql does not
support duplicate columns..


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: How I can create two instances in Cake?

2007-09-05 Thread Rahul

Hey Ketan Thanx yaa...

I am finally succeed to create two instances in single cake...

what I did is simple...first I have create two virtual hosts for each
application..[The term Virtual Host refers to the practice of
maintaining more than one server on one machine, as differentiated by
their apparent hostname.]...

then i have defined the DocumentRoots of each application in the two
Virtual Hosts..

the rest are simple

http://project1 will lead us to first project and
and
http://project2 will lead us to the second

thanx..


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: How I can create two instances in Cake?

2007-08-14 Thread Rahul

Thanx Ketan

Well I had done exactly what U have said. My question is beyond that
work. I need to redirect my browser to these two different
applications by say http://localhost/project1 for the first
application and http://localhost/project2 fro the second application..

Hope U understand what I mean to say..

Regards
Rahul


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



How I can create two instances in Cake?

2007-08-14 Thread Rahul

Hi

Suppose I have to do two different project in a single Cake
environment.
Then what modifications are needed ..
..and where these modifications should be...
..if I want to create two different instances in one CakePHP
framework.
Please help me out of this issue...!!
I dont want to change the "documentroot" or the .htaccess file each
and every time.
What I need to do is just type
http://localhost/project1 for the first one and
http://localhost/project1 for the 2nd

Regards
Rahul


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: Undefined index: Language in filtr_lang.thtml

2007-08-08 Thread Rahul
Try using

var recursive=3 in your model..



On 8/8/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
>
> Hello
>
> I want to filter my view by passing a language_id in the view.
> ( Subcategory can have many categories , category can have many
> languages )
>
> Does anyone know why i getting this error?
>
> ---
> ERROR:
>
> Notice: Undefined index: Language in C:\wamp\www\inz_cake\app\views
> \subcategories\filtr_lang.thtml on line 19
>
> -
> Controler
>
> class SubcategoriesController extends AppController {
> var $name = 'Subcategories';
> var $uses = array('Subcategory' , 'Category' , 'Language' ,
> 'Menu');
>
> function filtr_lang($id = null)
> {
> $this->set('filtr_langs', $this->Subcategory-
> >findAll(array('Category.language_id' =>$id )));
> }
>
> }
> 
> filtr_lang.thtml
>
> 
>   
> 
>
> --
> MODEL CATEGORY
>
> class Category extends AppModel {
> var $belongsTo = array(
> 'Menu' => array(
> 'className' => 'Menu',
> 'foreignKey' => 'menu_id'
> ),
> 'Language' => array(
> 'className' => 'Language',
> 'foreignKey' => 'language_id'
> )
> );
> var $hasMany = array(
> 'Subcategory' => array(
> 'className' => 'Subcategory',
> 'foreignKey' => 'category_id'
> )
> );
> }
>
> -
> MODEL SUBCATEGORY
>
> class Subcategory extends AppModel {
>
> var $belongsTo = array(
> 'Category' => array(
> 'className' => 'Category',
> 'foreignKey' => 'category_id'
> )
> );
>
> ---
>
> MODEL LANGUAGE
>
> class Language extends AppModel {
>
> var $hasMany = array(
> 'Category' => array(
> 'className' => 'Category',
> 'foreignKey' => 'language_id'
> )
> );
>
> --
>
> Please help
>
> Stanley
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---