Re: Session - losing value after redirect

2007-09-13 Thread Grant Cox
Good point. Is the issue that browsers will see the Location header, and ignore the Set-Cookie header, or is it that PHP does not even output the Set-Cookie header before the exit()? If the latter, I would have thought that having $this->Session->initialise() <- well, this happens implicitly .

Re: Undefined index after query

2007-09-13 Thread Geoff Ford
$this->set('posts', $this->Post->findAll(array("title" => "LIKE '%widget%'")); Geoff -- http://lemoncake.wordpress.com On Sep 14, 8:28 am, "Samuel DeVore" <[EMAIL PROTECTED]> wrote: > your query does not create returned data in a form that CakePHP > understands to build it's data structure for.

Re: Session - losing value after redirect

2007-09-13 Thread Dr. Tarique Sani
On 9/14/07, Grant Cox <[EMAIL PROTECTED]> wrote: > > The issue with lost sessions often comes down to the SessionComponent > being quite strict, and destroying the session if the user agent > changes. Of course, the user agent shouldn't really change, but with > Ajax calls and whatnot it can happ

Re: Session - losing value after redirect

2007-09-13 Thread Grant Cox
The issue with lost sessions often comes down to the SessionComponent being quite strict, and destroying the session if the user agent changes. Of course, the user agent shouldn't really change, but with Ajax calls and whatnot it can happen. To test, comment out the lines

Default form elements for data types

2007-09-13 Thread loki_mdog
Is there any URL out there that lists the different form elements that are generated via scaffolding or bake.php for given data types out of the database? Will any ever be radio buttons? Thanks, Matt -- View this message in context: http://www.nabble.com/Default-form-elements-for-data-types-t

I can no longer directly access the index method?

2007-09-13 Thread Aaron Shafovaloff
"You are seeing this error because the private class method index should not be accessed directly." Apparently this is part of the latest SVN update of 1.2. Ideas? Thoughts? Explanation? Thanks, Aaron --~--~-~--~~~---~--~~ You received this message because you

Re: Undefined index after query

2007-09-13 Thread Samuel DeVore
your query does not create returned data in a form that CakePHP understands to build it's data structure for. set debug level to 2 and see what cake does On 9/13/07, Chris <[EMAIL PROTECTED]> wrote: > > Hi Guys > > Sorry for the NEwbie question, I'm now 2hours into my CakePHP'ing. > Anyway I woul

Undefined index after query

2007-09-13 Thread Chris
Hi Guys Sorry for the NEwbie question, I'm now 2hours into my CakePHP'ing. Anyway I would like to be able to perform a moderately complex SQL query on my database. But I'm taking little baby steps so am trying to just do an SQL LIKE search so my Controller looks like... function index()

Re: New Router usage as of 5535 $Route->connectNamed()

2007-09-13 Thread [EMAIL PROTECTED]
On Sep 13, 5:13 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > I still don't really know whether this is all by design, but in order > to get PaginatorHelper working I had to add elements for 'page' and > also 'step', which Paginator uses, in order for links to form > correctly. > > Router

Re: Strange routes/Router::url() behavior

2007-09-13 Thread [EMAIL PROTECTED]
I still don't really know whether this is all by design, but in order to get PaginatorHelper working I had to add elements for 'page' and also 'step', which Paginator uses, in order for links to form correctly. Router::connectNamed(array('step', 'page')); A regex match can be added as the value

Re: Session - losing value after redirect

2007-09-13 Thread [EMAIL PROTECTED]
Correction: This also seems to happen even after calling $this->redirect(...). I've never noticed this hapenning before. So lost. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this

EmailComponent: UTF-8 and text-only mail

2007-09-13 Thread Preloader
Hello Bakers, I try to send a text only mail via the EmailComponent in Cake 1.2: $this->Email->sendAs = 'text'; $this->Email->charset = 'utf-8'; But the mail seems to be sent as ISO-8859-1, not UTF-8 If i send both, html AND text ... ... $this->Email->sendAs = 'both'; ... ... all works fine.

Re: Session - losing value after redirect

2007-09-13 Thread [EMAIL PROTECTED]
Wow, really ironic that you just posted this, as I was about to post a thread on the exact same topic. I am trying to integrate with Paypal. The paypal integration has gone pretty smooth, but when I use the Paypal Express Checkout (when you pay for something with your paypal account rather than a

Re: mysql union equivalent?

2007-09-13 Thread Mike Green
Well, looks like the solution is: override the findAll function in the model, to give the paginator what I want it to have, not what cake wants it to have :) I'll see how I get on tomorrow, but I suspect it will work exactly as the theory suggests. Mike On 13/09/2007, Mike Green <[EMAIL PROTE

Re: Release: 1.1.17.5612

2007-09-13 Thread Jeff
It seems like their new releases have a hard time baking. I always end up using an old bake script. Sometimes, you have to get the cake code from a nightly release. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "

Re: table names

2007-09-13 Thread Samuel DeVore
try looking in the manual ;) http://manual.cakephp.org/chapter/models On 9/13/07, thanuja <[EMAIL PROTECTED]> wrote: > > Is it a requirement in cakePHP that table names to be plural? If not > how do I tell the model to look for a specific table? > > Thanks > > > > > -- (the old fart) the ad

