Retrieve getID(), does not work

2009-06-29 Thread Louie Miranda
$last_id = $this-Pdf-getID(); Is this the proper way of getting the latest ID on a table? (NOT after save), just want to get the latest ID. -- Louie Miranda (lmira...@gmail.com) http://www.louiemiranda.net Quality Web Hosting - www.axishift.com Pinoy Web Hosting, Web Hosting Philippines

Re: Paypal Integration

2009-06-29 Thread Vijay Kumbhar
Hello Bhushan, Please follow the following links, http://bakery.cakephp.org/articles/view/paypal-direct-payment-api-component I also used this link for the paypal integration in my project it works nice. On Mon, Jun 29, 2009 at 11:12 AM, bhushan A bhushanahir...@gmail.comwrote: Hi All,

Re: How to deploy ACL-permissions on several envirnoments?

2009-06-29 Thread Jeroen
nobody know's it? --~--~-~--~~~---~--~~ 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

Re: Problem returning array from function

2009-06-29 Thread John Andersen
Assuming you are passing an array with one ID, then if I understand your problem correctly, a parent will be read from the database and as it will not be 0, the function will enter the else statement. There is will add the parent ID to the array and then pass this array plus the parent ID via a

css sharing not working.

2009-06-29 Thread Ernesto
Hello. i'm having some troubles with css sharing. my cake folder tree looks like this cake apps app_1 webroot //note: this folder is empty app_2 webroot //note: this folder is empty shared_items views vendors css test.css

Re: Using FCKEditor in a Plugin

2009-06-29 Thread Miles J
If you are using jQuery, I highly suggest you use MarkItUp. Its about 90% lighter and easier then Tiny MCE and FCK Edit. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send

load css from a subfolder by default

2009-06-29 Thread Ernesto
Hello. is there any way to load css files from a subfolder by default? --~--~-~--~~~---~--~~ 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

'add' action and auto-setting model id

2009-06-29 Thread Raph
I have weird (I think) problem. When I've added add() action to the contoller, the id of coresponding model has been set automaticlly to add() method parameter, and when I try to save data using that action update instead of save is made. This method singature looks like this: public function

Issue in validation

