Re: Style switcher / font resizer

2007-01-25 Thread Jonathon Davis
You should be able to do this with just prototype.js unless you want it to have an effect on it while it is resizing the font. http://www.prototypejs.org/api/element/methods/ getStyle and setStyle are the ones you should concern yourself with. $('element').setStyle({ 'font-size': g

Re: Date field SQL error

2007-01-25 Thread nate
Just add a beforeSave callback in your model that unsets the field from $this->data if it is empty. On Jan 25, 5:49 pm, "miggs" <[EMAIL PROTECTED]> wrote: > I'm sure the answer is right in front of me as it normally is, but I'm > just not seeing. I used the bake.php script to create the basic >

Re: Transactions support

2007-01-25 Thread nate
Transactions aren't yet supported at the model level. We're working on it, be patient. On Jan 25, 5:33 pm, "zipman" <[EMAIL PROTECTED]> wrote: > Anyone? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" g

Re: error in default.thtml

2007-01-25 Thread nate
Okay, the most likely issue is that Cake is rendering an error page, and the error page is using the default layout, which uses JavascriptHelper. Cake, on the other hand, is probably using the base Controller class to render the error. Ergo, no $javascript. If you want to know the *real* error,

Re: Can Cake's routing system do this?

2007-01-25 Thread nate
You can do this in Cake 1.2: Router::connect("/foo/bar/:controller/:action/*", array("plugin" => "foo_bar")); On Jan 25, 6:30 pm, Gonçalo Marrafa <[EMAIL PROTECTED]> wrote: > Hi to all. > > I've searched through Cake's documentation and this group but i couldn't > find an answer to my problem. Ho

Re: Pagination in 1.2 with method parameters

2007-01-25 Thread nate
$paginator->next('Next>>', array('url' => $this->params['pass'])) On Jan 25, 10:00 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > I'm using the latest nightly build of 1.2 (2007.01.24) and I'm trying > to use pagination to display some search results. The search > parameters are specified

Pagination in 1.2 with method parameters

2007-01-25 Thread [EMAIL PROTECTED]
I'm using the latest nightly build of 1.2 (2007.01.24) and I'm trying to use pagination to display some search results. The search parameters are specified as arguments to the action method like this: /controller/action/param1/param2 The first page of results comes up fine, but the link generat

Re: Dynamically generated form controls and DOM

2007-01-25 Thread Mountain Man
Hello, I solved the DOM problem. While the dynamically generated radio buttons could not be read by their name attribute, they could be read by their id attribute. I had mistakenly capitalized the D at the end of "getElementById." Below is an adaption of a script from page 749 of the second editi

Re: afterFind in associations STILL not working, 1.2.0.4206 Development

2007-01-25 Thread Logan
After some more test, I just find out that is not the afterFInd in associations that doesn't work but the afterFind in Behaviors. Sorry about the last one. :P I supposed that behaviors are yet to fresh to say anything about them. Thank you very much --~--~-~--~~~---

Re: A new music thing with CakePHP

2007-01-25 Thread tom
Hi, It's fixed. Sam - It's parsing XML with SimpleXML and tying into MusicBrainz, Amazon, and Hype Machine to get information. The musicbrainz database is lacking in certain areas, with lesser-known artists and it has some duplicates in the mix. I'll try to combine it with other services to get

afterFind in associations STILL not working, 1.2.0.4206 Development

2007-01-25 Thread Logan
Greetings CakePHP Team. Nice Work! afterFind, beforeFind, etc. in associations are not been executed. I know there are several posts about this subject, but no concrete answer. It's a bug? it's a feature? it's wrong to execute afterFind of one model from an association? I think this feature its

Can Cake's routing system do this?

