Problemas com ajax

2007-09-21 Thread Rodrigão
Pessoal, estamos desenvolvendo um sistema grande aqui no meu estágio e estamos com problemas quanto ao uso de ajax com o cake. em uma tela de cadastro grande, e queremos poder abrir uma janela, que já foi feito usando javascript, e preencher um formulário a mais e quando clicassemos em OK,

Re: Ajuda dateTimeOptionTag

2007-09-21 Thread Tiago
Mais um problema com datas...rs Quando o formulário retorna erro de campos obrigatórios, os campos de data é preenchido automaticamente. Alguém sabe uma solução?! Abraços On 21 Set, 13:56, Tiago Cardoso [EMAIL PROTECTED] wrote: Problema solucionado. ?php echo

Re: different model different view

2007-09-21 Thread CakeMan
Also with this can i use URL as http://www.mysite.com/Y ?? On Sep 20, 10:57 pm, CakeMan [EMAIL PROTECTED] wrote: Thanks Grant, Should i put these lines in model or in cotroller ? Thanks Again !! On Sep 20, 9:43 pm, Grant Cox [EMAIL PROTECTED] wrote: $this-viewPath = 'y';

Re: Creating lot of cachable elements from controller to serve static content instead of hitting database

2007-09-21 Thread AD7six
On Sep 21, 4:57 am, Humble Groups [EMAIL PROTECTED] wrote: Background I have scenario where I have 15000+ rows of messags in Mysql, I present them with pagination. It works well till 10 pages, if the user suddenly press the last page, Mysql takes lot of time, A database will be inevitably

Re: different model different view

2007-09-21 Thread Grant Cox
Put it in your controller action. If you request http://www.mysite.com/Y , then it will execute the index action of the YController, unless you have set up a custom route. That action may do whatever it likes and render whatever file it likes. On Sep 21, 4:46 pm, CakeMan [EMAIL PROTECTED]

Re: Creating lot of cachable elements from controller to serve static content instead of hitting database

2007-09-21 Thread Grant Cox
Surely when he clicks the last page he's not requesting all 15K rows??! If so, that's some incredibly bad pagination! But then if the first 10 pages are consistently fast, and it's the later pages that are slow, it could be the terrible truth Sounds like something from worsethanfailure.com

Re: Creating lot of cachable elements from controller to serve static content instead of hitting database

2007-09-21 Thread AD7six
On Sep 21, 9:45 am, Grant Cox [EMAIL PROTECTED] wrote: Surely when he clicks the last page he's not requesting all 15K rows??! If so, that's some incredibly bad pagination! But then if the first 10 pages are consistently fast, and it's the later pages that are slow, it could be the

Re: Using Model in Component

2007-09-21 Thread Grant Cox
On Sep 21, 3:01 pm, Ananda Putra [EMAIL PROTECTED] wrote: You did it in every method which is need the model? Well, truthfully I have the following function in my /app/config/ bootstrap.php, and I just call attachModel( array('Model1','Model2'), $this ); $this-Model1-blah();

Re: 1.2 Auth/ACL resume

2007-09-21 Thread cakeFreak
Cheers Geoff! I already checked that tuto, and I think I'll go that way. + I'll upgrade to latest nightly. Cheers for your great tutorials by the way! Carry on mate! Dan On 21 Set, 01:58, Geoff Ford [EMAIL PROTECTED] wrote: Look into the $this-Auth-authorize = 'actions' and/or

Re: SQL? Why

2007-09-21 Thread Dr. Tarique Sani
On 9/21/07, deepc [EMAIL PROTECTED] wrote: messages_controller In my emails_controller is a function send() which should handle what If this is correct $this-Email-send(); then this is wrong - the 'Email' here is the Model not the controller i got: Warning: SQL Error: 1064: You have an

Re: Is the plugins tutorial on the manual WORKING ?

2007-09-21 Thread Dr. Tarique Sani
On 9/21/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: It always says missing controller, can someone confirm it's actually working ? and so what's maybe wrong with mine More details like What is the name of your plugin? Which folder have you put it in? How are you calling the plugin - what