table names

2007-09-13 Thread thanuja
Is it a requirement in cakePHP that table names to be plural? If not how do I tell the model to look for a specific table? Thanks --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this g

Re: Session - losing value after redirect

2007-09-13 Thread majna
I have same problem with losing session key value, between two pages/ clicks, sometimes random 1.1.17, (same for 1.1.16, 1.1.15...) and ONLY for session set to "database" On Sep 13, 10:59 am, Milamber <[EMAIL PROTECTED]> wrote: > Cake Version 1.17.X, PHP5 > > Any ideas what could be causing t

Re: The forbidden hack? | An attempt to redesign Cake View handling

2007-09-13 Thread majna
View this snippethttp://cakeforge.org/snippet/detail.php?type=packagever&id=44 There is custom view class cjsView.php. On Sep 13, 7:23 pm, DanielSun <[EMAIL PROTECTED]> wrote: > I am extreemly sorry for this mess. I must say I posted all the > messages ONCE. even google isn't what it used to be :

Re: Updating related select / combo boxes

2007-09-13 Thread majna
http://www.devmoz.com/blog/2007/04/04/cakephp-update-a-select-box-using-ajax/#comment-79 On Sep 13, 4:19 pm, xevian <[EMAIL PROTECTED]> wrote: > I'm trying to get 2 related select / combo boxes to work together. > What I want to achieve is when a user picks a city from a dropdown > select box the

Re: Admin Implementation.

2007-09-13 Thread DJ Spark
These steps will help: 1. uncomment the admin route in config.php: define('CAKE_ADMIN', 'admin'); 2. bake the admin stuff (Models, views, controllers) the admin views have a 'admin' prefix to the files: admin_index.ctp they will use the default layout. to change that, step 3 3. copy the default

Re: Admin Implementation.

2007-09-13 Thread DGPhoebus
Actually... you know what... it does help. I have known about MVC for a while but never used it until now. The whole process has mainly been forcing myself to change my way of doing things and thinking things. And after reading what you said about building two sets of code I agree... I am frigg

Re: The forbidden hack? | An attempt to redesign Cake View handling

2007-09-13 Thread DanielSun
I am extreemly sorry for this mess. I must say I posted all the messages ONCE. even google isn't what it used to be :) I know that hacking core is not the thing to do. That is why i am trying hard to think of the way arround. Thanks Cris. But only passing variables TO the view doesn't help much h

Include Rows From The Model

2007-09-13 Thread axpen
Ok my problem is this; I would like to get a row from a from another table who has the same ID as my current row. Let me throw some ASCII art for you to see: Table 1 +ID +... Table 2 +ID +... Now this would be simple if Table 1 had a field like table_2_id, however this is not the case. I

Re: Admin Implementation.

2007-09-13 Thread Chris Hartjes
On 9/13/07, DGPhoebus <[EMAIL PROTECTED]> wrote: > > Thanks French. So by this method you would still have to build the > "Admin" functions into the front end of the site (only viewable to > admin users.) ? No separate admin area? Correct. But I don't know why you call it the "front end of the

Re: Admin Implementation.

2007-09-13 Thread DGPhoebus
Thanks French. So by this method you would still have to build the "Admin" functions into the front end of the site (only viewable to admin users.) ? No separate admin area? Daniel On Sep 13, 12:26 pm, fr3nch13 <[EMAIL PROTECTED]> wrote: > A simple way to do this is to use the admin routing. >

Re: Admin Implementation.

2007-09-13 Thread fr3nch13
A simple way to do this is to use the admin routing. so /admin/users/index would look like so: checkAdmin(); other stuff here } } ?> This is how i do it in most of my apps for simple auth when acl seems like using a sledge hammer to put a pin in a wall French On Sep 13, 11:06 am, DGP

Re: mysql union equivalent?