2007-01-25 Thread Gonçalo Marrafa
Hi to all. I've searched through Cake's documentation and this group but i couldn't find an answer to my problem. Hope you guys can help me out. I want to connect urls like /foo/bar/some_controller/some_action to foo_bar plugin. Can i do this with Cake's routing system? -- Gonçalo Marrafa <[EM

Style switcher / font resizer

2007-01-25 Thread lukemack
Hi, Can anyone recommend a way to implement a font resizer in a cakePHP application? Can this be done with the scriptaculous js library? Or would I be better off doing this server-side? The functionality should be global to the app and allow the user to click on some buttons in the header to resi

Re: error in default.thtml

2007-01-25 Thread lukemack
thanks again! On 25 Jan, 13:52, "Samuel DeVore" <[EMAIL PROTECTED]> wrote: > Actaully you don't need to copy the app_controller from core, just > make a new one that has just this > > class AppController extends Controller { > var $components = array('Acl','Output'); // components you

Date field SQL error

2007-01-25 Thread miggs
I'm sure the answer is right in front of me as it normally is, but I'm just not seeing. I used the bake.php script to create the basic scaffolding for my project. I then added a datepicker (from frequency-decoder.com) to the date fields. It is working great, I think it's a fantastic script. If

Re: how can I pass two or more params to controller

2007-01-25 Thread the_woodsman
Ahhh, excellent. Could 1.2 map these directly to the names of the params in your action methods? i.e action/var1:val1/var2:val2 maps correctly to action($var2, $var1) Now *that* would be awesome... hint :) On Jan 25, 6:50 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > Here ya

Re: Paginate() question for 1.2.x.x

2007-01-25 Thread Jonathon Davis
Sweet. Thanks for explaining that for me. I don't know what I would do without the Cake Google Group. The API and documentation don't give all the information you would need. Thanks nate On Jan 25, 3:40 pm, "nate" <[EMAIL PROTECTED]> wrote: > // First way: > > var $paginate = array('conditions'

Dynamically generated form controls and DOM

2007-01-25 Thread Mountain Man
Hello, I searched Cake PHP for "DOM" and got 4 pages of results, none of which appeared to address this question. I am having a problem with code adapted from the first edition of "Programming PHP." This code dynamically generates checkboxes or radio buttons that retain their settings when the f

Re: Transactions support

2007-01-25 Thread zipman
Anyone? --~--~-~--~~~---~--~~ 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 PROTECTED] For more optio

Re: Using one set of controllers/models for multiple sites

2007-01-25 Thread John David Anderson (_psychic_)
On Jan 25, 2007, at 3:11 PM, Dave Rogers wrote: > > On Jan 25, 4:00 pm, "John David Anderson (_psychic_)" > <[EMAIL PROTECTED]> wrote: > >> You should be able to point multiple virtual domains at a single app/ >> webroot folder. Is that what you're asking? >> >> -- John > > > Yes. But the domai

Re: Using one set of controllers/models for multiple sites

2007-01-25 Thread Dave Rogers
On Jan 25, 4:00 pm, "John David Anderson (_psychic_)" <[EMAIL PROTECTED]> wrote: > You should be able to point multiple virtual domains at a single app/ > webroot folder. Is that what you're asking? > > -- John Yes. But the domains would be from different organizations: someNonProfit

Re: Using one set of controllers/models for multiple sites

2007-01-25 Thread John David Anderson (_psychic_)
On Jan 25, 2007, at 2:54 PM, Dave Rogers wrote: > > Is there a way to use one set of controllers and models for multiple > sites? This would effectively create an ASP (Application Service > Provider) model. You should be able to point multiple virtual domains at a single app/ webroot folder.

Using one set of controllers/models for multiple sites

2007-01-25 Thread Dave Rogers
Is there a way to use one set of controllers and models for multiple sites? This would effectively create an ASP (Application Service Provider) model. Thanks --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake P

Re: Custom conditions in 1.2 Pagination

