Re: How to update last login using authcomp

2010-02-06 Thread John Andersen
You are welcome :) Joh On 7 February 2010 06:24, Hussain wrote: > Thanks for you solution! It helps me a lot. > here is my solution: >function login() { >//-- code inside this function will execute only when > autoRedirect > was set to false (i.e. in a beforeFilter). >

Uploader Component

2010-02-06 Thread Dave
Does anyone know Can the uploader component upload 1 image then creates a resized version and a thumb? http://www.milesj.me/resources/script/uploader-plugin Thanks Dave Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions. You rece

Console Trouble, ACL

2010-02-06 Thread Patrick
Hello, I am new to Cake and this forum and having a lot of trouble in general but here is a specific issue I just cannot get past. I am trying to implement ACL on my site using the instructions at: http://book.cakephp.org/view/467/Defining-Permissions-Cake-s-Database-ACL I cannot do "$ cake sche

"Powered by" CakePHP logos?

2010-02-06 Thread Raven
I know this seems kind of off-topic, but I couldn't find a more appropriate place to post this. I was wondering if there were any sort of collection of CakePHP logos/banners/buttons to post on your website (besides the CakePHP | Power button found in the bottom right- hand corner of Cake's default

xml parse than modify/update and finally save

2010-02-06 Thread misterjinx
Hello, I'm trying to figure out how to modify the content of an xml document using the xml core library, but i don't succeed at appending the newly created element at the root element. First of all, I have the following structure of my xml file: A new song

Re: How to update last login using authcomp

2010-02-06 Thread John Andersen
In your login function, when you have confirmed that the user is logged in, perform a User save so that the modified field is updated, as specified in the CakePHP book at: http://book.cakephp.org/view/68/Creating-Database-Tables#created-and-modified-69 Enjoy, John On Feb 6, 2:23 pm, Hussain w

Re: urgent help

2010-02-06 Thread John Andersen
Wrong answer, sorry! Your code is wrong here: if(!empty(this->data)) should be: if(!empty($this->data)) Enjoy, John On Feb 6, 9:20 pm, John Andersen wrote: > You have to speicfy that you are using the Registration model! Add the > code: > [code] >    var $uses = array('Registration'); >

Re: urgent help

2010-02-06 Thread John Andersen
You have to speicfy that you are using the Registration model! Add the code: [code] var $uses = array('Registration'); [/code] to your controller! Enjoy ;) John On Feb 6, 10:37 am, priyanka123 wrote: > Hi.. > I need your help in cakephp.Actually i have started but get error in the > page wh

Re: friends and self HABTM

2010-02-06 Thread Foroct
Thanks John! While your example didn't exactly work it did help me figure out what to do. function addfriend($id = null) { if (!empty($this->data)) { // set user id $this->data['user_id'] = $this->Auth->user('id');

Designing a form builder - Ideas

2010-02-06 Thread @pauldatta
Hi Everyone, I am working on building a form builder module for the past three days and Ive finally reached the part that I was avoiding slightly - the form building bit :) simply cause I am yet to come up with an interesting way to do this without screwing it up. Note - I have already done the UI

How to update last login using authcomp

2010-02-06 Thread Hussain
I am currently using Auth component to login and using ACL and ARO for permission. my login function in user controller is as follows: function login() { if ($this->Session->read('Auth.User')) { $this->Session->setFlash('You are logged in!');

urgent help

2010-02-06 Thread priyanka123
Hi.. I need your help in cakephp.Actually i have started but get error in the page which is not solved by me.. Here is the code of controllers page.. set('dd',$this->Registration->find('all')); } function add() { if(!empty(this->data)) { $this->Registration

Re: friends and self HABTM

2010-02-06 Thread John Andersen
Ok, just checked with the CakePHP book again, and it is a little more complicated than just saving the data. http://book.cakephp.org/view/75/Saving-Your-Data#Saving-Related-Model-Data-HABTM-85 In the add a friend case, you are right! You have to save the information in the HABTM table yourself, so

Re: hasMany join table that stores the actual ForeignKey

2010-02-06 Thread John Andersen
Ok, I assume that you have considered your database model careful :) and based on the first post, you have the following tables (according to CakePHP conventions for naming tables): users, companies, addresses, addresses_users, addresses_companies According to the CakePHP book and information gath

localized routing prefix

2010-02-06 Thread toka...@gmail.com
Hi, I need to set up 'member' prefix for my page with its localization. So my address is now ... example.com/member/dashboard/index BUT, how can I translate the word member to other language? Let say I wish to use a spanish word 'miembro' in URL but english word 'member' as action prefix in the c