2007-09-13 Thread fr3nch13
You can use $this->Model->query(); However, it won't return any dependent models with it. http://manual.cakephp.org/chapter/models On Sep 13, 12:03 pm, Mike Green <[EMAIL PROTECTED]> wrote: > Hi folks > > I want to query two tables at the same time, mysql lets me do this > with: > > SELECT name,

mysql union equivalent?

2007-09-13 Thread Mike Green
Hi folks I want to query two tables at the same time, mysql lets me do this with: SELECT name,age FROM football UNION SELECT name,age FROM baseball which will produce something like this: nameage John20 Alex21 Robort 23 Reid16 Greek 19 ( shamelessly stolen from http://www.

Re: mysql union equivalent?

2007-09-13 Thread Mike Green
If you can pass a custom query to the paginator, then yes that would work fine, but I'm not using $this->Model-> anything, I'm only using $this->paginate Mike On Sep 13, 5:13 pm, fr3nch13 <[EMAIL PROTECTED]> wrote: > You can use $this->Model->query(); > However, it won't return any dependent m

Re: What is __(), __c() etc ?

2007-09-13 Thread Dateve
I have no idea why the same post got posted 2 extra times, I only hit the submit button once and did not use the back button. On Sep 13, 8:12 am, Dateve <[EMAIL PROTECTED]> wrote: > Can someone please point me in the right direction so I can read more > about these style functions. I am using cak

Re: What is __(), __c() etc ?

2007-09-13 Thread Chris Hartjes
On 9/13/07, Dateve <[EMAIL PROTECTED]> wrote: > > Can someone please point me in the right direction so I can read more > about these style functions. I am using cake 1.2 for the first time, > and I noticed that sometimes __(something) gets called. What is this / > are these functions used for? >

What is __(), __c() etc ?

2007-09-13 Thread Dateve
Can someone please point me in the right direction so I can read more about these style functions. I am using cake 1.2 for the first time, and I noticed that sometimes __(something) gets called. What is this / are these functions used for? Thanks. --~--~-~--~~~---~--

Re: Novice To cakephp

2007-09-13 Thread Chris Hartjes
On 9/13/07, Subhradip <[EMAIL PROTECTED]> wrote: > > Hi Dudes, > I am new in cake php.can anybody send me sample source > code for cake php example 1) the manual's blog tutorial 2) lots of code examples at http://bakery.cakephp.org -- Chris Hartjes Senior Developer Cake Developmen

Novice To cakephp

2007-09-13 Thread Subhradip
Hi Dudes, I am new in cake php.can anybody send me sample source code for cake php example --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-ph

Admin Implementation.

2007-09-13 Thread DGPhoebus
I have been messing around with CakePHP for a little bit of time and most things are making sense. I am having a hard time though trying to figure out how to implement an Administrative area of the site where site management takes place. In the past I have created an / admin folder and password

Re: Why does this shitty Ggroups need 10 mins to post?

2007-09-13 Thread Danijel Kurinčič
well, i guess It really needs to be posted thru email. maybe google should consider using Cake :) On 9/13/07, booyah <[EMAIL PROTECTED]> wrote: > > > bwahah - 'momentarily' my arse... > > On Sep 13, 10:14 pm, DanielSun <[EMAIL PROTECTED]> wrote: > > Bad, wrong, dull, stupid Google Gropus. > > >

Re: Why does this shitty Ggroups need 10 mins to post?

2007-09-13 Thread booyah
i don't think it's just you... DanielSun wrote: > Bad, wrong, dull, stupid Google Gropus. > > Or is it just me?! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email t

Updating related select / combo boxes

2007-09-13 Thread xevian
I'm trying to get 2 related select / combo boxes to work together. What I want to achieve is when a user picks a city from a dropdown select box the city areas box is populated (similar to if you choose a stae another dropdown lists the cities that are in the state). I have looked at using the dev

Re: Why does this shitty Ggroups need 10 mins to post?

2007-09-13 Thread booyah
bwahah - 'momentarily' my arse... On Sep 13, 10:14 pm, DanielSun <[EMAIL PROTECTED]> wrote: > Bad, wrong, dull, stupid Google Gropus. > > Or is it just me?! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP

Re: Unknown modifier 'a' in ...libs/router.php on line 166