SQL? Why

2007-09-21 Thread deepc
Hello, I have following models: Email Message and controllers emails_controller messages_controller In my emails_controller is a function send() which should handle what type of email should be send. If i call it from messags $this-Email-send(); i got: Warning: SQL Error: 1064: You have

Is the plugins tutorial on the manual WORKING ?

2007-09-21 Thread [EMAIL PROTECTED]
Hi, It has been severals days i'm trying to use the plugins but the tutorial on the manual of cakePHP doesn't work (for me at least) It always says missing controller, can someone confirm it's actually working ? and so what's maybe wrong with mine THANKS a lot

Model dependancies based on other relationship

2007-09-21 Thread Jason
I have an interesting issue with my model relationships that I'm attempting to figure out how to take care of in the most elegant fashion. Basically, I have a User model, a Profile model, and then multiple extended Profile models (ex: AdminProfile, etc.) which have information specific to that

Re: SQL? Why

2007-09-21 Thread deepc
OK, i see. if i move it to the model, is it still posible to access other models. for example i have to get some data from my users table. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Cake PHP group. To post to

Re: SQL? Why

2007-09-21 Thread Dr. Tarique Sani
On 9/21/07, deepc [EMAIL PROTECTED] wrote: OK, i see. if i move it to the model, is it still posible to access other models. for example i have to get some data from my users table. let me guess - you are getting the data which you want to send in the email in the send() method? I would

Re: SQL? Why

2007-09-21 Thread deepc
No, i just create the content in a central place. I use one of the bakery mail components. The situation is the following. I have template for a lot of emails in the database (table emails). in my emails controller i wanted to replace the variables with real life content and let the mail

Re: SQL? Why

2007-09-21 Thread Dr. Tarique Sani
On 9/21/07, deepc [EMAIL PROTECTED] wrote: the idea was that any controller should be able to send emails with one line of code, and without the necessity of defining text or anything else. just the userid and a type of mail. the rest should be held in database. An apt solution would be to

Capistrano + PHP deployment

2007-09-21 Thread cakeFreak
Hey guys, I read throught the *Automated PHP Deployment With Capistrano* tutorial = http://www.simplisticcomplexity.com/2006/8/16/automated-php-deployment-with-capistrano but it seems outdated. Does anyone has any FRESH suggestion for using Capistrano for PHP projects? Cheers in advance Dan

Re: Capistrano + PHP deployment

2007-09-21 Thread Chris Hartjes
On 9/21/07, cakeFreak [EMAIL PROTECTED] wrote: Hey guys, I read throught the *Automated PHP Deployment With Capistrano* tutorial = http://www.simplisticcomplexity.com/2006/8/16/automated-php-deployment-with-capistrano but it seems outdated. In what way do you think it's outdated? I'm

Re: Capistrano + PHP deployment

2007-09-21 Thread Dr. Tarique Sani
On 9/21/07, Christian Winther [EMAIL PROTECTED] wrote: Do share ? :) +1 Tarique -- = Cheesecake-Photoblog: http://cheesecake-photoblog.org PHP for E-Biz: http://sanisoft.com

Re: Creating lot of cachable elements from controller to serve static content instead of hitting database

2007-09-21 Thread Humble Groups
On 9/21/07, AD7six [EMAIL PROTECTED] wrote: On Sep 21, 4:57 am, Humble Groups [EMAIL PROTECTED] wrote: Background I have scenario where I have 15000+ rows of messags in Mysql, I present them with pagination. It works well till 10 pages, if the user suddenly press the last page,

Re: Capistrano + PHP deployment

2007-09-21 Thread Chris Hartjes
On 9/21/07, Dr. Tarique Sani [EMAIL PROTECTED] wrote: On 9/21/07, Christian Winther [EMAIL PROTECTED] wrote: Do share ? :) +1 Okay, okay. http://www.littlehart.net/atthekeyboard/2007/09/21/deploying-cakephp-applications-using-capistrano/ -- Chris Hartjes Senior Developer Cake

