Re: ACL per record

2007-11-07 Thread francky06l
Check on the Bakery, there is a tutorial for Auth and ACL that covers your need. Well ACL should be quite fast even with thousands of record, but really never tried yet on such volume. On Nov 8, 3:14 am, HR <[EMAIL PROTECTED]> wrote: > Hello every one, > > I've searched how to use the ACL compone

$form->checkbox having troubles.

2007-11-07 Thread maschoen
I'm using version 1.2.0.5427alpha, and I'm seeing very weird output from $form->checkbox(). My code looks like: $name="Model.field'; echo $form->checkbox($name,array('label'=>false,'div'=>false,'value'=> $somevalue); The output is something like: I don't know where to begin with this. Why

Re: Using models with plugins in CakePHP 1.2

2007-11-07 Thread rtconner
I think you have to do.. $uses = array('Pluginname.Modelname'); On Nov 7, 10:54 pm, Aaron Shafovaloff <[EMAIL PROTECTED]> wrote: > I have a plugin which has two models of its own. I've followed the > directions to creating a plugin to the T. > > In the plugin's own app_controller file I have th

Using models with plugins in CakePHP 1.2

2007-11-07 Thread Aaron Shafovaloff
I have a plugin which has two models of its own. I've followed the directions to creating a plugin to the T. In the plugin's own app_controller file I have the following: class PluginNameAppController extends AppController ... This creates a problem. The main AppController file "uses" some mode

Re: Simplest usage of the new Auth component?

2007-11-07 Thread Paolo Stancato
I am having troubles with Auth component too (but after the login step). My code is very similar, except that I'm using in AppController: function isAuthorized() { // This should authorize any controller/action, even if I'm not logged in, right? return true; } But when I try to access to a

Simplest usage of the new Auth component?

2007-11-07 Thread Arne-Kolja Bachstein
Hi there, I tried to implement a simple authentication using the new Auth component from CakePHP 1.2, but did not succeed. Maybe there's someone who can give me quick and dirty assistance with this? My goal is to implement the authentication basics directly into /app/ app_controller.php rather t

Re: I want gData

2007-11-07 Thread Mr-Yellow
Zend seems like a mess to me -Ben On Nov 7, 8:46 pm, "Mikee Freedom" <[EMAIL PROTECTED]> wrote: > You can incorporate the Zend framework in to your application : > > http://www.google.co.uk/search?q=cakephp+zend+framework&ie=utf-8&oe=u... > > On 07/11/2007, keymaster <[EMAIL PROTECTED]>

ACL per record

2007-11-07 Thread HR
Hello every one, I've searched how to use the ACL component of CakePHP 1.2 on "per record" situations on all places. Let me exemplify: We have a Message! Only the Author or an Admin can edit its data. How can we archive this using ACL? Is it fast on a thousands records situation? Thank you so

Re: Add Syntax Coloring to .thtml files with JEdit?

2007-11-07 Thread Robert Sosinski
Hello Wayne, I have the latest version of JEdit (4.3pre11) and now have PHPParser installed, however I still have no syntax coloring with .thtml files. Have any other ideas? Thanks a bunch! On Nov 6, 11:54 am, "Wayne Fay" <[EMAIL PROTECTED]> wrote: > You may need to add/install the PHPParser pl

Re: What does findAll return when there is a DB error?

2007-11-07 Thread Samuel DeVore
findall used to just return 'false' On 11/7/07, MikeK <[EMAIL PROTECTED]> wrote: > > And its a paginate call, not a findAll if that makes any difference... > > > > > -- (the old fart) the advice is free, the lack of crankiness will cost you - its a fine line between a real question and an idi

CakePHP API for CakePHP 1.1 and 1.2