2007-09-13 Thread booyah
I am also getting a similar error. Did you find a solution? I had just 'baked' during a simple tutorial, and the bake asked me some questions about admin routing (which the tutorial said nothing about), to which I answered yes.Now I am getting this error: Warning: preg_match() [function.preg-ma

Re: Why does this shitty Ggroups need 10 mins to post?

2007-09-13 Thread Mike Green
try yahoo groups, ive seen messages delayed for over 4 days on there Mike On 13/09/2007, DanielSun <[EMAIL PROTECTED]> wrote: > > Bad, wrong, dull, stupid Google Gropus. > > Or is it just me?! > > > > > -- Mike Green Find yourself some misspelled eba

2 relations, where one relation belongs twice to the other

2007-09-13 Thread millZ
Hello, i've hopeness, that you can help me. the situation: i've 2 relations/tables 'members' and 'friends'. The last one has two foreign keys to 'members', so that is 'members' connected with himself, over the relation/table 'friends. It's clear, becaus every member can be a friend of anybody el

A problem with a model that belongs to another model twice

2007-09-13 Thread millZ
Hello, i've hopeness, that you can help me. the situation: i've 2 relations/tables 'members' and 'friends'. The last one has two foreign keys to 'members', so that is 'members' connected with himself, over the relation/table 'friends. It's clear, becaus every member can be a friend of anybody el

Re: 2 relations, where one relation belongs twice to the other

2007-09-13 Thread Chris Hartjes
On 9/13/07, millZ <[EMAIL PROTECTED]> wrote: > my PHP-Code > > PHP-Code: > // first DRAFT > var $belongsTo = array( > 'Member' => array( >'class' => 'Member', >'foreignKey' => 'mID1' > ), > 'Member' => array( >'class' => 'Member', >'fo

Re: The forbidden hack? | An attempt to redesign Cake View handling

2007-09-13 Thread Chris Hartjes
On 9/13/07, DanielSun <[EMAIL PROTECTED]> wrote: > > Meaning I cannot at all make my own view class and I should instead > use the allready instantiated view object __viewClass? Or should I > make a new instance of view just for the purpose of rendering layout. You can create your own view class

Re: A problem with a model that belongs to another model twice

2007-09-13 Thread millZ
I've found the solution. I've to use roles like this: // Rollenverteilung var $belongsTo = array( 'Member1' => array( 'class' => 'Member', 'foreignKey' => 'mID1' ), 'Member2' => array( 'class' => 'Member', 'foreignKey' => 'mID2' ), )

2 relations, where one relation belongs twice to the other

2007-09-13 Thread millZ
Hello, i've hopeness, that you can help me. the situation: i've 2 relations/tables 'members' and 'friends'. The last one has two foreign keys to 'members', so that is 'members' connected with himself, over the relation/table 'friends. It's clear, becaus every member can be a friend of anybody el

Dynamic session-time-out

2007-09-13 Thread mani
Hi All, How to set the session time-out value dynamicaly in (component)? Plz help me to resolve this --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-p

Re: The best way to back to the previous place?

2007-09-13 Thread Chris Hartjes
On 9/13/07, red <[EMAIL PROTECTED]> wrote: > > Some parts of my app need user to be logged in. So in this places I've > put links to 'log in' page. But after user log correctly, the app > always back to the main page (as I set it up). I want to back to > place, where the user was before login acti

Re: Suggestions on Time Helper (1.2)

2007-09-13 Thread Chris Hartjes
On 9/13/07, Charlie van de Kerkhof <[EMAIL PROTECTED]> wrote: > Should this be added to the time helper to make use of both? (date and > strftime)? > There's no need to fear putting in en enhancement ticket at trac.cakephp.org. Personally, I don't see the need for those two functions but (lucky

Re: The forbidden hack? | An attempt to redesign Cake View handling

2007-09-13 Thread DanielSun
Meaning I cannot at all make my own view class and I should instead use the allready instantiated view object __viewClass? Or should I make a new instance of view just for the purpose of rendering layout. And therefore I cannot bypass hacking of the core? On 12 sep., 16:19, nate <[EMAIL PROTEC

Why does this shitty Ggroups need 10 mins to post?

2007-09-13 Thread DanielSun
Bad, wrong, dull, stupid Google Gropus. Or is it just 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 from this g

The best way to back to the previous place?

2007-09-13 Thread red
Some parts of my app need user to be logged in. So in this places I've put links to 'log in' page. But after user log correctly, the app always back to the main page (as I set it up). I want to back to place, where the user was before login action. I can of course add optional param to the /users/

Re: The forbidden hack? | An attempt to redesign Cake View handling

2007-09-13 Thread Chris Hartjes
On 9/13/07, DanielSun <[EMAIL PROTECTED]> wrote: > > this f* google groups drive me crazy. this is the 4th post that will > probably NOT BE POSTED. > (well, if you are reading this a miracle has happened ...) > > Anyone has similar troubles? Never. But I always post via email not via the Google

Re: The forbidden hack? | An attempt to redesign Cake View handling

2007-09-13 Thread DanielSun
trying in IE6 test? (working?) awake mr Google? On 12 sep., 16:19, nate <[EMAIL PROTECTED]> wrote: > You're doing it wrong. Cake handles the loading and instantiating of > view classes internally. > > On Sep 12, 9:54 am, DanielSun <[EMAIL PROTECTED]> wrote: > > > > > GWOO: > > I have played a l

News Aggregator in CakePHP

2007-09-13 Thread [EMAIL PROTECTED]
Hi, I created news aggregator site(similar to Digg, Reddit) using CakePHP, Ext and YUI. http://news.adversitement.nl/ Some of the features: * CakePHP 1.2 based * Layout using ExtJS * History and Back-button management using YAHOO history * Endless scrolling, i.e. there is no pagination, new da

Re: The forbidden hack? | An attempt to redesign Cake View handling

2007-09-13 Thread DanielSun
this f* google groups drive me crazy. this is the 4th post that will probably NOT BE POSTED. (well, if you are reading this a miracle has happened ...) Anyone has similar troubles? On 12 sep., 16:19, nate <[EMAIL PROTECTED]> wrote: > You're doing it wrong. Cake handles the loading and instan

Re: uploading files

2007-09-13 Thread Gummie
rtanz, How did you fix the PEAR problem? Thanks On 5 aug, 16:05, rtanz <[EMAIL PROTECTED]> wrote: > Ok fixed the PEAR problem, now it seems to work without problem, > however the file is not being uploaded for some reason. Where should i > be adding the upload folder? Am i correct in putting th

Disabling session once login page accessed through browser back button.

2007-09-13 Thread Ravi
Hai, I want to disable going to inner pages once user comes to login page using browser back button. Scenario is like this: 1. User goes to login page 2. Enters authentication info and goes to other pages like users/ viewing profiles, editing etc. 3. Now user clicks on b

Session - losing value after redirect

2007-09-13 Thread Milamber
Cake Version 1.1.17.X, PHP 5. Got any ideas why this can happen? --~--~-~--~~~---~--~~ 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

Session - losing value after redirect

2007-09-13 Thread Milamber
Cake Version 1.17.X, PHP5 Any ideas what could be causing this? --~--~-~--~~~---~--~~ 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 t

Re: Overriding models / pretending to delete rows

2007-09-13 Thread MonkeyGirl
Hi! Thanks for your reply. > Oh, and as a tip, all Cake find functions actually end up using > findAll - including exists, findCount, find, etc. So just change > findAll - you don't have to change each of them separately. Thank you, I'll take out the findCount() overriding bit then! Does it als

Suggestions on Time Helper (1.2)

2007-09-13 Thread Charlie van de Kerkhof
Hi all, Before I add a enhancement ticket in trac I would like to know what you people do in this situation: I have a database datetime '2007-09-13 13:24:12' en I would nicely transform that on a webpage to: 'September 13th 13:24h' I used the Time Helper like this: $time->format('F dth H:i', $db_

Re: limit functions to user id

2007-09-13 Thread Mike Green
I wholly recommend this wiki page http://wiki.kabturek.info/authcomponent Mike On Sep 13, 5:06 am, seans9 <[EMAIL PROTECTED]> wrote: > I'm new to cakephp. What is the best way to control content based on a > user id? I've read all about authenticating which i'm sure I won't > have a problem set

Re: Word Verification

2007-09-13 Thread MJ Ray
"Dr. Tarique Sani" <[EMAIL PROTECTED]> wrote: > On the flip side - CAPTCHAs are an irritant to the real users > Anyone considering using blurry-words should go read the W3C advice http://www.w3.org/TR/turingtest and think about people with visual impairments. If you label an eye-test as a "huma

duplicate foreign key

2007-09-13 Thread Rahul
I have one table for say Record. I need to maintain two foreign key say User_id for this record table. One user_id will hold the id of the user who will create that record and another user_id will hold that user id who will last modify the record. In this case, record table must have two HasMany

Re: Help with Google Checkout Integration

2007-09-13 Thread Penfold
Hi, This might be no help, but there's a paypal tutorial on the bakery. You could use this as a reference on how it can be used in a controller to model one for google. http://bakery.cakephp.org/articles/view/paypal-direct-payment-api-component Ian On 12 Sep, 06:46, "Aaron Roberson" <[EMAIL PR