Re: Is the plugins tutorial on the manual WORKING ?

2007-09-21 Thread [EMAIL PROTECTED]
starcraft like the pizza exemple on the manual /starcraft/replays/index (replays is my controller index my action) You are seeing this error because controller StarcraftController could not be found. thx again :) On 21 sep, 11:56, Dr. Tarique Sani [EMAIL PROTECTED] wrote: On 9/21/07, [EMAIL

Re: Capistrano + PHP deployment

2007-09-21 Thread cakeFreak
Hey Chris, cheers for sharing! I thought it was not updated 'cause I tried to follow the tutorial and it didn't work for me. + I'm new to capistrano one question: I have all my php projects in C:\\www, while I installed all Ruby + Capistrano stuff in C:\\ruby In order to give the recepy to

Re: Capistrano + PHP deployment

2007-09-21 Thread Chris Hartjes
On 9/21/07, cakeFreak [EMAIL PROTECTED] wrote: Hey Chris, cheers for sharing! I thought it was not updated 'cause I tried to follow the tutorial and it didn't work for me. + I'm new to capistrano one question: I have all my php projects in C:\\www, while I installed all Ruby +

POST to /app/webroot/cake_gateway.php not supported.

2007-09-21 Thread Artur Dębski
Hi to all Can anybody help me what is wrong with my new Linux Fedora Core 7 serwer (Apache/PHP/MySQL) my friend got some errors with cakephp : - 501 Method Not Implemented Method Not Implemented POST

Re: Scheduled Task

2007-09-21 Thread guigouz
you can also use wget http://mysite/controller/action on the cron job, that would trigger the action On Sep 21, 2:54 am, 1/2 aßrain [EMAIL PROTECTED] wrote: That's what I was after - thanks! On Sep 21, 2:57 pm, Grant Cox [EMAIL PROTECTED] wrote: It's just a slightly modified

Re: SQL? Why

2007-09-21 Thread [EMAIL PROTECTED]
Sounds like you've got a problem with the naming of your models and components. If you are using the EmailComponent to send mails, you need to use $this-Email-send() in your controller. However, if your controller has a model called Email, then $this-Email will be the model instead of the

Re: Creating lot of cachable elements from controller to serve static content instead of hitting database

2007-09-21 Thread Humble Groups
And another question is, you are actually caching the data using serialize and unserialize. In my case, I want to either cake to execute the index.tpl view and return the html output so that I can save it persist/cache it myself or let cake cache it as well. TIA On 9/21/07, Humble Groups [EMAIL

JOB: CakePHP Developer Needed

2007-09-21 Thread Patrick Ruffini
Engage, a new strategic media firm at the intersection of technology and politics, is looking for a topflight Web applications developer to add to our growing network. We're looking for the following candidate: * Minimum 3 years experience in PHP/MySQL application development * Extensive

Yahoo Search Ajax

2007-09-21 Thread seacloud9
I am trying to create a Yahoo Search. I think it is breaking where I send the variable.. Your Help Would be greatly appreciated thanks: Current Error: Notice: Undefined variable: javascript in.. Control function showresult($yahoosearch = null) { $this-set('question',

Downloadable manual?

2007-09-21 Thread macasek
Why is gods name is there now downloadable manual? You're killing me! --~--~-~--~~~---~--~~ 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

Yahoo Search Ajax

2007-09-21 Thread seacloud9
I am trying to create a Yahoo Search. I think it is breaking where I send the variable.. Your Help Would be greatly appreciated thanks: Current Error: Notice: Undefined variable: javascript in.. Control function showresult($yahoosearch = null) { $this-set('question',

hasAndBelongsToMany help

2007-09-21 Thread kionae
My issue here is that I have an Article model and I want to be able to associate articles with other articles. It works in as much as I can relate one article to several others, but I need the relationship to go both ways. For example, in the backend of my site, a user associates article 1 with

Re: SQL? Why

2007-09-21 Thread AD7six
On Sep 21, 1:43 pm, Dr. Tarique Sani [EMAIL PROTECTED] wrote: On 9/21/07, deepc [EMAIL PROTECTED] wrote: the idea was that any controller should be able to send emails with one line of code, and without the necessity of defining text or anything else. just the userid and a type of

Re: Downloadable manual?

2007-09-21 Thread Chris Hartjes
On 9/21/07, macasek [EMAIL PROTECTED] wrote: Why is gods name is there now downloadable manual? You're killing me! Why? Because there is no need for one. The manual for 1.1 is online. The bakery contains lots of examples and the manual for 1.2 is almost ready. Combine that with Google and

PapPal IPN report problem

2007-09-21 Thread [EMAIL PROTECTED]
Hi (first post, and probably bad english) Im having a strange (I think) problem. Im trying to implement paypal's IPN notification with my cake app. The ipn works correct if it's sent to a fixed file in the site, for example: http://site.com/ipn.php, but doesn't seem to work if I point it to an

Re: Capistrano + PHP deployment

2007-09-21 Thread ianh
Suitably inspired and with absolutely no ruby experience whatsoever (how hard could it be?!) I just sat down, installed ruby and capistrano and wrote a simple deployment script for an app that: 1. archives the current version as a tar file 2. exports the latest version from SVN 3. sets the

Re: Capistrano + PHP deployment

2007-09-21 Thread Chris Hartjes
On 9/21/07, ianh [EMAIL PROTECTED] wrote: Suitably inspired and with absolutely no ruby experience whatsoever (how hard could it be?!) I just sat down, installed ruby and capistrano and wrote a simple deployment script for an app that: 1. archives the current version as a tar file 2.

generateList with concatenated valuePath

2007-09-21 Thread bujanga
Pretty sure this can be done but haven't quite gotten it yet. $this-User-generateList(); gives array of key=value such as [joined] = Array ( [30] = garyroot [31] = Tester1 ) Doing $this-User-generateList(null, null, null, null,

Re: Downloadable manual?

2007-09-21 Thread macasek
An offline copy. For browsing and for printing more than one section at a time. On Sep 21, 2:15 pm, Chris Hartjes [EMAIL PROTECTED] wrote: On 9/21/07, macasek [EMAIL PROTECTED] wrote: Why is gods name is there now downloadable manual? You're killing me! Why? Because there is no need

Re: Downloadable manual?

2007-09-21 Thread John David Anderson (_psychic_)
On Sep 21, 2007, at 11:42 AM, macasek wrote: Why is gods name is there now downloadable manual? You're killing me! It's people like you that make me want to quit. Thanks indeed for this respectful request! Since you pay so well, I guess I better hurry up and get that for you. Combine

Rss time to Unix Time?

2007-09-21 Thread [EMAIL PROTECTED]
Haven't found a good, quick way to convert the silly RSS time format into a unix format. Would love to be able to use cake's time helper to work with the timestamps, but no luck so far. As of now, I'm running a php function that I wrote to handle some time comparisons and such. anyone have a

Re: Rss time to Unix Time?

2007-09-21 Thread Chris Hartjes
On 9/21/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Haven't found a good, quick way to convert the silly RSS time format into a unix format. Would love to be able to use cake's time helper to work with the timestamps, but no luck so far. As of now, I'm running a php function that I

Re: Rss time to Unix Time?

2007-09-21 Thread fr3nch13
http://api.cakephp.org/1.2/class_rss_helper.html#29f174f1137ce44cc7328f199c2fa231 --~--~-~--~~~---~--~~ 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

Re: Rss time to Unix Time?

2007-09-21 Thread [EMAIL PROTECTED]
I thought so, but it's returning '-1' On Sep 21, 2:26 pm, Chris Hartjes [EMAIL PROTECTED] wrote: On 9/21/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Haven't found a good, quick way to convert the silly RSS time format into a unix format. Would love to be able to use cake's time

Re: Rss time to Unix Time?

2007-09-21 Thread [EMAIL PROTECTED]
RssHelper::time ( $ time ) Converts a time in any format *to* an RSS time. Not what I was looking for, thanks though! On Sep 21, 2:36 pm, fr3nch13 [EMAIL PROTECTED] wrote: http://api.cakephp.org/1.2/class_rss_helper.html#29f174f1137ce44cc732...

Re: Rss time to Unix Time?

2007-09-21 Thread Chris Hartjes
On 9/21/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: RssHelper::time ( $ time ) Converts a time in any format *to* an RSS time. Not what I was looking for, thanks though! Here's a crazy thought...why not just look at the source for RssHelper::time() and figure it out. If

Re: Scriptaculous Effects not working

2007-09-21 Thread [EMAIL PROTECTED]
I actually tried it with both a capital and lower case B, but nothing worked. Now, one of the interesting things I'm seeing with firebug is that there is no code for the Effect. I've looked at the source code, the generated code, all the stuff, and there is nothing about the effect in the page

Modifying name of DEBUG constant - bad practice?

2007-09-21 Thread MikeK
Just checking with the gurus on best practices. My CakePHP application (1.2 based) is bridged to phpBB for Authentication, ACL and a number of other features. WEBROOT/index.php has some code at the very top that imports appropriate modules from phpBB to setup phpBB sessions and vars that runs on

webroot visible in the url || bake -app newsite caused htaccess woes

2007-09-21 Thread Joshua McFarren
I just started developing a new app using the lastest 1.2 source. The old way I used to do things was to untar a fresh instance of cake into /var/www and then rename it something like www.sitename.com. I would the setup a VirtualHost directive in Apache and point DocumentRoot to

Re: Scriptaculous Effects not working

2007-09-21 Thread [EMAIL PROTECTED]
Nope. I've got the new in my code. On Sep 21, 2:23 pm, Christopher E. Franklin, Sr. [EMAIL PROTECTED] wrote: You are forgetting the new statement in front of Effect. new Effect.Flash('id'); On Sep 21, 12:45 pm, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: I actually tried it with both a

Re: Scriptaculous Effects not working

2007-09-21 Thread Christopher E. Franklin, Sr.
You are forgetting the new statement in front of Effect. new Effect.Flash('id'); On Sep 21, 12:45 pm, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: I actually tried it with both a capital and lower case B, but nothing worked. Now, one of the interesting things I'm seeing with firebug is that

Re: Modifying name of DEBUG constant - bad practice?

2007-09-21 Thread MattC
Hey Mike, You can use the same syntax to set the debug level as you saw in the Cake code. So after you include the phpBB files put: Configure::write('debug', '1'); Or even better define your own debug, CAKE_DEBUG and use that instead: Configure::write('debug', CAKE_DEBUG); That should overwrite

Re: Baffling error when trying to put ACL check in beforeFilter

2007-09-21 Thread 2000Man
What was the final solution to this problem (putting parent::beforeFilter(); as first line of code in my AppController::beforeFilter doesn't work)? On 30 aug, 12:58, Jon Bennett [EMAIL PROTECTED] wrote: ...I think you may be right (from looking at dispatcher.php in the cake source code).

raw headers and soap

2007-09-21 Thread deivid
Right now I'm implementing a soap server using php4 and nusoap (I know there is a soap class in php5), and I have hacked the file nusoap.php The problem is that for some reason the response comes with some linebreaks, and that is giving me this error (because the soap client expects ?xml instead

dbdesigner2cake version 1.0.3 released - supporting CakePHP 1.1 and 1.2

2007-09-21 Thread Dérico Filho
Hello All, Dbdesigner2cake now officially supports CakePHP 1.1 and 1.2. Actually, when you use it on CakePHP 1.2 it offers a new parameter, which is shown below: -wb, -with-bake generate controller and view code using bake shell. This options scaffold your application creating

Re: Modifying name of DEBUG constant - bad practice?

2007-09-21 Thread rtconner
The use the the DEBUG constant is going the way of the dodo in Cake (or already has). Yeah use Configure::write/read now. On Sep 21, 3:04 pm, MattC [EMAIL PROTECTED] wrote: Hey Mike, You can use the same syntax to set the debug level as you saw in the Cake code. So after you include the

Best practice: HABTM or HasMany: 5 cents?

2007-09-21 Thread bigbass
Hi there, I'm setting up a new site with cake 1.1. As a cake-newby, maybe you could give me your 5 cents (or even more? :) : The site uses user-generated images in different places (user profile, galeries, articles etc) I'm thinking of setting up just one table which stores image information

Re: Downloadable manual?

2007-09-21 Thread Samuel DeVore
the old manual is available at cakeforge.org for download http://cakeforge.org/frs/?group_id=53release_id=248 On 9/21/07, bigbass [EMAIL PROTECTED] wrote: hmm, my 2cent A downloadable manual would HELP people like macasek. (And me, as I like to have that old-fashioned folder of paper

Re: Downloadable manual?

2007-09-21 Thread Jon Molesa
googled [cakephp manual] http://manual.cakephp.org/printable/complete I ahven't checked, but I assume this is v1.2. Printed it stright to pdf. May not be what you had in mind, but...it works offline. *On Fri, Sep 21, 2007 at 05:42:19PM - macasek [EMAIL PROTECTED] wrote: From: macasek

Re: Capistrano + PHP deployment

2007-09-21 Thread Dr. Tarique Sani
On 9/22/07, ianh [EMAIL PROTECTED] wrote: capistrano and wrote a simple deployment script for an app that: 1. archives the current version as a tar file 2. exports the latest version from SVN 3. sets the permissions on the tmp folder; and now you should share it :) Tarique --

Re: SQL? Why

2007-09-21 Thread Dr. Tarique Sani
On 9/21/07, AD7six [EMAIL PROTECTED] wrote: An apt solution would be to extend the component which you are using. Controller like functionality which needs to be used in several controllers === Component Indeed :)! And using a component with the same name as a model == component gets

Re: JOB: CakePHP Developer Needed

2007-09-21 Thread Dr. Tarique Sani
On 9/21/07, Patrick Ruffini [EMAIL PROTECTED] wrote: Engage, a new strategic media firm at the intersection of technology and politics, is looking for a topflight Web applications developer to add to our growing network. post at http://withcake.com/ T --

Re: Unbind in paginate vs findAll

2007-09-21 Thread MikeK
Thanks Grant -- and just to confirm -- they will be reset to default regardless at conclusion of the action? ATHis has really helped me pare down the data in some requests -- it was either this or some custom SQL and this has been quite simple. The database structure is normailzed and I would not

Re: Modifying name of DEBUG constant - bad practice?

2007-09-21 Thread MikeK
Thanks guys -- I changed DEBUG to CAKEDEBUG in the source files although I hate to do it. Here's the files in cakeland: core.php, webroot/test.php, cake/bootstrap.php, cake/libs/configure.php, cake/ libs/xml.php, cake/libs/model/model.test.php. Since the constant DEBUG is used in all those places

Re: Best practice: HABTM or HasMany: 5 cents?

2007-09-21 Thread Grant Cox
HABTM vs hasMany depends on your application functionality - between an article and an image is it hasMany (each image is only in one article), or HABTM (each image could be in multiple articles)? The table setup will follow these application requirements, not the other way round. If you can

Re: Unbind in paginate vs findAll

2007-09-21 Thread Grant Cox
Depends what you mean at the end of the action. It isn't saved in the session or anything, so separate requests will not be affected. But while that model instance is in scope it will remain that way (so through the view render etc), for the remainder of the request. If you want really fine

Re: Posting a form with a regular link

2007-09-21 Thread Dr. Tarique Sani
On 9/22/07, beetlecube [EMAIL PROTECTED] wrote: I'm wondering how many users have javascript disabled. IME - this varies significantly from site to site my photogallery site has 1% visitors with JS disabled where as my company site has about 5% Why not have a submit button styled to look like

Re: Posting a form with a regular link

2007-09-21 Thread Felix Geisendörfer
I've started doing the following. If the delete action is called using GET then I'm serving a Are you sure you want to delete item X? page which has a form and a submit button to it. When JS is enabled then my delete link has an onclick event that pops up a JS confirm() modal and then sends