2009-06-29 Thread bhushan A
Hi all, I am facing issue in displaying error message for validation. I have added following code in model var $validate = array( 'product_name' = VALID_NOT_EMPTY ); and following code in view file i.e. add.thtml ?php echo $form-input('product_name',

Re: Issue in validation

2009-06-29 Thread Vijay Kumbhar
Hello Bhushan, Cake php uses that default layout file to show the common layout.And it takes the home.ctp in pages folder. Are you using default.ctp for default layout? If not please refer that file. You can get that file in the project folder=app=views=layouts=default.ctp In default.ctp you

Re: 'add' action and auto-setting model id

2009-06-29 Thread Adam Royle
Yes, whether it is right or not, that is the way cake behaves. You should always use Model::create() before saving a new record just in case. For the extra paranoid, you can do this on your add() action: $this-Model-create($this-data, false); $this-Model-save(); The second parameter (false)

Re: 'add' action and auto-setting model id

2009-06-29 Thread Vijay Kumbhar
Hello Raph, I think you are making a mistake that you are providing a id while adding a record. If you provide the id to the save method it fires the update query. For further explanation Can you please paste the code here? On Mon, Jun 29, 2009 at 5:44 PM, Raph ra...@epoczta.pl wrote: I have

Re: load css from a subfolder by default

2009-06-29 Thread Vijay Kumbhar
Hello Ernesto, You can use the following code,if your css file is in webroot/abc/abc.css folder, $html-css('abc/abc.css'); By default cakephp searches for the css in webroot folder. So better way to store the css , js, images in the webroot folder. On Mon, Jun 29, 2009 at 5:14 PM, Ernesto

Re: Issue in validation

2009-06-29 Thread bhushan A
Yes i am using default.ctp. ?php echo $session-flash();? line is present in that file. .. I Have fount that if i will enter wrong data then after submitting form, it is not inserted in DB but not displaying error message also. Any other file which needs to be modified for this. Please guide..

bakeme tool

2009-06-29 Thread zecoelho
Hello All, I wonder if anyone can help me with the bakeme tool? I am digging around in this code for a solution to the following problem. Maybe you can help! When it comes to sorting data in the Deleted Tag, the whole page is refreshed (instead of just the table view) and as a result the

association with 'external' attribute

2009-06-29 Thread BoogieBug
Hi, Please anyone suggest me any readings about the attribute 'external' in the model association? What is the role of the 'external' attribute take in the association? I've searched through the CakePHP web site but cannot find any clue about this. Thanks.

Sitepoint tutorial with Flickr component

2009-06-29 Thread Hols Kay
Hi guys, Quite new to this - I'm doing this tutorial: http://www.sitepoint.com/article/photo-gallery-cakephp-flickr/ and I'm having issues on index.ctp. This is the troublesome code: - img id=mainimg src=?php echo

Re: 'add' action and auto-setting model id

2009-06-29 Thread Adam Royle
Hi Vijay, Have a look at the source of controller.php in constructClasses() and you will see what Ralph is experiencing. Line numbers are indicative of r8204 (current branch). line 448: $id = $this-passedArgs['0']; line 452: $this-loadModel($this-modelClass, $id); Cheers, Adam -

Re: Issue in validation

2009-06-29 Thread Vijay Kumbhar
Hello Bhushan, What type of validation you want to apply for that fileld. You are applying now only not empty validation only. So please refer the following link for further help, http://book.cakephp.org/view/125/Data-Validation On Mon, Jun 29, 2009 at 6:38 PM, bhushan A

Re: Sitepoint tutorial with Flickr component

2009-06-29 Thread Vijay Kumbhar
Hey Hols, Can you please checked printing that $photo array?? Please check that one. If that array is blank / or please check the structure of that array then it gives the error. On Mon, Jun 29, 2009 at 6:22 PM, Hols Kay hol...@googlemail.com wrote: Hi guys, Quite new to this - I'm doing

Re: Sitepoint tutorial with Flickr component

2009-06-29 Thread Hols Kay
Hi Vijay - thanks for your help! The photo array is blank while all the other key pairs are populated, and photo is the only keypair that uses an array: --- $thumbs = array( photoset = array( id =

Re: load css from a subfolder by default

2009-06-29 Thread Ernesto
hi Vijay. Thx for the response. i'm looking for a method to change the default css folder. your code surely works but that's not exactly what i'm looking for :) On 29 Giu, 15:05, Vijay Kumbhar k.vidn...@gmail.com wrote: Hello Ernesto, You can use the following code,if your css file is in

Re: How to deploy ACL-permissions on several envirnoments?

2009-06-29 Thread brian
I can't speak for others, but I don't understand the question. If you're migrating your DB from one server to the other, why wouldn't that include your ACL info? Also, why do you have 'foreign_key' = 0? How can you have 0 as a foreign key? And Guest is misspelled, btw. On Mon, Jun 29, 2009 at

Flash messages and Session Destroy

2009-06-29 Thread lordG
Hi Guys, I have a slight issue and I suspect its related to how Session- destroy works. If I destroy a session, and then set a flashmessage, it never appears or exists in the page after I redirect. For example, when a use logs out, I set a message after Session-destroy to you have been logged

Re: Sitepoint tutorial with Flickr component

2009-06-29 Thread Vijay Kumbhar
Hello Hols, hey thats good :) . Yes sure you can add that array in the main $thumbs array by using simple php function array_push(); if it not works please explain it properly. please check that one. On Mon, Jun 29, 2009 at 7:29 PM, Hols Kay hol...@googlemail.com wrote: Hi Vijay - thanks

phpThumb with Web Hosted Images

2009-06-29 Thread gbd
Hey, I'm trying to use phpThumb with web hosted images, none of the other options i.e. width/height are working. This is the relevant line in my view: img src=?php echo $html-url('/webroot/phpThumb/phpThumb.php'); ?? src=?php echo $pic_source? class=polaroid I've tried something like the

Delete current login user sessions

2009-06-29 Thread lordG
Hi Guys, Does anyone know of a method to delete/destroy any sessions created by a user when they re login? I.E. If 2 people login using the same login, the first person should get kicked out (session destroyed) when the second person logs in. From looking at the Session base class,

Re: Flash messages and Session Destroy

2009-06-29 Thread lordG
Ok, this has been fixed in the latest release 1.2.3.8166. --~--~-~--~~~---~--~~ 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,

Fieldset Issues under IE 8

2009-06-29 Thread j-rod
Does anyone know if there is a change coming in the 1.2.x or 1.3.x versions that have different handling for the fieldset with $form- create than the display: none. It just came to my attention that IE 8 running normally (not in capatability mode) is now hiding the entire form contents with this

Models and SOAP

2009-06-29 Thread RhythmicDevil
Hi, some of my application's models will use SOAP or MySQL. I am trying to figure out where to put the common SOAP stuff. User Model will use MySQL Subscriber Model will use SOAP Device Model will use SOAP In my SOAP models I need to have this: $api_config = Configure::read('API');

Re: Models and SOAP

2009-06-29 Thread Carlos Gonzalez Lavin
How about a little class hierarchy? Soap extends AppModel and Suscriber-Device extend Soap You put that in Soap's constructor and then just super() it in Suscriber-Device 2009/6/29 RhythmicDevil rhythmicde...@gmail.com Hi, some of my application's models will use SOAP or MySQL. I am trying

Simple relationship problem

2009-06-29 Thread Bryan Paddock
Heya all, Theres something I'm not doing right here... I have a User model which has one Seller model linked to it which in turn can have an Agency model linked to it. User Model: hasOne seller. Seller Model: belongsTo user Agency Model: belongsTo seller

Re: Simple relationship problem

2009-06-29 Thread Bryan Paddock
Argh.. I hate gmail shortcut keys. Anyways continuing mail: Heya all, Theres something I'm not doing right here... I have a User model which has one Seller model linked to it which in turn can have an Agency model linked to it. User Model: hasOne seller. Seller Model: belongsTo user

Re: Models and SOAP

2009-06-29 Thread RhythmicDevil
Thats what I thought too, but when I do that I get an error that the SoapModel class cannot be found. class SoapModel extends AppModel { public function __construct() { parent::__construct(); $api_config = Configure::read('API');

Tutorial won't validate

2009-06-29 Thread 0plus1
Dear cake, I'm deciding which php framework to use for a pretty big project. I'm pretty fluent with code igniter but i'm looking to switch to cake php or symphony because they are simply on another planet, features and codewise. I was following the tutorial but I've encountered a problem: the

Re: Using FCKEditor in a Plugin

2009-06-29 Thread craig.kaminsky
Thanks, so much for that tip, Miles. This is really nice and definitely lighter weight than FCK Tiny. Appreciate it! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email

Re: Simple relationship problem

2009-06-29 Thread JD Daniels
You need to look at hasAndBelongsToMany http://book.cakephp.org/view/83/hasAndBelongsToMany-HABTM Bryan Paddock wrote: Argh.. I hate gmail shortcut keys. Anyways continuing mail: Heya all, Theres something I'm not doing right here... I have a User model which has one Seller model linked

Re: 'add' action and auto-setting model id

2009-06-29 Thread Raph
Hello, I can't paste exactly the same code, but I can tell you what I want to do. In controller where I have that add() method I want to save an entry to a journal which model is in belongsTo relation with User model, so I tried to use add() method in journal's controller with user id as a

Re: Tutorial won't validate

2009-06-29 Thread mike karthauser
On 29 Jun 2009, at 14:59, 0plus1 wrote: I understand that: if ($this-Post-save($this-data)) {} but the validation section in the documentation states this command: if ($this-Post-validates()) {} this is not required if you are saving see [1] What of the two is right, can you tell me

RE: How to deploy ACL-permissions on several envirnoments?

2009-06-29 Thread Paul
of virus signature database 4197 (20090629) __ The message was checked by ESET NOD32 Antivirus. http://www.eset.com __ Information from ESET NOD32 Antivirus, version of virus signature database 4197 (20090629) __ The message was checked by ESET NOD32 Antivirus. http

return true or false

2009-06-29 Thread Dave Maharaj :: WidePixels.com
I have a function that checks if a users profile is public or private function checkPublicAccess ($profile_user_id) { // check if profile is public or private //0 = private 1 = public $params = array( 'conditions' = array('Profile.user_id' = $profile_user_id,

Time redirection in cakePHP ?

2009-06-29 Thread Techinfocomp.com
header(refresh:5; url='pagetoredirect.php'); we can use this if we want to redirect our page in 5 second , is there any way to redirect page in 5 second in cakephp ? if yes please let me know --~--~-~--~~~---~--~~ You received this message because you are

Re: 'add' action and auto-setting model id

2009-06-29 Thread Vijay Kumbhar
hello Raph, Can you please tell me is this Users controller function or Journal controllers function? Then i can provide you exact solution. On Tue, Jun 30, 2009 at 12:13 AM, Raph ra...@epoczta.pl wrote: Hello, I can't paste exactly the same code, but I can tell you what I want to do. In

Re: Time redirection in cakePHP ?

2009-06-29 Thread Miles J
You would have to use javascript or meta refresh. --~--~-~--~~~---~--~~ 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

Validate

2009-06-29 Thread Dave Maharaj :: WidePixels.com
I have created rules example: 'someRule-1' = array( 'rule' = 'alphaNumeric', 'message' = 'Only alphabets and numbers allowed', 'last' = true ), 'someRule-2' = array( 'rule' = array('minLength', '8'), 'message' = 'Minimum

cake_livesearch.zip copy?

2009-06-29 Thread Louie Miranda
Anyone who have a copy of cake_livesearch.zip? Because... http://justkez.com/wp-content/uploads/2008/04/cake_livesearch.zip Seems to be down. :( -- Louie Miranda (lmira...@gmail.com) http://www.louiemiranda.net Quality Web Hosting - www.axishift.com Pinoy Web Hosting, Web Hosting Philippines

find with unrelated model

2009-06-29 Thread Dave
I am trying to create a validation function where I check the User.slug field against a tables of banned words So if a user tries to use a slug profile it will come back invalid I have Restrictions table with all banned words which is not related to any model on the site. How do I do a query

SMTP - Not working

2009-06-29 Thread si-mon
Hi all... In my application, I need to send mails using smtp server. I have given all parameters but it is not working. Then I have tracked the errors in the email component. Then I got the following status messages: 503 AUTH command used when not advertised 550 bosauthsmtp16: No

Re: Validate

2009-06-29 Thread Miles J
Well yes you could apply them in app model. Is that your main question? --~--~-~--~~~---~--~~ 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

RE: find with unrelated model

2009-06-29 Thread Paul
on the site. How do I do a query from the users model to check restrictions table? Tried App::Import('Model', 'Restriction'); method but all i get is error - Trying to get property of non-object __ Information from ESET NOD32 Antivirus, version of virus signature database 4198 (20090629

RE: Validate

2009-06-29 Thread Dave Maharaj :: WidePixels.com
Just not sure how to go about it... How do I define them in app_model then relate them to each model when needed. -Original Message- From: Miles J [mailto:mileswjohn...@gmail.com] Sent: June-30-09 2:53 AM To: CakePHP Subject: Re: Validate Well yes you could apply them in app model.