2007-01-25 Thread [EMAIL PROTECTED]
I actually wrote it wrong in the first post (d'oh!): price1 and price2 are actually the same field in the table called price. Here's what finally worked: $conditions = array(); $conditions[] = array('price' => '>=100'); $conditions[] = array('price' => '<= 400'); $this->paginate($conditions);

Re: Custom conditions in 1.2 Pagination

2007-01-25 Thread nate
First, try setting DEBUG to 2, so you can see the actual SQL being generated. Second, try specifying the conditions like this: $data = $this->paginate(array('price1' => "<= 100", 'price2' => ">=400")); On Jan 25, 4:05 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > I'm using the latest nig

Re: Paginate() question for 1.2.x.x

2007-01-25 Thread nate
// First way: var $paginate = array('conditions' => array('active' => 1)); // Second way: $data = $this->paginate(array('active' => 1)); On Jan 25, 3:02 pm, "Jonathon Davis" <[EMAIL PROTECTED]> wrote: > I have a question about paginate()... Is there any way to add > conditions to fetching and d

Re: obAuth Session Errors

2007-01-25 Thread [EMAIL PROTECTED]
Hi, just check out what is at line 117 (output started at /Library/WebServer/Documents/cake_1.1.12.4205/ngo_reservation/controllers/components/ob_auth.php:117) that makes some output into buffer before session_start() function is called. Also white spaces count. --~--~-~--~~

Re: Pagination in 1.2 using different models

2007-01-25 Thread [EMAIL PROTECTED]
Wow that was easy - thanks Nate! On Jan 25, 3:07 pm, "nate" <[EMAIL PROTECTED]> wrote: > var $paginate = array("ModelName" => array("limit" => 20)); > > function index() { > $data = $this->paginate("ModelName"); > ... > > }On Jan 25, 2:08 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote

Custom conditions in 1.2 Pagination

2007-01-25 Thread [EMAIL PROTECTED]
I'm using the latest nightly 1.2 (2007.01.24) and am trying to use some custom conditions in my pagination call. Basically I want some SQL that looks like: SELECT * FROM table WHERE price1<='100' AND price2>='400' I tried using "price1<='100' AND price2>='400'" as the $scope argument to the pag

Re: Error At Top Of Every Page

2007-01-25 Thread Dustin
Thanks Mika, my de-compression software defaults the bad way in this case. That was the problem, it just skipped the empty folders. I appreciate the help from everyone. I feel dumb for missing that note at the bottom of the install instructions though. - Dustin On Jan 25, 1:50 pm, "Mika" <[EM

Paginate() question for 1.2.x.x

2007-01-25 Thread Jonathon Davis
I have a question about paginate()... Is there any way to add conditions to fetching and displaying results? Let's say I had a posts MVC and I wanted to paginate only posts that have a certain category assigned to them. How would I do this? Can I achieve this with the built-in function or would

Re: Pagination in 1.2 using different models

2007-01-25 Thread nate
var $paginate = array("ModelName" => array("limit" => 20)); function index() { $data = $this->paginate("ModelName"); ... } On Jan 25, 2:08 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > I'm using the latest nightly of 1.2 (2007.01.24) and have a controller > that uses several model

Re: Error At Top Of Every Page

2007-01-25 Thread Mika
I think the original problem was that you uncompressed the cakephp files without using the "full directory" option. Those directories are in the compressed zip but they are empty so if you don't set that option (which is usually on by default in most compression software) then it will just ignore

Re: Error At Top Of Every Page

2007-01-25 Thread Samuel DeVore
http://apache.teachesme.com/~sdevore/FinderScreenSnapz001.png --~--~-~--~~~---~--~~ 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

Re: Error At Top Of Every Page

2007-01-25 Thread John David Anderson (_psychic_)
On Jan 25, 2007, at 12:33 PM, Dustin wrote: > > OK, well I finally understand what the error means and felt sorta > dumb. > I see that it was looking for a directory that didn't exist WITHIN > the > tmp folder. Specifically 'app\tmp\cache\models\'. > > I am in windows, so I didn't think it

Re: Error At Top Of Every Page

2007-01-25 Thread Samuel DeVore
they are included On 1/25/07, Dustin <[EMAIL PROTECTED]> wrote: > > OK, well I finally understand what the error means and felt sorta dumb. > I see that it was looking for a directory that didn't exist WITHIN the > tmp folder. Specifically 'app\tmp\cache\models\'. > > I am in windows, so I didn

Re: Error At Top Of Every Page

2007-01-25 Thread Chris Hartjes
On 1/25/07, Dustin <[EMAIL PROTECTED]> wrote: > > I guess there is no logic to create the folders if they don't exist? > Why aren't the tmp/cache folders including in the folder structure from > the git go? > > ie: why isn't it mentioned in the install or come included with the > downloadable arc

Re: Error At Top Of Every Page

2007-01-25 Thread Dustin
OK, well I finally understand what the error means and felt sorta dumb. I see that it was looking for a directory that didn't exist WITHIN the tmp folder. Specifically 'app\tmp\cache\models\'. I am in windows, so I didn't think it was permission problems like that. I added the cache and models

Re: Error At Top Of Every Page

2007-01-25 Thread Chris Hartjes
On 1/25/07, Dustin <[EMAIL PROTECTED]> wrote: > > That's odd, I don't even have a directory in app called tmp. That > folder doesn't come with the basic archive does it? > > I added the folder and made double-checked permissions, it all looks > ok. Still doing the same thing. > > I am using the

Re: Error At Top Of Every Page

2007-01-25 Thread Dustin
That's odd, I don't even have a directory in app called tmp. That folder doesn't come with the basic archive does it? I added the folder and made double-checked permissions, it all looks ok. Still doing the same thing. I am using the development install where everything is under the htdocs fol

Re: Error At Top Of Every Page

2007-01-25 Thread John David Anderson (_psychic_)
On Jan 25, 2007, at 12:11 PM, Dustin wrote: > > Hey, > > Cake noob here, but I'm very excited by everything I've seen so far > and > think it's far superior to any of the other PHP frameworks I've tried > so far. > > With that being said, I've had a frustrating pair of error messages at > the

Re: Dreamhost and CakePHP

2007-01-25 Thread DJ Spark
I have a few test websites running on dreamhost, and none had any problem. They worked with de default installation, and with the advanced , with app path outside the doc root... spark On 1/24/07, lance <[EMAIL PROTECTED]> wrote: > > On Jan 24, 5:51 pm, "Mark" <[EMAIL PROTECTED]> wrote: > > An

Error At Top Of Every Page

2007-01-25 Thread Dustin
Hey, Cake noob here, but I'm very excited by everything I've seen so far and think it's far superior to any of the other PHP frameworks I've tried so far. With that being said, I've had a frustrating pair of error messages at the top of every page I've built in Cake (from various tutorials). I

Re: idea: trace things into a log window

2007-01-25 Thread NOSLOW
I made a couple of changes while trying to get this working on a shared hosting server: 1. removed public/private statements before my functions. 2. check for log file existence before attempting to read it's contents (doh!). http://bin.cakephp.org/saved/2412 This should make it easier for anyo

Pagination in 1.2 using different models

2007-01-25 Thread [EMAIL PROTECTED]
I'm using the latest nightly of 1.2 (2007.01.24) and have a controller that uses several models, none of which are the default. I'd like to paginate search results on any of these models, but I'm not sure how to tell the controller which model classes to use. Does anyone know how to specify the

Re: how can I pass two or more params to controller

2007-01-25 Thread [EMAIL PROTECTED]
Here ya go: http://bakery.cakephp.org/articles/view/129 personally i do see benefits for using named parameters in terms of usability, even SEO. it's just more informational. other then that, it relieves the programmer for having to worry about the order in which get paramaters appear. for that

Re: Where to store application-wide array definition

2007-01-25 Thread Jon Bennett
> Can some point me to a location where i can store > an array so it can be evaluated in two or more > controllers and models ? you've got at least 2 options: 1. in app/app_controller.php 2. in /app/config/bootstrap.php j -- jon bennett t: +44 (0) 1225 341 039 w: http://www.jben.net/ iChat

Re: Where to store application-wide array definition

2007-01-25 Thread Mikee Freedom
what would be the purpose of such an array? just curious so we might be able to provide a solution that will suit. On 26/01/07, jyrgen <[EMAIL PROTECTED]> wrote: > > Can some point me to a location where i can store > an array so it can be evaluated in two or more > controllers and models ? > th

Re: ComboBox

2007-01-25 Thread Mikee Freedom
morning mate, your best place to start to look for help is searching through these groups. this topic has come up countless times before and an answer can be found by doing a little research. http://groups.google.com/group/cake-php/browse_thread/thread/b6c269d2b0c2a321/e9f98a33ce764209?lnk=st&q=

Re: Ajax to show hidden select Tag.

2007-01-25 Thread John David Anderson (_psychic_)
On Jan 25, 2007, at 10:41 AM, salimk786 wrote: > > Thanks John for that. > However, I'd like the form to be submitted when they choose something > from the drop down and based on that selection, my hidden field > appears > with the data based on their selection. > > For example. I have a list

Re: Same result from the same method with a different argument

2007-01-25 Thread Samuel DeVore
did you add the cache querie in that function like is in the paste now? http://bin.cakephp.org/view/2040641251 On 1/25/07, Steniskis <[EMAIL PROTECTED]> wrote: > > It is in the model, Sam > > http://bin.cakephp.org/view/2040641251"; target="_blank">here > is the link > > > > > -- == S. DeVore

Re: Model for my SQL-query

2007-01-25 Thread Chris Hartjes
On 1/25/07, Barma3 <[EMAIL PROTECTED]> wrote: > > > Step one is for you to define your models > > Step two is for you to define the associations between the two models > > so you can use the nicely formatted results array. > > Step three is to start messing around with passing selection criteria >

Re: Model for my SQL-query

2007-01-25 Thread Barma3
> Step one is for you to define your models > Step two is for you to define the associations between the two models > so you can use the nicely formatted results array. > Step three is to start messing around with passing selection criteria > via your model->find() method. What method of associat

Re: Ajax to show hidden select Tag.

2007-01-25 Thread salimk786
Thanks John for that. However, I'd like the form to be submitted when they choose something from the drop down and based on that selection, my hidden field appears with the data based on their selection. For example. I have a list of countries. I want it so that when they choose their country, th

Re: Model for my SQL-query

2007-01-25 Thread Chris Hartjes
On 1/25/07, Anggie Bratadinata <[EMAIL PROTECTED]> wrote: > > Model->findBySql($sql) > > -- C'mon now, that's cheating... Step one is for you to define your models Step two is for you to define the associations between the two models so you can use the nicely formatted results array. Step three

Re: how can I pass two or more params to controller

2007-01-25 Thread Chris Hartjes
On 1/25/07, the_woodsman <[EMAIL PROTECTED]> wrote: > > Hi Chris, > > I mean Cake specifically - i've seen the name:val syntax for GET > requests on Cake sites and examples, and never understood if this maps > them somehow, or is just to icnrease the usability of the URL... > I've done similar th

Re: how can I pass two or more params to controller

2007-01-25 Thread the_woodsman
Hi Chris, I mean Cake specifically - i've seen the name:val syntax for GET requests on Cake sites and examples, and never understood if this maps them somehow, or is just to icnrease the usability of the URL... On Jan 25, 3:30 pm, "Chris Hartjes" <[EMAIL PROTECTED]> wrote: > On 1/25/07, the_wood

Re: Model for my SQL-query

2007-01-25 Thread Anggie Bratadinata
Model->findBySql($sql) -- Anggie Bratadinata www.masputih.com I N D O N E S I A Barma3 wrote: > Could somebody tell me how to use Cake's model for this query: > > SELECT tmp_table.mfr, COUNT(item_sale.mfr) as count FROM (SELECT > DISTINCT mfr FROM item) tmp_table LEFT JOIN item_sale ON tmp_ta

Re: drawbacks of model coupling

2007-01-25 Thread jyrgen
thanks Chris for your hint. In the manual i couldn't find anything about this particular value for $recursive. it just tells about values between 1 and 3. j. > You can pass an optional variable called $recursive via your find > statements set to -1 to stop your find from pulling in any associat

Re: drawbacks of model coupling

2007-01-25 Thread jyrgen
Yes i have considered doing this, but in a certain way it appeared to me a bit unappropriate for my goal, which was just to avoid undefined model variables. In other words : why on earth should i unbind models from each other in order to get my different views straight ? And because the model d

Re: drawbacks of model coupling

2007-01-25 Thread jyrgen
thank you, i'll give it a try ! for now everything is running fine :-) jyrgen On 25 Jan., 15:58, "dkarlson" <[EMAIL PROTECTED]> wrote: > Or try this approach. I started using it because I wanted to recurse on > some associated models but not all. I didn't need the extra data, and > didn't want th

Re: how can I pass two or more params to controller

2007-01-25 Thread Chris Hartjes
On 1/25/07, the_woodsman <[EMAIL PROTECTED]> wrote: > > Hmm, sorry to hijack, but something I've never understood about HTTP > GET params - sometimes see them in the form > controller/action/name:val/name:val > > Does this have any real affect (map to the names for your action's > method params, f

Re: drawbacks of model coupling

2007-01-25 Thread the_woodsman
maybe i have to decouple certain models for certain views" Sounds like a good idea - have you seen the bind related methods of the model class? They allow you to add/remove model relations on the fly. See the manual on models for more info... On Jan 25, 11:02 am, "jyrgen" <[EMAIL PROTECTED]> wro

Model for my SQL-query

2007-01-25 Thread Barma3
Could somebody tell me how to use Cake's model for this query: SELECT tmp_table.mfr, COUNT(item_sale.mfr) as count FROM (SELECT DISTINCT mfr FROM item) tmp_table LEFT JOIN item_sale ON tmp_table.mfr = item_sale.mfr GROUP BY tmp_table.mfr I have two tables. First for items, second for posts. Fina

Re: how can I pass two or more params to controller

2007-01-25 Thread the_woodsman
Hmm, sorry to hijack, but something I've never understood about HTTP GET params - sometimes see them in the form controller/action/name:val/name:val Does this have any real affect (map to the names for your action's method params, for example), or is it just for readability? On Jan 25, 12:48 pm,

Re: drawbacks of model coupling

2007-01-25 Thread dkarlson
Or try this approach. I started using it because I wanted to recurse on some associated models but not all. I didn't need the extra data, and didn't want the additional queries. http://bakery.cakephp.org/articles/view/185 D On Jan 25, 8:52 am, "Chris Hartjes" <[EMAIL PROTECTED]> wrote: > On 1/2

Re: Finally a good Editor for Windows

2007-01-25 Thread Mandy
crazylegs - That is not what I was talking about. I know we can do that. But, suppose I was editing a jsp file, so I opened it in the jsp editor. Now, I have a javascript snippet inside of it. And I would like to take advantage of js snippets and editing features that my js editor has. Then, I

Re: drawbacks of model coupling

2007-01-25 Thread Chris Hartjes
On 1/25/07, jyrgen <[EMAIL PROTECTED]> wrote: > > hi list, > > > But i ran into heavy trouble, because models are associated > in my design (i have authors and articles basically). > I had errors in my views of the type ("undefined index..."). > For example in a simple article index list of one au

Re: Same result from the same method with a different argument

2007-01-25 Thread Samuel DeVore
where is this function? is it in the model or the controller can you paste in http://bin.cakephp.org (will give better formatting and it's just nicer to read and edit) Sam D On 1/25/07, Steniskis <[EMAIL PROTECTED]> wrote: > > Thank you all for your smart answers. > According to your suggesti

Re: error in default.thtml

2007-01-25 Thread Samuel DeVore
Actaully you don't need to copy the app_controller from core, just make a new one that has just this class AppController extends Controller { var $components = array('Acl','Output'); // components you want for all controllers var $helpers = array('html', 'ajax'); //helpers

Re: how can I pass two or more params to controller

2007-01-25 Thread [EMAIL PROTECTED]
:) I forgot that ... what a shame.. thx anyway On 1月25日, 下午8时09分, "Dr. Tarique Sani" <[EMAIL PROTECTED]> wrote: > On 1/25/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > > how can I pass two or more params to > > controller?http://blah.com/controller/action/param1/param2 > > HTH > Tarique

