Exibir mensagem do resultado da ação gravado com setFlash

2007-11-26 Thread hostdesigner
Preciso exibir as mensagens do tipo Dados salvos com sucesso, não foi possível realizar o processo e afins. O problema é que mesmo gravando as mensagens com o setFlash elas não aparecem na página, só aparecem as mensagens das páginas geradas pelo bake as minhas não aparecem nem a pau. Para que

Re: Exibir mensagem do resultado da ação gravado com setFlash

2007-11-26 Thread hostdesigner
É assim que estou fazendo atualmente, mas, como já tinha dito os controllers e views criados pelo bake não tem este código e exibem a mensagem normalmente... queria saber como é feito... Falopa! --~--~-~--~~~---~--~~ Recebeu esta mensagem porque está inscrito em

Re: Data em Português

2007-11-26 Thread markynhoz
Opa segui o exemplo que voce postou ta funcionando mas fica me mostrando um erro Notice: Undefined index: Conta in C:\xampp\htdocs\cake\contas\models \conta.php on line 9 Saberia me dizer o que seria esse erro! On 1 out, 15:47, Marcio Trindade [EMAIL PROTECTED] wrote: Vinícius, outra opção

Re: Exibir mensagem do resultado da ação gravado com setFlash

2007-11-26 Thread Augusto Ferreira
Nos seus controladores para setar a mensagem $this-Session-setFlash(''); e no teu layout coloca if ($session-check('Message.flash')){ $session-flash(); } Em 26/11/07, hostdesigner [EMAIL PROTECTED] escreveu: É assim que estou fazendo atualmente, mas,

Re: Exibir mensagem do resultado da ação gravado com setFlash

2007-11-26 Thread Renan Gonçalves
Olha o código gerado... Mas tipo, qual template ele usa? Por exemplo, no template: cake/scripts/templates/skel/views/layouts/default.thtml (o defaul do cake) existe o $session-flash(). On Nov 26, 2007 6:18 PM, hostdesigner [EMAIL PROTECTED] wrote: É assim que estou fazendo atualmente, mas,

Re: Data em Português

2007-11-26 Thread John-Henrique Ferreira Silva
Simples, você está utilizando uma chave de array que não existe, ou seja, que não possui um valor e nem mesmo foi setada... Ela está na linha 9 do arquivo conta.php Falopa! Em 26/11/07, markynhoz [EMAIL PROTECTED] escreveu: Opa segui o exemplo que voce postou ta funcionando mas fica me

Re: Exibir mensagem do resultado da ação gravado com setFlash

