Question about Fixture subdirectories in 2.5.5
Hi all, I upgraded from 2.4.5 to 2.5.5 to enjoy the benefit of using subdirectories to organize my test fixtures. However, I'm having difficulties with getting Cake to find my fixtures once they've been moved to subdirectories. This seems to be due to the fact that my Fixture names and class names start with uppercase letters. For example, I might have a class called *MultipleUsersFixture* in a file */Test/Fixture/User/MultipleUsersFixture.php* . When I try to reference this fixture in a test by adding *'User/multiple_users'* to the $fixtures array, I get the following error: Referenced fixture class User/multipleUsers (Test/Fixture/User/multipleUsersFixture.php) not found Digging into the Cake code a little bit, it looks like the Inflector ultimately calls ucwords on the fixture class name, which does not capitalize any words immediately following a '/' character. Is this a situation where I need to rename all of my classes and filenames to comply with the constraints placed on me by the inflector? Or am I missing something here? I've googled around and don't see many examples out there of fixtures that use subdirectories (including the Cake framework itself). Thanks! -- Like Us on FaceBook https://www.facebook.com/CakePHP Find us on Twitter http://twitter.com/CakePHP --- You received this message because you are subscribed to the Google Groups "CakePHP" group. To unsubscribe from this group and stop receiving emails from it, send an email to cake-php+unsubscr...@googlegroups.com. To post to this group, send email to cake-php@googlegroups.com. Visit this group at http://groups.google.com/group/cake-php. For more options, visit https://groups.google.com/d/optout.
Re: Setting the years
Is this working with cake 1.1.19's dateTimeOptionTag ? cause it doesn't seem to work for me... Here is the piece of code: dateTimeOptionTag('Student/date_of_birth', 'MDY', 'NONE', null, array('minYear' => '1970', 'maxYear' => '2008')) ?> Did I do anything wrong? Thank you, On Jul 12, 5:34 pm, Vixy <[EMAIL PROTECTED]> wrote: > I tried changing those, and it doesnt get passed 1973 and 2007. > Thanks, Vix > > On Jul 11, 11:06 pm, "Amit Badkas" <[EMAIL PROTECTED]> wrote: > > > 2008/7/12 Vixy <[EMAIL PROTECTED]>: > > > > Hi, In the HTML Helper, I found this code: > > > function yearOptionTag($tagName, $value = null, $minYear = null, > > > $maxYear = null, $selected = null, $selectAttr = null, $optionAttr = > > > null, $showEmpty = true) { > > > if (empty($selected) && ($this->tagValue($tagName))) { > > > $selected = date('Y', > > > strtotime($this->tagValue($tagName))); > > > } > > > > $yearValue = empty($selected) ? ($showEmpty ? NULL : > > > date('Y')) : > > > $selected; > > > $currentYear = date('Y'); > > > $maxYear = is_null($maxYear) ? $currentYear + 11 : $maxYear > > > + 1; > > > $minYear = is_null($minYear) ? $currentYear - 60 : > > > $minYear; > > > > if ($minYear > $maxYear) { > > > $tmpYear = $minYear; > > > $minYear = $maxYear; > > > $maxYear = $tmpYear; > > > } > > > > $minYear = $currentYear < $minYear ? $currentYear : > > > $minYear; > > > $maxYear = $currentYear > $maxYear ? $currentYear : > > > $maxYear; > > > > for ($yearCounter = $minYear; $yearCounter < $maxYear; > > > $yearCounter+ > > > +) { > > > $years[$yearCounter] = $yearCounter; > > > } > > > > return $this->selectTag($tagName . "_year", $years, > > > $yearValue, > > > $selectAttr, $optionAttr, $showEmpty); > > > } > > > > This out puts a drop down box for my signup form. The years that show > > > up are from 1948 - 2018. This is a signup form and if someone is > > > signning up, how can they have thier birthday in 2018? So how can I > > > change it to this range: 1980-1994? > > > - As you have noticed in the code, you need to pass $minYear and $maxYear to > > method > > > -- > > Amit > > >http://amitrb.wordpress.com/http://coppermine-gallery.net/http://chee... --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" 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 options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
plugin overwrites cakephp app-controller with plugin app-controller.
I'm having issues with this. I need something to follow through my whole website, including my plugins as the cms software is plugin driven. However the app-controller in my authake plugin is overwriting everything the the main app-controller is doing. How do I inherit the main app-controller into my plugin? --~--~-~--~~~---~--~~ 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 options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: User management, authentication and ACL plugin/component/helper
Thanks for the offer, but last night it came down I think it might have been a South Africa internet problem again. :( LOL Thanks for the offer once again. So back to the topic though, I spent last night reading about ACL and finally got the whole understanding. However I was playing around with ACL last night, especially in the cake console and I find that I wasn't really able to replicate the tutorials examples, unless I did it their specific way. aro -> Root > Users > User::1 I'm going to install authcheck today... will keep updated. On Feb 21, 9:38 pm, "Sam Sherlock" <[EMAIL PROTECTED]> wrote: > I downloaded this package a while back; not using it not apt for my > pursposes > > I can email it to you off list if you like. > > confusingly I have to authake-app.tar.gz & authsample.zip > > On 21/02/2008, lucaspirola <[EMAIL PROTECTED]> wrote: > > > > > i cannot too, any news?! > > if someone can send me, i > > host ! > > > On 21 fev, 09:49, vince <[EMAIL PROTECTED]> wrote: > > > Hi, > > > > Cannot download the file on the website. :( > > > > On Feb 12, 4:14 pm, jakecake <[EMAIL PROTECTED]> wrote: > > > > > Hi all, > > > > > Here is the plugin to manage users/groups, registration, > > > > authentication,ACL, and the GUI to manage everything. > > > > >http://conseil-recherche-innovation.net/authake > > > > > This is in development so becareful before using it. I made this in > > > > few days to learn Cake (by the way, thanks to Marco Sbragi, I used its > > > > tutorial to learn). There are maybe some coding style errors, and the > > > > stability depends of the cake version fetched from the SVN... So > > > > please, don't hesitate to give feedback, patches, ideas, etc. > > > > > Here are some screenshots to give you a taste ;)http://conseil- > > recherche-innovation.net/download/authake/screenshots/ > > > > > Read you, > > > > Jakecake --~--~-~--~~~---~--~~ 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 options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: User management, authentication and ACL plugin/component/helper
Hi, Cannot download the file on the website. :( On Feb 12, 4:14 pm, jakecake <[EMAIL PROTECTED]> wrote: > Hi all, > > Here is the plugin to manage users/groups, registration, > authentication,ACL, and the GUI to manage everything. > > http://conseil-recherche-innovation.net/authake > > This is in development so becareful before using it. I made this in > few days to learn Cake (by the way, thanks to Marco Sbragi, I used its > tutorial to learn). There are maybe some coding style errors, and the > stability depends of the cake version fetched from the SVN... So > please, don't hesitate to give feedback, patches, ideas, etc. > > Here are some screenshots to give you a taste > ;)http://conseil-recherche-innovation.net/download/authake/screenshots/ > > Read you, > Jakecake --~--~-~--~~~---~--~~ 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 options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Cake PHP routing question
Hi all I have a question for the community : cakephp is not installed in the document root folder of my apache server. eg the document root folder is www and cake was installed in www/sub_folder. I found an article (http://www.chriscassell.net/log/2006/07/27/how_to_install_.html) which explains step by step what I should do to configure cake properly but the problem is it uses aliases and I cannot edit the httpd.conf file of the apache server. Anyone has a clue what I should do to configure cake properly ? Thank you, Vincent --~--~-~--~~~---~--~~ 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 options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Ajax form issue
Hi there, I'm trying to validate form data using ajax in cakephp. The form looks something like this : --- First name: input('Student/first_name', array('size' => '40'))?> tagErrorMsg('Student/fn_empty', 'First name is required.') ?> tagErrorMsg('Student/fn_len', 'First name must be at least two charcters long.') ?> submit('Register', array('url' => 'register', 'update'=>'register_student')); ?> --- I can see the form when I request http://www/mydomain.com/version2/students/register (mod_rewrite seems to work just fine) but when I submit the form, I get an error message: "The requested URL /home/xxx/www/version2/app/webroot/students/ register was not found on this server". The documentRoot of my server is set to /home/xxx/www, cake is installed in the "version2" subfolder. As you can imagine I don't want cake to look in the webroot folder but look for the register action of my students controller (http://www.mydomain.com/version8/students/ register). Any idea on how to fix that? --~--~-~--~~~---~--~~ 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 options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: session data gone after redirect
To fix this problem I just needed an exit(); call after the redirect. I have been searching the manual, wiki, irc, etc, but i finally found this information on a blog: http://cakebaker.wordpress.com/2006/08/28/dont-forget-to-exit-after-a-redirect/ and also 21 things I learned about cake: http://www.avatarfinancial.com/pages/cake/ This seems like an issue a newbie (like me) would run into, so I'm updaing this in hopes it might help someone else new to cakephp and php. --~--~-~--~~~---~--~~ 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 options, visit this group at http://groups.google.com/group/cake-php -~--~~~~--~~--~--~---
Re: session data gone after redirect
Ok so session management wasn't working at all before as I tested it with using regular php session management code. The problem was in my php.ini conf file. I changed the line to this: output_buffering = Off and regular php session management started working. the session ids were the same when i went from page to page. However with the cakephp simple auth tutorial my session ids still change from page to page upon redirect. i'm at a loss to figure it out. any ideas? On Oct 28, 1:57 pm, "vince" <[EMAIL PROTECTED]> wrote: > Ok so I hopped on the IRC and got some more information with > pr(session_id()); > > showed that i'm not getting the same session id accross requests. It > looks like it could have something to do with the way php is set up. i > was recommended to edit the enable-trans-id in my php.ini file. I > don't have that in my php.ini file. > > looks like it could be more of a setup problem. > > On Oct 28, 12:48 pm, "vince" <[EMAIL PROTECTED]> wrote: > > > I'm just triyng to get the basic auth working. While in the login() > > function I can read my session data fine be using > > $this->Session->read('User'). > > > However once I redirect to another function, index(), calling > > $this->Session->read('User') nothing. Similarly in my view: > > index.ththml if I use $this->Controller->Session->read('User') I get > > nothing. > > > Now, there is session data, which I can show by using > > print_r($this->Session->read()) but nothing in there for User. The > > same goes if I use php's $_SESSION. > > > I'm actually new to php and cakePHP, so I might be missing something > > simple. --~--~-~--~~~---~--~~ 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 options, visit this group at http://groups.google.com/group/cake-php -~--~~~~--~~--~--~---
Re: session data gone after redirect
Ok so I hopped on the IRC and got some more information with pr(session_id()); showed that i'm not getting the same session id accross requests. It looks like it could have something to do with the way php is set up. i was recommended to edit the enable-trans-id in my php.ini file. I don't have that in my php.ini file. looks like it could be more of a setup problem. On Oct 28, 12:48 pm, "vince" <[EMAIL PROTECTED]> wrote: > I'm just triyng to get the basic auth working. While in the login() > function I can read my session data fine be using > $this->Session->read('User'). > > However once I redirect to another function, index(), calling > $this->Session->read('User') nothing. Similarly in my view: > index.ththml if I use $this->Controller->Session->read('User') I get > nothing. > > Now, there is session data, which I can show by using > print_r($this->Session->read()) but nothing in there for User. The > same goes if I use php's $_SESSION. > > I'm actually new to php and cakePHP, so I might be missing something > simple. --~--~-~--~~~---~--~~ 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 options, visit this group at http://groups.google.com/group/cake-php -~--~~~~--~~--~--~---
session data gone after redirect
I'm just triyng to get the basic auth working. While in the login() function I can read my session data fine be using $this->Session->read('User'). However once I redirect to another function, index(), calling $this->Session->read('User') nothing. Similarly in my view: index.ththml if I use $this->Controller->Session->read('User') I get nothing. Now, there is session data, which I can show by using print_r($this->Session->read()) but nothing in there for User. The same goes if I use php's $_SESSION. I'm actually new to php and cakePHP, so I might be missing something simple. --~--~-~--~~~---~--~~ 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 options, visit this group at http://groups.google.com/group/cake-php -~--~~~~--~~--~--~---