Re: bake.php script writes models, but not controller or views

2007-01-25 Thread biesbjerg
Hi miggs, I recently had this problem. Turns out I had made a copy of a model (backed up app/models/media_folder.php as app/models/media_folder - Copy.php) I deleted this file and everything worked fine again. Guess app/models is only for models, eh? ;-) On Jan 17, 11:09 pm, "miggs" <[EMAIL P

Re: how can I pass two or more params to controller

2007-01-25 Thread heberm
And in your controller you will have function action($param1,$param2){ //your code... } Regards, Heber On 25 jan, 10:09, "Dr. Tarique Sani" <[EMAIL PROTECTED]> wrote: > On 1/25/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > > how can I pass two or more params to > > controller?http://b

Re: Wizard creation headaches ... validation and save problems. How do I do this?

2007-01-25 Thread Dr. Tarique Sani
On 1/25/07, Flexewebs <[EMAIL PROTECTED]> wrote: > Using this piece of code: > > tagErrorMsg('mail_code', 'Mail code is required') ?> Try tagErrorMsg('Order/mail_code', 'Mail code is required') ?> Tarique = PHP for E-Biz: http://sanisof

Re: how can I pass two or more params to controller

2007-01-25 Thread Dr. Tarique Sani
On 1/25/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > how can I pass two or more params to controller? http://blah.com/controller/action/param1/param2 HTH Tarique -- = PHP for E-Biz: http://sanisoft.com Cheesecake-Photoblog: htt

URLs with Ajax confusion

2007-01-25 Thread quincy
Hi, I was recently using $this->render("xyz", "ajax") until i realised that if a user typed a URL directly it would render a messed up non-ajax page. So I promptly removed the "ajax" parameter and now the pages render correctly when the URL is entered directly. I take it from my travels here tha

Re: Wizard creation headaches ... validation and save problems. How do I do this?

2007-01-25 Thread Flexewebs
Just to clarify. Using this piece of code: tagErrorMsg('mail_code', 'Mail code is required') ?> Gives me this error now: Notice: Undefined offset: 1 in /var/www/html/white_label/cake/libs/view/helpers/html.php on line 949 I have set mail_code with in the controller using: $this->Order->set('

drawbacks of model coupling

2007-01-25 Thread jyrgen
hi list, with your help and guidelines i was able to add checkbox data un/serialisation methods via the beforeSave() and afterFind() model callbacks. But i ran into heavy trouble, because models are associated in my design (i have authors and articles basically). I had errors in my views of the

Re: how to acess attribution in join table

2007-01-25 Thread [EMAIL PROTECTED]
I figure a better way we can still use hasAndBelongsToMany association,and get the Song and Chart ids and then use them to find out the other attribution through the join table model ChartsSong. On 1月25日, 下午1时55分, "Grant Cox" <[EMAIL PROTECTED]> wrote: > The only way I have done it is to chang

how can I pass two or more params to controller

2007-01-25 Thread [EMAIL PROTECTED]
how can I pass two or more params to controller? any help is appr. --~--~-~--~~~---~--~~ 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 fro

Where to store application-wide array definition

2007-01-25 Thread jyrgen
Can some point me to a location where i can store an array so it can be evaluated in two or more controllers and models ? thanks very much jyrgen --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To

Re: View caching, routes and perfomance issues

2007-01-25 Thread Dr. Tarique Sani
On 1/25/07, Klaus <[EMAIL PROTECTED]> wrote: > > Do you mean is not working for login forms? > > No. A cached view should be deleted anytime an INSERT, UPDATE or DELETE > operation is done by it's related model True - my question was specific about the login form - I presume that login will just

Re: View caching, routes and perfomance issues

2007-01-25 Thread Klaus
> > First of all, the routing mechanism -and please correct me if I'm > > wrong- is not correctly working with view caching. I make heavy use of > > routes in the shake of user friendlyness and search engine > > optimization, so the 'controller/view/parameter' paradigm doesn't fit > > my URIs in m

Re: A new music thing with CakePHP

2007-01-25 Thread Sam Sherlock
Hi Tom, That good work indeed very expansive too. Seems to not be working right now unless you click that top 25. The other day I was really impress with the range of results. Are having to make a xml file or add each artist / band to a db? for example Iggy returned a number of stuff, but search

Re: Same result from the same method with a different argument

2007-01-25 Thread Steniskis
Thank you all for your smart answers. According to your suggestion, Samuel, I tried $this->cacheQueries = false; But it did not change the result. Djiize, I can't use $this->Agent->findAllByTypeId(1) here is my function function listedesagents ($role=null){ $this->sql_desagents = $this->findAll

Re: how to make bake in tables as 'tb_pedidos' and 'tb_pedidos_itens'?

2007-01-25 Thread mindcharger
Let's keep it in English, please... It's better a "Bad English" than "No English". If it's "Bad English" everyone can understand and help...if it's Portuguese or whatever language, only those who speak that language will be able to follow. You are free to use "Reply to Author" and speak whateve

Re: Wizard creation headaches ... validation and save problems. How do I do this?

2007-01-25 Thread Flexewebs
Related query I have now is this: I seem to have got the logic/syntax of the validates() within my controller working now using the above snippet of code (I am not using the FormWizard class). So what happens now is that I get the controller to carry out correct validation based on my model rule

Re: Finally a good Editor for Windows

2007-01-25 Thread [EMAIL PROTECTED]
On Jan 24, 11:34 pm, "Grant Cox" <[EMAIL PROTECTED]> wrote: > Is there really no undo/redo? Seems like a surprising omission, even > from an alpha release. sorry but that doesn't much sense to me. the product is still in very early stage of development, miles away from being finished. If you fi

Re: error in default.thtml

2007-01-25 Thread kabturek
Hi On Jan 25, 6:58 am, "lukemack" <[EMAIL PROTECTED]> wrote: > thanks guys - i resolved it by adding the helpers in > cake\app_controller.php. what would be the point of having this in the > \app folder? does it override the default one? You shouldn't edit anything in the /cake folder - these are

Re: Finally a good Editor for Windows

2007-01-25 Thread CraZyLeGs
> In Eclipse I am not sure you can bind a file with a > phpEditor/cssEditor/javascriptEditor etc at the same time? Sure you can. even multiple editors for the same type of files. rightclick open with.. Eclipse for project Management and just uh-huh everything. NotePad++ for quick rightclick open

obAuth Session Errors

2007-01-25 Thread Makea
Anyone know why I'm getting session errors with obAuth? Sessions work fine (doing a print_r($_SESSION) with obAuth disabled), just pukes with obAuth: Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /Library/WebServer/Do

Re: Bake doesn't show all available tables

2007-01-25 Thread Preloader
Hi Tom, thank you for your hints, but I still have the problem. The tables really have been generated (I checked that in the MySQL-Query-Browser), I even filled them with data. I will try to drop the database und start the whole project (it's the "Cook up Web sites fast with CakePHP" tutorial b