2007-11-07 Thread Gustavo Carreno
Hey bakers/padeiros, [en] Just released the HTML(.zip) and CHM files for the API: 1.2 is from last pre-beta launch. (http://cakeforge.org/frs/?group_id=53&release_id=352) 1.1 is from last stable trunk launch. (http://cakeforge.org/frs/?group_id=53&release_id=353) [pt] Acabei de publicar os fiche

Re: Multiple validation on a single field - CakePHP 1.1.17

2007-11-07 Thread Rajesh
Thanks all for replying. It worked. --~--~-~--~~~---~--~~ 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 [EMA

Google Bots geenrating weird queries

2007-11-07 Thread MikeK
I am tracking some strange errors that showed in my logs and in the process have stumbled onto some weird requests by google bots of my cake app. They are throwing all kinds of urls together with invalid parameters that aren't even links on my published pages. What's their deal? --~--~-~

problem with 1.2 __() function

2007-11-07 Thread sdc53
In my baked view/edit/index screens, the __() internationalization function is used with values coming from the DB inside $html->link. For example: echo $html->link(__($placement['Status']['status'], true), array('controller'=> 'statuses', 'action'=>'view', $placement['Status'] ['id'])); when the

Re: What does findAll return when there is a DB error?

2007-11-07 Thread MikeK
And its a paginate call, not a findAll if that makes any difference... --~--~-~--~~~---~--~~ 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

Re: What does findAll return when there is a DB error?

2007-11-07 Thread MikeK
I am asking because on a query that has an ambiguity warning logged into my error.log, there is always a subsequent log entry at the same time as if my view operated on the output of findAll/paginate as if it were not false. For example: $records = $this->findAll()... $this->set('records', $recor

What does findAll return when there is a DB error?

2007-11-07 Thread MikeK
Can someone please tell me what findAll returns when there is a mysql db error as a result of malformed query? It returns nothing when it finds nothing, but what does it return on error? --~--~-~--~~~---~--~~ You received this message because you are subscribed t

Re: shopping cart

2007-11-07 Thread Juan Basso
Why not shopping cart IN cake? http://cakeforge.org/projects/bakesale/ Juan Basso On 6 nov, 15:04, carSign <[EMAIL PROTECTED]> wrote: > Has anyone been able to integrate a third party shopping cart into > cake? --~--~-~--~~~---~--~~ You received this message be

Again Auth+ACL. Need help for actions type

2007-11-07 Thread VolCh
I try to work with Auth+ACL in 1.2. I understand how to work Auth with other types of authorizations. But with 'actions ' types (other than simple CRUD) - I can't. :( For example: I have a contoller 'photos' with 'index','view','full_view', 'add', 'edit', 'enable', 'disable' and 'delete', 'add_co

need to write error.log in ShowQuery or LogQuery dbosource.php

2007-11-07 Thread MikeK
I need some guru help -- if there's an easier way please tell me. I have a MySQL ambiguity bug in a query -- I thought I had nailed all these issues but I saw one in my error log and need to pinpoint the query that is actually causing it. It has to do with something in some convoluted pagination s

working with: tablename_id as the name of the primarykey

2007-11-07 Thread [EMAIL PROTECTED]
Hello Community, i am doing my first steps here with cake. I already have a database and i want to add websites for edit update delete / view of the tables. The index() method already works fine, you can see it here: http://itimarketing.dyndns.org/website/destinations/ The problem is, that when

Re: YAMMY!: feed your migrations faster

2007-11-07 Thread cakeFreak
Whell you can type: >cake yammy all And YAMMY generates a schema with ALL tables! It does not take into account changes, namely the generated schema does not write down just changes (as subversion does with files), but at list you have all modification. Hypothesis: 1) you have a DB schema and

Re: Admin Main page, routing and Routing.admin benefits

2007-11-07 Thread cakeFreak
I found the solution yesterday with regard to admin routing: You need to pass a parameter: 'admin'='1' EXAMPLE (config/routes.php): Router::connect('/', array('controller' => 'home', 'action' => 'index', 'admin' => '1')); -

Re: YAMMY!: feed your migrations faster

2007-11-07 Thread cakeFreak
HEy Evgeny, what do you mean here? To add comments to the schema generated by YAMMY? Dan On 7 Nov, 08:27, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > Really usefull for next version is implement short YAML field > decription syntax that appear in 3.3 version and only it work with > add_fil

Re: YAMMY!: feed your migrations faster

2007-11-07 Thread jarmstrong
I just realized i might have said yammy when i really meant migrations. jarmstrong wrote: > > Gwoo, > > i understand the shell handling. I was asking more for an automated > application based update to the schema when the app notices that the DB it > is pointed at is out of date. For instanc

Re: YAMMY!: feed your migrations faster

2007-11-07 Thread jarmstrong
Gwoo, i understand the shell handling. I was asking more for an automated application based update to the schema when the app notices that the DB it is pointed at is out of date. For instance, new version is developed, tests are run, staging is approved. Then when it is migrated from dev->stagin

Re: YAMMY!: feed your migrations faster

2007-11-07 Thread Gwoo
The SchemaShell handles full schema versioning. run: cake schema help --~--~-~--~~~---~--~~ 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 f

Re: YAMMY!: feed your migrations faster

2007-11-07 Thread jarmstrong
Speaking of future enhancements. Is there a current feature or easy way to add in handling that will generate the entire schema from version X to Y or simply do the update the first time the app is run against a schema that is out of date or doesnt have any tables? I have seen this in some other

Re: Admin Main page, routing and Routing.admin benefits

2007-11-07 Thread [EMAIL PROTECTED]
I've been fighting with this today as well. I have a route set up: Router::connect('/admin', array('controller' => 'pages', 'action' =>'index', 'prefix' => Configure::Read('Routing.admin'))); Which gets me to the admin main page. However $html->link() doesn't recognize that you're currently in

Re: How delete selected checkboxes?

2007-11-07 Thread francky06l
Best is to make a form, with your check boxes in .. When the form is submitted to get the data to the usual way ($this->data). You might have to trick the name of the field ie : $form->input('Model/ field]['.$id, array('type' => 'checkbox')), then you will receive an array $this->data['Model']['fi

How delete selected checkboxes?

2007-11-07 Thread dandreta
Hello! I have in my view a list of products, each one with a checkbox to the side and a link (Remove Selected Products) at the end of the page. The question is that I want that on click the link all the marked products will be removed. How I would do my function in the controller in order that it

Re: Read M S Doc using php from linux and windows

2007-11-07 Thread Brandon
Welcome to the group Naren! There are lots of helpful people and tons of good information about CakePHP on here. Your question is out of the scope of this group, however I found lots information on this page: http://www.google.com/search?hl=en&client=firefox-a&rls=org.mozilla%3Aen-US%3Aofficial

Re: Clean Cake 1.1 sigfaults apache2

2007-11-07 Thread MrTufty
I've seen this happen myself - do you have anything like Zend Accelerator installed? I can't think what was causing it on my test system (it was months ago, before I migrated to the fertile grounds of 1.2 development). On Nov 7, 2:22 pm, MaxDao <[EMAIL PROTECTED]> wrote: > Ok, I tried, it. In mod

Re: Read M S Doc using php from linux and windows

2007-11-07 Thread MrTufty
I suggest you do some research on that thing commonly called the internet... On Nov 7, 10:27 am, "NAREN KUMAR" <[EMAIL PROTECTED]> wrote: > hi, > > iam new to this group. > > i need code to Read MS WORD document and stores in string from linux > system as well as from windows > > thanking u

Re: Log SQL queries

2007-11-07 Thread [EMAIL PROTECTED]
Thanks for your reply! Worked like a charm! Cake rules! On Nov 7, 1:50 pm, grigri <[EMAIL PROTECTED]> wrote: > extend whatever datasource you're using and override the _execute > method to log and pass back to the parent. > For example, let's assume you're currently using dbo_mysql. That means >

Re: Clean Cake 1.1 sigfaults apache2

2007-11-07 Thread MaxDao
No I don't have Zend accelerator, neither Zend optimizer installed. >From extensions that are not bundled with php I have only xdebug 1.3 Look's like I can't run cake on my primary stage server..sad. On Nov 7, 5:05 pm, MrTufty <[EMAIL PROTECTED]> wrote: > I've seen this happen myself - do you h

Re: |Revisted| Validation of a related Model

2007-11-07 Thread senser
Hmm, strange - may be the code works but the problem is at my side - all my validation seems to doesn't work. I haven't change my validate array and error messages in layout but now everything validates - even invalid fields, and beferoValidate() returns false but validation passes.. On N

Re: banging my head for last two days to find the blank line in RSS output

2007-11-07 Thread MrTufty
Skipping the ?> is actually something the Zend Framework people require if you submit code to them - it's in their coding style guide. Seems to work, but I couldn't get the habit - I hated not having balanced elements! On Nov 7, 11:21 am, bingo <[EMAIL PROTECTED]> wrote: > hi Richard, > > oh Cool

Re: dynamically change behavior's settings?

2007-11-07 Thread R. Rajesh Jeba Anbiah
On Nov 7, 7:10 pm, grigri <[EMAIL PROTECTED]> wrote: > If you look at the code in the behavior, you'll see that the messages > are generated in the setupUploadValidations() method, which is called > at the end of the setup() method. > > So basically, after you've changed the settings, call > setup

Re: |Revisted| Validation of a related Model

2007-11-07 Thread R. Rajesh Jeba Anbiah
On Nov 7, 7:21 pm, senser <[EMAIL PROTECTED]> wrote: > Do you mean that this code works: > > >$this->model1->model2->save($this->data) > > > and the below has to be: > > >$this->model1->model2->data = $this->data; > >$this->model1->model2->validates(); > > Both models are validated and error mes

Re: Clean Cake 1.1 sigfaults apache2

2007-11-07 Thread MaxDao
Ok, I tried, it. In model method (model_php4.php) when I put die() on the fist line of the __construct(); - it still gives segfault. However model extends object. On the object constructor object() I tried die string from first line to last - every time I have segfault, now I think I've stuck in

Re: |Revisted| Validation of a related Model

2007-11-07 Thread senser
Do you mean that this code works: >$this->model1->model2->save($this->data) > > and the below has to be: > >$this->model1->model2->data = $this->data; >$this->model1->model2->validates(); Both models are validated and error messages are displayed ??? On Nov 7, 3:05 pm, "R. Rajesh Jeba Anbiah"

Re: |Revisted| Validation of a related Model

2007-11-07 Thread R. Rajesh Jeba Anbiah
On Nov 7, 1:55 pm, I, ("R. Rajesh Jeba Anbiah" <[EMAIL PROTECTED]>) wrote: > > 2. From controller1::add() > > $this->model1->model2->save($this->data['model2']) correctly shows the > > validation error message in 'model2.x' In case, if someone refers this thread, the above save() call has to b

Re: Log SQL queries

2007-11-07 Thread grigri
extend whatever datasource you're using and override the _execute method to log and pass back to the parent. For example, let's assume you're currently using dbo_mysql. That means your db config is something like this: class DATABASE_CONFIG { var $default = array( 'driver

Re: dynamically change behavior's settings?

2007-11-07 Thread grigri
If you look at the code in the behavior, you'll see that the messages are generated in the setupUploadValidations() method, which is called at the end of the setup() method. So basically, after you've changed the settings, call setupUploadValidations() again manually and they should be updated, s

dynamically change behavior's settings?

2007-11-07 Thread R. Rajesh Jeba Anbiah
I'm looking to dynamically change the behavior's settings from controller. Background: I'm trying to change the "allowedSize" aka upload limit in Andy's UploadBehavior toolkit. I came up with this: $this->Post->Attachment->behaviors['ImageUpload']- >settings['Attachment'] = am($this->Post->Attach

Behavior of cake1.2 from branch concerning Form

2007-11-07 Thread francky06l
Hi All, I am working with the Cake1.2 branch, I now the consequences and I have noticed some side effects behaviors. I haven't updated from the branch for 3 days, and I noticed the following : - When you have an hidden field which is not 'id' of the spotted form model, the fields input name cont

Re: usedbconfig doesn't work

2007-11-07 Thread alessio
Hi, if I rename database.php in database.temp in my app condif dir cakephp return to me: --- Requires a Database Connection Confirm you have created the file : mydb\config\database.php. Missing Database Connection: ConnectionManager requires a database connection --- If I remane

Re: Cakephp newbie design question

2007-11-07 Thread maschoen
Not sure if I understand the question, but I think you want to keep track of the user being logged in, in a Session variable. That way, when you build the "tab" pages, you know whether to put up Generic or Specific content.I would put the navigation tabs in an element and pass it a variable

Read M S Doc using php from linux and windows

2007-11-07 Thread NAREN KUMAR
hi, iam new to this group. i need code to Read MS WORD document and stores in string from linux system as well as from windows thanking u in advance --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP"

Re: How to get value from method post (calendar)

2007-11-07 Thread birumerah
thanx, now i can working with post method :) On Nov 7, 2:16 pm, Grant Cox <[EMAIL PROTECTED]> wrote: > Should be in $this->params['form']['t0'] --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To

Re: Help me with paginate, please ; )

2007-11-07 Thread puatki
Thank You. That was very helpful ;) --~--~-~--~~~---~--~~ 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 [EMA

Re: YAMMY!: feed your migrations faster

2007-11-07 Thread [EMAIL PROTECTED]
Really usefull for next version is implement short YAML field decription syntax that appear in 3.3 version and only it work with add_fileds goal. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To

Re: using dojo with cakephp

2007-11-07 Thread kchopein
Hi! The same problem here! I can see cake is great and dojo is great too, but I'm not sure about how to use both together. I'm working on it, so I'll write here as I progress. Best regards! kchopein On 11 oct, 11:31, jimmyxx <[EMAIL PROTECTED]> wrote: > Hey guys, I've decided to jump in head f

Log SQL queries

2007-11-07 Thread [EMAIL PROTECTED]
Hi bakers. I need to log every SQL command executed by models. I was using the datasource's queriesLog variable to do this but when i put my server in production mode queries stoped being logged. I looked at the code and saw that SQL queries where only being logged in debug mode! I _really_ need

Re: banging my head for last two days to find the blank line in RSS output

2007-11-07 Thread bingo
hi Richard, oh Cool, I didn't knew that :-p. Regards, Ritesh On Nov 7, 5:26 am, RichardAtHome <[EMAIL PROTECTED]> wrote: > Another useful tip to cut down on these kind of errors in future is: > The closing php tag '?>' is optional so if you omit it you will never > have any unwanted trailing sp

Re: Clean Cake 1.1 sigfaults apache2

2007-11-07 Thread AD7six
On Nov 7, 9:41 am, MaxDao <[EMAIL PROTECTED]> wrote: > Maybe I gave to you wrong link to file. > I stopped on this string: > > $model =&new $this->modelClass($id); > > Where $this->modelClass is "Test" in my case. And code of this class > you can see in my prev. post. Yeah that's the line. and

Re: banging my head for last two days to find the blank line in RSS output

2007-11-07 Thread RichardAtHome
Another useful tip to cut down on these kind of errors in future is: The closing php tag '?>' is optional so if you omit it you will never have any unwanted trailing spaces ;-) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Googl

Re: General site sturcture

2007-11-07 Thread jimmyxx
Marcin Jaworski-2 wrote: > > > There was recently a discussion about this. You can read possible > solutions in this thread: > http://groups.google.com/group/cake-php/browse_thread/thread/74bc54890176172f# > > Cheers Marcin, using Robs helper which was mentioned on that link : http://baker

Re: I want gData

2007-11-07 Thread Mikee Freedom
You can incorporate the Zend framework in to your application : http://www.google.co.uk/search?q=cakephp+zend+framework&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:official&client=firefox-a On 07/11/2007, keymaster <[EMAIL PROTECTED]> wrote: > > Not sure how much mileage you're going to get out

Re: Multiple validation on a single field - CakePHP 1.1.17

2007-11-07 Thread Thrilller
i am sure VALID EMAIL will handle empty field also. i tried here and its working fine on empty field and on non valid email data. just go on with VALID EMAIL --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake

Re: |Revisted| Validation of a related Model

2007-11-07 Thread R. Rajesh Jeba Anbiah
On Nov 7, 12:52 pm, I, ("R. Rajesh Jeba Anbiah" <[EMAIL PROTECTED]>) wrote: > Previous discussions: > 1. http://groups.google.com/group/cake-php/browse_thread/thread/856cda8e... > 2.https://trac.cakephp.org/ticket/2473 > > Summary: > I still don't get it working. > > Case: > 1. add.ctp > $form->c

Re: |Revisted| Validation of a related Model

2007-11-07 Thread senser
I use latest CakePHP 1.2 version - 5875 On Nov 7, 10:43 am, senser <[EMAIL PROTECTED]> wrote: > I have the same problemm in my application and still working to > resolve. > > P.S. There is something strange that happened these days (not > upgrading CakePHP, PHP, MySQl etc) - now even when I

Re: |Revisted| Validation of a related Model

2007-11-07 Thread senser
I have the same problemm in my application and still working to resolve. P.S. There is something strange that happened these days (not upgrading CakePHP, PHP, MySQl etc) - now even when I "return false;" in beforeValidation() callback validation ot the models passes and tries to save invalid

Re: Clean Cake 1.1 sigfaults apache2

2007-11-07 Thread MaxDao
Maybe I gave to you wrong link to file. I stopped on this string: $model =&new $this->modelClass($id); Where $this->modelClass is "Test" in my case. And code of this class you can see in my prev. post. Regards, Maxim On Nov 6, 4:54 pm, AD7six <[EMAIL PROTECTED]> wrote: > On Nov 6, 3:31 pm, Ma

Re: General site sturcture

2007-11-07 Thread Marcin Jaworski
There was recently a discussion about this. You can read possible solutions in this thread: http://groups.google.com/group/cake-php/browse_thread/thread/74bc54890176172f# On Nov 6, 5:45 pm, jimmyxx <[EMAIL PROTECTED]> wrote: > Hey, > I'm new to cakephp and need some advise on how to structure my