2007-11-26 Thread John-Henrique Ferreira Silva
heheh, verdade, nem tinha me dado conta deste detalhe, eu alterei o layout :D Falopa! Em 26/11/07, Renan Gonçalves [EMAIL PROTECTED] escreveu: Olha o código gerado... Mas tipo, qual template ele usa? Por exemplo, no template: cake/scripts/templates/skel/views/layouts/default.thtml (o

Re: Problems modeling User - Friend HABTM associations

2007-11-26 Thread Nasko
Could anyone help me out with this one? I'm really stuck :-( --~--~-~--~~~---~--~~ 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

Problem in displaying the css,images in layout..

2007-11-26 Thread shri
Hi friends... i have some problem in Cakephp configuration .. My Cakephp folder is c:/wamp/www/cake_1.0.2 While execute my coding it display the input box and so on. But when I click the submit button. It display File not found Error.. Help me to solve this problem..

Re: cakephp-fr

2007-11-26 Thread avairet
Bonjour à tous ! Oui, parlons un peu français, puisque nous sommes sur ce post pour évoquer une communauté francophone autour de Cake ! J'utilise Cake depuis deux mois environ, suite à une décision du chef de projet de la boîte où je suis actuellement en mission. Et l'une des difficultés

Help with multiple ajax forms

2007-11-26 Thread Wi1d
Hello Google CakePHP Group, I'm stumped and thought I'd submit. I'm wanting to create multiple task list and related task on a single view. This view also has multiple forms created using $ajax-form and $ajax-submit that will let me add task to their related tasklist. For some reason that I

Re: Problem in displaying the css,images in layout..

2007-11-26 Thread Ryan Escarez
The subject and the body message seems to be not appropriate... To answer your subject question: Make sure that you enabled the mod_rewrite AllowOverride All in apache config file To answer your body question: Once you tried the above answer, you may try executing again your script and

bake function, Fatal Error, Call to undefined function mysql_connect()...

2007-11-26 Thread Sam Luo
I tried the nightly release, I replaced all componenets: doc, vendor, cake, but app. All my webs work properly, but the baking function, when I use php bake.php in windows command line, I got Fatal error. Call to undefined function mysql_connect(). And I can use phpmyadmin, which means my

Re: Strange recursion problem (i think) - hopefully someone can shed some light (code inc.)

2007-11-26 Thread designvoid
Sorted! It was that plural, dropped the 's' and BINGO! d. On Nov 24, 7:15 pm, designvoid [EMAIL PROTECTED] wrote: The uses array is only there to test the Variations call, I would remove it in finished thing. The plurals are the names of the arrays I thought, and as such didn't matter what

Re: bake function, Fatal Error, Call to undefined function mysql_connect()...

2007-11-26 Thread Daniel Hofstetter
Hi Sam, That sounds like the mysql module is not enabled for the command line, there is a separate php.ini for php-cli (at least here on Linux). HTH -- Daniel Hofstetter http://cakebaker.42dh.com --~--~-~--~~~---~--~~ You received this message because you are

Re: bake function, Fatal Error, Call to undefined function mysql_connect()...

2007-11-26 Thread Sam Luo
Problem got solved!!! Happy! 1. Add line PHPIniDir C:/Sserver/PHP at the bottom of httpd.conf file( the configure file of apache). 2, Move php.ini to the PHP installation folder. 3. restart apache server. 4. Check tag Loaded Configuration File in phpinfo() to make sure the proper

configuring cakephp

2007-11-26 Thread GunabalanS
configuring cakephp Refer: http://manual.cakephp.org/chapter/installing point no 5) Configuring Apache and mod_rewrite when put the cakePHP folder in doc root if the following error comes Warning: session_start() [function.session-start]: open(/var/lib/php/

Re: cakephp-fr

2007-11-26 Thread kanian
Have you registered the domain as yours yet? I do speak french, and eventhough I am not a Cake expert, I believe that translating the docs is a doable task. I can commit myself to such a project. Still as avairet says, there needs to be leadership. Why not you? Since it's your idea... I am now

Clear definitions for M V C? (newbie)

2007-11-26 Thread powtac
Hi, Im trying to move an existing project into cakephp (and also into a MVC-modell). What questions can I use to find out if -an existing part of code -an existing functionality -an existing database table is a model or a controller or only a view...

Re: cakephp-fr

2007-11-26 Thread avairet
Hello Kanian, This discussion is now on the Cakephp-fr Groups: http://groups.google.com/group/cakephp-fr You're welcome! Aurélien On 26 nov, 11:47, kanian [EMAIL PROTECTED] wrote: Have you registered the domain as yours yet? I do speak french, and eventhough I am not a Cake expert, I

Re: Clear definitions for M V C? (newbie)

2007-11-26 Thread djiize
Controller: business logic Model: data logic View: presentation logic http://en.wikipedia.org/wiki/Model-view-controller http://manual.cakephp.org/chapter/basic_concepts On Nov 26, 1:11 pm, powtac [EMAIL PROTECTED] wrote: Hi, Im trying to move an existing project into cakephp (and also into a

Re: Eclipse code completion in Views

2007-11-26 Thread avairet
Hello Michael, All it's clear for Code completion now and I will search the better method to get this completion in Eclipse PDT, whitout surcharging files. Otherwise my question about Helpers/Components loading is not about the Code completion but about Cake himself! Because of sentence in your

Re: Clear definitions for M V C? (newbie)

2007-11-26 Thread powtac
Yes, but... For example I have a pice of code which handles a file upload. What question can I ask to figure out if this is a model or a controller? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Cake PHP group. To

Please help -- Acl node inheritance

2007-11-26 Thread Dodger
Hi, My ARO tree: [1] [2] [3] [4] My ACO tree: [1] Root [2] Pages [3] display A permission in the aros_acos table: id, aro_id, aco_id, _create, _read, _update, _delete 1, 4, 2, '0', '0', '0', '0' i.e. Grant ARO 4 access to ACO 2 ('Pages' controller). However, this check

Re: Problems modeling User - Friend HABTM associations

2007-11-26 Thread nate
Take the associations out of your UserFriend model. They're implied, as UserFriend is already being used to join User and Friend. On Nov 26, 3:32 am, Nasko [EMAIL PROTECTED] wrote: Could anyone help me out with this one? I'm really stuck :-(

Re: Problems modeling User - Friend HABTM associations

2007-11-26 Thread nate
Also, unless you're using some other code that's not posted here, there's no method in CakePHP called unbindAll. On Nov 26, 3:32 am, Nasko [EMAIL PROTECTED] wrote: Could anyone help me out with this one? I'm really stuck :-( --~--~-~--~~~---~--~~ You received

Re: Please review my way of saving a Associaton Model

2007-11-26 Thread mbavio
Instead of making an if, you can put that code in an afterSave callback. But it´s the same, the olny benefit will be that you are following the Fat Model, Skinny Controller concept. Cheers. Martin Bavio. On Nov 24, 10:21 pm, josoroma [EMAIL PROTECTED] wrote: In my benchlink_controller.php im

Cake and ThemeView class

2007-11-26 Thread foxmask
hello, i'm trying to use this class to be able to use theme with cake but i really dont know how to do. i've created : webroot/themed/foobar/layouts webroot/themed/foobar/elements put default.php in layout directory and in the app_controller did public $theme = PT_DEFAULT_THEME; class

How can i use filters?

2007-11-26 Thread [EMAIL PROTECTED]
Hi all I'm a totally beginner with CakePHP and need some help. I have a user list with pagination, who shows me all users. It works fine. But, all users are in different usergroups, and I like to have a select-box, where I can choose one of the usergroups. After that, it should show me all

Re: Problems modeling User - Friend HABTM associations

2007-11-26 Thread Samuel DeVore
On Nov 26, 2007 8:08 AM, nate [EMAIL PROTECTED] wrote: Also, unless you're using some other code that's not posted here, there's no method in CakePHP called unbindAll. could be this one http://othy.wordpress.com/2006/06/03/unbind-all-associations-except-some/ Sam D -- (the old fart) the

Re: Looking for an example with Extjs lib

2007-11-26 Thread hydra12
OK, I now have an example to share. It's fairly long, so I won't post it here, but you can find it on my blog. http://www.ntatd.org/mark/?p=29 I hope that helps you some. If you have any questions, let me know. hydra12 On Nov 21, 5:19 pm, aniston [EMAIL PROTECTED] wrote: Thankx Hydra, will

path from Router::url

2007-11-26 Thread iGL
Hi, My question is probably that of a beginner: I has not been a long time since I started to use CakePHP. I need pathinfo in my controller. Thats what I am doing: $p1=Router::url(/,false); //that's my RewiteBase $p2=Router::url(,false); $pc=substr($p2,strlen($p1)-1); And then I use $pc:

Dynamic table

2007-11-26 Thread dandreta
I have two models:ModelA and Model B. ModelA hasMany ModelB. In the add view of ModelA, I want to create a table dynamically with a button(AddB) and clicking it, adds a new row with the inputs of the fields of the ModelB. At the end of the view I have a submit button and I want that on clicking

Re: email component - smtp auth (SOLVED?)

2007-11-26 Thread Gorka
I had this same issue, the server was responding 235 GO AHEAD ans not OK authenticated. This fixed the error on send, though emails still don't seem to arrive. On 29 oct, 21:35, atomic [EMAIL PROTECTED] wrote: I had some problems sending mail using smtp auth. MTA (postfix) always told me lost

suggestion for cake query

2007-11-26 Thread keymaster
Looking for a suggestion on how to cake-formulate the following query with FindAll: Associations: == Group hasMany Account; Account belongsTo Group Account hasMany Order; Order belongsTo Account Order hasMany OrderProduct; OrderProduct belongsTo Order

setting default for datetime field in FormHelper

2007-11-26 Thread releod
Hello, I was wondering if anyone could shed some light on how to pre- populate a datetime FormHelper field. I have read through the API, and I get the basics of it, but I guess not fully because now I am here asking for some guidance :) Two things I am interested in, is there a way to specify a

Re: Dynamic table

2007-11-26 Thread Christopher E. Franklin, Sr.
I think here, you are going to have to roll your own sql statements within the function of the controller. On Nov 26, 10:01 am, dandreta [EMAIL PROTECTED] wrote: I have two models:ModelA and Model B. ModelA hasMany ModelB. In the add view of ModelA, I want to create a table dynamically with a

Re: Dynamic table

2007-11-26 Thread rtconner
If it was me, I'd have a Model with no table attatched and then add a function to create the tables in it --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Cake PHP group. To post to this group, send email to

Re: setting default for datetime field in FormHelper

2007-11-26 Thread Christopher E. Franklin, Sr.
You should be able to set a default by passing a unix timestamp to the field $selected. $selected = strtotime('Jan 6, 1978 07:00'); $form-dateTime('Field.name', 'DMY', 12, $selected, array(), false); about setting up the range? No clue besides making your own helper or modifying cake code. On

Re: suggestion for cake query

2007-11-26 Thread rtconner
In theory the following code should work. I don't know if it will or not though, because I'm not sure how deep you can set the recursive flag. OrderProduct=recursive = 4; OrderProduct-find(array(OrderProduct.fromDate '2007-10-01', 'Group.id'=3)) On Nov 26, 11:15 am, keymaster [EMAIL PROTECTED]

Re: setting default for datetime field in FormHelper

2007-11-26 Thread releod
I found you can set minYear / maxYear, for the year range. Do not really need it on the other fields. Of course I discover that part after posting. Thanks though! On Nov 26, 1:26 pm, Christopher E. Franklin, Sr. [EMAIL PROTECTED] wrote: You should be able to set a default by passing a unix

Re: suggestion for cake query

2007-11-26 Thread keymaster
The following kludge did the trick: The key was to figure out which model to go through for the findAll(), and which relationship to redefine as hasOne so it will be included in the query. Here is the snippet fyi: // Redefine Order - OrderProduct relationship to get Order included in the

Sub-classing Paginator?

2007-11-26 Thread Buzzholio
I'm writing an application for FaceBook (using version 1.2 of Cake). I am having trouble getting paginator to work. Paginator works great when I run it locally, but when running as a FaceBook application, it returns urls that relate to FaceBook. I need to take what ever is returned by Paginator

Re: Save multipel posts at once

2007-11-26 Thread hydra12
Here's a post on my blog that talks about saving several records to your database at once: http://www.ntatd.org/mark/?p=28 I hope that helps! hydra12 On Nov 22, 12:57 pm, laeffe [EMAIL PROTECTED] wrote: I'm trying to create a page that will submit multipel posts for an model. But i cant

RE: published/unpublished mode with search conditions

2007-11-26 Thread Mariano Iglesias
The Soft Deletable behavior has been updated and now also supports string based conditions: http://bakery.cakephp.org/articles/view/soft-delete-behavior -MI --- Remember, smart coders answer ten questions for every

Re: .htaccess password in CAKE

2007-11-26 Thread Dragos Chiriac
Mazgalici wrote: Does anybody know how to put a passoword on .htaccess file for a direcory for example http://localhost/admin ? Thanks Hi, though it seems a stupid question it is not, and you'll see why : Part one, preety straight forward : Put a .htaccess in the dir you want to

Using curl_multi_* across several modules

2007-11-26 Thread Sean Walberg
I've got a series of web services implemented as models that a controller might call as such: $a = $this-WebService1-findByName($searchstring1); $b = $this-WebService2-findByName($searchstring2) $c = $this-WebService3-findByName($searchstring3) // Do something with $a, $b, and $c, then pass it to

Problem with IPN notify_url

2007-11-26 Thread xz8888
Hi, I am new to Cakephp and I have been trying to integrate paypal IPN with cakephp. In the notify_url I have set the url to /***/orders/ipn. However, the ipn doesn't seem response when the order is completed. Is it something to do with the url I have set Here is the form that submit to

Model.index.field notation gone?

2007-11-26 Thread releod
I just updated to the latest nightly build, and now some of my form elements are broken. They _were_ using model.index.field notation, can someone suggest what other options I can use, or how to re-enable it. Is this something that will be worked out for good or is it a bug causing it not to

Re: Cake and ThemeView class

2007-11-26 Thread foxmask
any suggestion on how we have to proceed to be able to use themes ? Kind Regards On Nov 26, 4:19 pm, foxmask [EMAIL PROTECTED] wrote: hello, i'm trying to use this class to be able to use theme with cake but i really dont know how to do. i've created : webroot/themed/foobar/layouts

Newbie: HABTM select

2007-11-26 Thread [EMAIL PROTECTED]
I have two tables, companies and tags, joined by a companies_tags table. If I add/edit a company, Cake populates a tags listbox just fine. How can I get a list of the companies that contain certain tags? If I try to set a condition Tag.tag_id IN (1, 2, 3), I get an SQL error (field tags.tag_id

Re: Cake and ThemeView class

2007-11-26 Thread Gwoo
try setting var $view = 'Theme'; --~--~-~--~~~---~--~~ 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

How do I access variables set in App Controller in View?

2007-11-26 Thread [EMAIL PROTECTED]
Is there a special way to refer to variables that are set in the app controller? I have: class AppController extends Controller { var $helpers = array('Html','Ajax','Javascript'); function beforeFilter() { if($this-Session-check('User')){

Re: How do I access variables set in App Controller in View?

2007-11-26 Thread Gwoo
beforeRender is usually better for that stuff than beforeFilter because its possible that you are overwriting user somewhere in you controllers. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Cake PHP group. To post

Can we put controller into sub folder ?

2007-11-26 Thread paydjo
can we put controller into sub folder. example: I separated user_controller into guest, member, admin so I want to put it into separate file in - /app/controllers/user/admin_controller.php - /app/controllers/user/guest_controller.php - /app/controllers/user/member_controller.php and we can access

Re: Can we put controller into sub folder ?

2007-11-26 Thread Samuel DeVore
http://cakebaker.42dh.com/2007/11/22/organizing-your-code-with-folders/ On Nov 26, 2007 8:16 PM, paydjo [EMAIL PROTECTED] wrote: can we put controller into sub folder. example: I separated user_controller into guest, member, admin so I want to put it into separate file in -

Tree behaviour help

2007-11-26 Thread CakeMan
Hi Guys, I am looking for working with Tree behaviour however i am finding any Tutorials or article for it. I am having cake1.2 pre beta. pls help. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Cake PHP group. To

Re: Newbie: HABTM select

2007-11-26 Thread Bertot Remy
Hello, In case you wants to paginate the result here is the way: 1. Create a model companies_tag, with the association $belongsTo(Company,Tag,[...]). 2. In your company controller, use this model ($uses) and redefine the paginate var by adding something like $paginate = array( CompaniesTag

Re: Can we put controller into sub folder ?

2007-11-26 Thread Daniel Hofstetter
The solution I described in the article linked by Sam doesn't have an effect on the url, i.e. if you put some controllers into a user folder, then they are not automatically accessible under yourdomain.com/user/controllername/. You would have to define one or more routes for this purpose. HTH

Re: Cake and ThemeView class

2007-11-26 Thread foxmask
Hi, i already tried it, and also, as suggest in another thread, copying from cake/view/theme.php in the myapp/view directory that does not solve the issue. may be the theme management is not ready yet . Kind Regards. On 27 nov, 02:48, Gwoo [EMAIL PROTECTED] wrote: try setting var $view =

How i18n loads translation files?

2007-11-26 Thread Cristian Vrabie
From your cake source digging, what do you know? Does the internationalization system caches the traslation files in shared memory or it loads (or performs search on file) them for every page acces? --~--~-~--~~~---~--~~ You received this message because you