RE: New CakePHP Application Launches
+1 on how nice the site looks, and seems fast. A good case study could be the search you have going on there. I've done some code to incorporate FULLTEXT searching (need to convert it to a behavior) which works very well, but still need some polishing before I publish it. -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar -Mensaje original- De: cake-php@googlegroups.com [mailto:[EMAIL PROTECTED] En nombre de Geoff Ford Enviado el: Jueves, 05 de Julio de 2007 03:36 a.m. Para: Cake PHP Asunto: Re: New CakePHP Application Launches And maybe consider a Case Study for the Bakery. We are always looking for good real-world examples of applications built on Cake. The site looks very nice as well. --~--~-~--~~~---~--~~ 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: New CakePHP Application Launches
Did you add it to http://groups.google.com/group/cake-php/web/cake-apps-sites-in-the-wild And maybe consider a Case Study for the Bakery. We are always looking for good real-world examples of applications built on Cake. The site looks very nice as well. Geoff -- http://lemoncake.wordpress.com On Jul 5, 3:00 pm, oms <[EMAIL PROTECTED]> wrote: > Thanks! > > It really needs some content right now, so would be great if bakers > from all over would contribute some articles! :) > > Omar > > On Jul 4, 7:24 pm, "Jonathan Langevin" <[EMAIL PROTECTED]> wrote: > > > just upon first glance, awesome looking site, gj! > > > On 7/4/07, oms <[EMAIL PROTECTED]> wrote: > > > > Hi all, > > > > We've just launchedwww.trippert.com-a travel community site built > > > using cakePHP. Please help us out by checking it out, giving us > > > feedback, and writing a few articles about your travels (or where you > > > live!). :) > > > > Thanks, > > > Omar --~--~-~--~~~---~--~~ 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: URL Rewriting
On Jul 5, 4:41 am, "Feris Thia" <[EMAIL PROTECTED]> wrote: > Hi All, > > I'm a newbie to cakephp, and have learnt that cake's URL with .htaccess > looks like this : > > http://myhost/controllername/action/param1 > > can we modified it to > > http://myhost/param1/controllername/action > > Thanks, > > Feris Routes. http://manual.cakephp.org/chapter/configuration --~--~-~--~~~---~--~~ 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: "webroot" getting appended in subsequent links?
Are you using symlinks by any chance? If yes then point the symlink to the app folder rather than the outside folder - this had solved the problem for me Tarique On 7/4/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > > I'm curious about this too, Rajesh. > > It actually causes my sessions to expire when the webroot link is > appended. Has anyone fixed this before? > > Thanks, > Wilson > > On Jul 4, 11:32 am, "R. Rajesh Jeba Anbiah" > <[EMAIL PROTECTED]> wrote: > > I have setup like this: > > > > ROOT\.cake\ > > ROOT\public_html\ > > > > 'CAKE_CORE_INCLUDE_PATH' set to ROOT.DS.'.cake' in ROOT\public_html > > \webroot\index.php > > > > When I accesshttp://foo.com/, the subsequent links are appended > > with "webroot", sayhttp://foo.com/webroot/users/login > > > > I have trapped up to dispatcher, but still couldn't find the > > reason. Could anyone has any idea? TIA > > > > -- > > > > Email: rrjanbiah-at-Y!comBlog: http://rajeshanbiah.blogspot.com/ > > > > > -- = Cheesecake-Photoblog: http://cheesecake-photoblog.org PHP for E-Biz: http://sanisoft.com = --~--~-~--~~~---~--~~ 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: New CakePHP Application Launches
Thanks! It really needs some content right now, so would be great if bakers from all over would contribute some articles! :) Omar On Jul 4, 7:24 pm, "Jonathan Langevin" <[EMAIL PROTECTED]> wrote: > just upon first glance, awesome looking site, gj! > > On 7/4/07, oms <[EMAIL PROTECTED]> wrote: > > > > > Hi all, > > > We've just launchedwww.trippert.com- a travel community site built > > using cakePHP. Please help us out by checking it out, giving us > > feedback, and writing a few articles about your travels (or where you > > live!). :) > > > Thanks, > > Omar --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
Problem with Ajax: observeField
I use $Ajax->observeField, with Option['with'=>'type_id'], however, an error reported: Form.Element.Serializers[method] is not a function. But from the manual, to use Option['with'] of phpCake Ajax, only need to call by DOM ID, and in my case 'type_id' is. What is the problem? By the way, where can I find examples for using Cake's Ajax Helper? I think there should some usage examples in Cake's manual. --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
URL Rewriting
Hi All, I'm a newbie to cakephp, and have learnt that cake's URL with .htaccess looks like this : http://myhost/controllername/action/param1 can we modified it to http://myhost/param1/controllername/action Thanks, Feris --~--~-~--~~~---~--~~ 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: New CakePHP Application Launches
just upon first glance, awesome looking site, gj! On 7/4/07, oms <[EMAIL PROTECTED]> wrote: > > > Hi all, > > We've just launched www.trippert.com - a travel community site built > using cakePHP. Please help us out by checking it out, giving us > feedback, and writing a few articles about your travels (or where you > live!). :) > > Thanks, > Omar > > > > > --~--~-~--~~~---~--~~ 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: admin backend best practice
On 7/4/07, citrus <[EMAIL PROTECTED]> wrote: > > I also prefer approach #1. Actually I use it in all of my mini > projects. > You know, I was just thinking that not only is #1 a good approach (build the admin stuff right into the app) but by putting ACL stuff in there you can also give some of your more trusted users access to "beta features" when you want to try out some new functionality. A lot of this stuff I've cribbed from the book "Getting Real" produced by the folks at 37 Signals. Yes, I know they are the people behind Ruby on Rails but they stay technology-neutral in that book. -- Chris Hartjes Senior Developer Cake Development Corporation My motto for 2007: "Just build it, damnit!" @TheBallpark - http://www.littlehart.net/attheballpark @TheKeyboard - http://www.littlehart.net/atthekeyboard --~--~-~--~~~---~--~~ 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: admin backend best practice
I also prefer approach #1. Actually I use it in all of my mini projects. To know exactly which actions a user is able to perform, I take advantages of SimpleAcl by Felix. Regards, On Jul 5, 3:09 am, danfreak <[EMAIL PROTECTED]> wrote: > Hey guys, > > I saw a couple of different approaches for building an admin backend: > > 1) exploit CAKE admin routes and then show the relative controllers > actions only if an user belongs to certain administrative groups > > 2) build 2 applications (frontend and backend) and then manage > everything from the backend > > What I was wondering with regard to method 2 is to avoid to duplicate > the models. > > Which method would you recomend? > > Cheers > > Dan --~--~-~--~~~---~--~~ 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: Going nuts on components
Thanks, it worked like a charm! Only one thing that I can't quite get to float; using ISO-8859-1 character set instead of UTF-8. I've tried changing the UTF-8 setting within the helper, but it seems as if it doesn't really care what I change it to. I'm using extended characters åäö as I live in Sweden and I'm trying to figure out how to solve this issue. Anyone got a hint for me? As I said, it works real good so no complaining at all there, just trying to figure out how to get the extended character set working. Would it perhaps mean I have to make changes in the regular expressions? Regards DrLaban On Jul 4, 4:18 am, Geoff Ford <[EMAIL PROTECTED]> wrote: > Here is the Bakery's implementation as a helper > :-https://cakeforge.org/plugins/scmsvn/viewcvs.php/trunk/bakery/views/h... > > Basically in the view you call $bbcode->format($this->data['ModelName'] > ['bbcode']); > > Geoff > --http://lemoncake.wordpress.com > > On Jul 4, 11:30 am, DrLaban <[EMAIL PROTECTED]> wrote: > > > Hey all and thank you for reading this post! > > > I'm a newbie on cakePHP but it's a really fascinating project and > > slowly I'm getting the hang of things. It might be that I'm going a > > bit too fast and get a bit ahead of myself, but really, I can't see > > why I have such problems with components. I'm trying to wrap my head > > around some other minor things, I'll mention them below. > > > Short: > > This is for a guestbook I've done. I need to interpret bbCode inside > > each users message and translate those into proper html. > > I can't really get the grips on what's needed for it to work, perhaps > > I'm looking in the wrong direction, but a component seems appropriate. > > > Longer: > > I've tried creating a component using the guide on cakePHP.org. Now, > > everything works after doing some extensive search on google and > > whatnot. I have problems in the Model/Controller/Component-block. If I > > add a file ("Guestbook.php") in the components folder, along with the > > code snippets from cakePHP.org I get a fatal error on MySQL telling me > > that 'startup' isn't a valid query. Someone in a newsgroup post > > mentioned that this could be due to the fact that I haven't defined > > the functions in the model. So, I added them there and everything is > > fins so far. But no matter what I add to the component file, I get > > errors until I add them to the model too. This makes the component > > file obsolete, since the functions become duplicated. > > What am I missing here? > > > Short 2: > > How do I access instance variables or variables in general? There > > aren't getters in cake as far as I've gathered and I find it tricky to > > figure out how to get to a specific piece of data within a variable in > > a class. I'm sure there's an easy way to read data from variables, but > > I just haven't found it. > > > Thanks for your time, I hope I didn't mess everything up with my > > descriptions! > > > Regards > > DrLaban --~--~-~--~~~---~--~~ 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: Shopping Cart
To write some data to the session, use $this->Session->write(name, data) To read from the session: $this->Session->read(name) To check if a variable exists in the session or not: $this->Session- >check(name) For more info, have a look at Cake's API. On Jul 5, 7:36 am, r557 <[EMAIL PROTECTED]> wrote: > I'm creating a shopping cart to extend a current project completed in > CakePHP. > > I'm having some issues with regards to understanding how Sessions work > around CakePHP and how to use them. The trouble i'm having is, I am > not able to find some practical examples regarding how to store > session data around Cake. > > For example, i have a controller: > class ProductsController extends AppController { > > function view($id = null) { > $this->layout = 'main'; > if(!$id) { > $this->Session->setFlash('Invalid id for Product.'); > $this->redirect('/products/index/'); > } > $this->set('product', $this->Product->read(null, $id)); > } > ?> > > / view.thtml / > > > image('sundaymorning_cover.jpg', array('class' => > 'product_img')); ?> > > - $ $product['Product']['price']?> > > > > > I'm looking for a starting point to begin the process of integrating a > Shopping Cart Using Sessions. Not looking necessarily for a complete > how-to (would be nice if possible :)) but all i'm really looking for > is some assistance on how to integrate this. I haven't found much on > this topic as of yet, but if someone has any good resources please > share. --~--~-~--~~~---~--~~ 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 1.2 input wrapper div and field validation error
Hi, I was just wondering that field validation won't set an error class for the wrapper div of an input field, for highlightning the hole row or something like that. So i changed in form.php from line 518 and following: if(!empty($div)) { $divOptions = array('class'=>'input'); if (is_string($div)) { $divOptions['class'] = $div; } elseif (is_array($div)) { $divOptions = am($divOptions, $div); } if (in_array($this->field(), $this->fieldset['validates'])) { $divOptions = $this->addClass($divOptions, 'required'); } // here the magic happens if ($this->tagIsInvalid()) { $divOptions = $this->addClass($divOptions, 'form-error'); } } Did I miss something ? Regards, Andreas --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
Foreign models inside components and components
Hi there, I read in few comments in Bakery that it's not very good to use models inside other model's controllers and components. Can anybody explain the reason? And the question about using models inside component: I want component to return some fields from database, and I don't want to use php database requests, so is it possible to use model with my component? :) --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
New CakePHP Application Launches
Hi all, We've just launched www.trippert.com - a travel community site built using cakePHP. Please help us out by checking it out, giving us feedback, and writing a few articles about your travels (or where you live!). :) Thanks, Omar --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
mod_rewrite not working in all cases, error in RewriteBase causing File Not Found and 404
I've filed a bug report (#2858) and hopefully this will be fixed in the documentation soon. This drove me crazy for hours before I finally figured it out. I've changed the subject of my post to include some of the search terms I used while looking for help. Hopefully that will make it easier for others to find this post until the bug is fixed. On May 25, 4:57 pm, furiouslettuce <[EMAIL PROTECTED]> wrote: > It turns out that the documentation > athttp://manual.cakephp.org/chapter/installing > is wrong - you have to addRewriteBase/~username/ to both > the .htaccess as the root and in /app/webroot, wheras the > documentation says to only include it in the root .htaccess. I'm not > sure how to get it changed, so if anyone does know, I'm sure that > they'd appreciate being told. > > On May 25, 6:43 pm, furiouslettuce <[EMAIL PROTECTED]> wrote: > > > I've been attempting to follow the blog tutorial, simply to see what > > Cake entails, but I'm finding that I can't get the URLs to work - I > > keep getting 404's. I'm fairly sure it's a mod_rewrite issue, but it > > appears to be working normally. > > > I have cake installed to ~/public_html/. If I put a file, e.g., > > info.php, which simply contains phpinfo( ) into app/webroot, I can > > access it throughhttp://localhost/~ben/info.php. The php info that > > comes up when I access this page shows that mod_rewrite is loaded, and > > that the request URI is /~ben/info.php, wheras the script name (page > > served) is /~ben/app/webroot/info.php, so that appears to be working. > > However, if I attempt to access the posts view > > throughhttp://localhost/~ben/posts, > > I get a 404, with 'The requested URL /home/ben/public_html/app/webroot/ > > index.php was not found on this server' (even though that is the exact > > path to the script). If attempt to accesshttp://localhost/~ben/?url=posts, > > it works fine, and I get the posts view. As I said, it appears to be a > > mod_rewrite issue, but I can't isolate it. > > > I've inserted 'RewriteBase/~ben/' to the .htaccess in the root > > directory. My apache error log keeps coming up with 'File does not > > exist: /var/www/home'. However,http://localhost/postsworksfine if I > > place cake in /var/www (the apache document root), and this > > causeshttp://localhost/~ben/poststowork also, meaning that it's > > redirecting relative to the document root. Is there a way around this, > > have I missed something, or will I have to change the DocumentRoot to > > ~/public_html? I tried doing this in public_html/.htaccess, but the > > apache log shows that I don't have permission to change documentroot > > there, even though the directory is set to override all. Does this > > mean that I will have to create a virtualhost to house the directory? > > > Any help would be much appreciated. --~--~-~--~~~---~--~~ 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: Render view without layout
I am trying to get jquery to work with cake as well, so if anyone has any ideas that would be great. On Jul 4, 12:26 pm, Contrid <[EMAIL PROTECTED]> wrote: > Thanks for the responses guys! Greatly appreciated! > > I could use the 'ajax' feature... > But the problem is that I'll then need the Scriptaculous libraries > included. > I don't want that, since I already have jQuery integrated. > How can I make jQuery work with this? > > Best, > > On Jul 4, 8:00 pm, "[EMAIL PROTECTED]" > > <[EMAIL PROTECTED]> wrote: > > All you need to do is type $this->render('view_name','ajax'); > > > ajax is a layout which just contains > > > without all the usual layout.ctp stuff. > > > this also follows if for whatever reason you need to change the > > layout. (checkout the manual page on controllers for how render works) > > > Simon > > > On Jul 4, 5:07 pm, Contrid <[EMAIL PROTECTED]> wrote: > > > > Hi there, > > > > Within my current view, I want to include another view. > > > I tried using : > > > > render('view_name'); ?> > > > > ...but it renders the entire layout. > > > I just want the content inside of the view file. > > > > How can I accomplish this? > > > Thank you for your help. --~--~-~--~~~---~--~~ 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: Render view without layout
I'm afraid I can't help the author with my advice, but I have a something to add to author's question: Is it possible to switch layout in controller (or view)? I don't want some views of my controller to use layout, and I want others to do so :) On Jul 4, 7:07 pm, Contrid <[EMAIL PROTECTED]> wrote: > Hi there, > > Within my current view, I want to include another view. > I tried using : > > render('view_name'); ?> > > ...but it renders the entire layout. > I just want the content inside of the view file. > > How can I accomplish this? > Thank you for your help. --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
Cache Elements for Different Users
Is there a way to cache elements separately for each user? Currently, since the element name is same, the cache is basically overwritten, I would prefer to cache the element individually. So that later on, I can delete the cache when an update is performed for that user, otherwise it is uses the cached view. Thanks --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
Shopping Cart
I'm creating a shopping cart to extend a current project completed in CakePHP. I'm having some issues with regards to understanding how Sessions work around CakePHP and how to use them. The trouble i'm having is, I am not able to find some practical examples regarding how to store session data around Cake. For example, i have a controller: layout = 'main'; if(!$id) { $this->Session->setFlash('Invalid id for Product.'); $this->redirect('/products/index/'); } $this->set('product', $this->Product->read(null, $id)); } ?> / view.thtml / image('sundaymorning_cover.jpg', array('class' => 'product_img')); ?> - $ I'm looking for a starting point to begin the process of integrating a Shopping Cart Using Sessions. Not looking necessarily for a complete how-to (would be nice if possible :)) but all i'm really looking for is some assistance on how to integrate this. I haven't found much on this topic as of yet, but if someone has any good resources please share. --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
othAuth & multple CAKE_ADMINS
Hi Bakers, I've been trying to get othAuth working in conjunction with this bakery article http://bakery.cakephp.org/articles/view/using-cake_admin-for-multiple-user-types In a nutshell I want to: 1. separate the natural logic of my app by group (admins, contractors, users) 2. reduce complexity of my permissions system by having a group wide setting, eg: group name: Admins permission: /admin/* group name: Contractors permission: /contractor/* I currently have this in place, but it's not working. I'd really appreciate some insight from someone who know's othAuth better. I'm using php5/cake 1.2 (latest nightly from a few days ago) Thanks, Jon -- jon bennett t: +44 (0) 1225 341 039 w: http://www.jben.net/ iChat (AIM): jbendotnet Skype: jon-bennett --~--~-~--~~~---~--~~ 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: Render view without layout
$layout = $this->layout; $this->layout = null; $this->render("view_name"); $this->layout = $layout; Geoff -- http://lemoncake.wordpress.com On Jul 5, 5:26 am, Contrid <[EMAIL PROTECTED]> wrote: > Thanks for the responses guys! Greatly appreciated! > > I could use the 'ajax' feature... > But the problem is that I'll then need the Scriptaculous libraries > included. > I don't want that, since I already have jQuery integrated. > How can I make jQuery work with this? > > Best, > > On Jul 4, 8:00 pm, "[EMAIL PROTECTED]" > > <[EMAIL PROTECTED]> wrote: > > All you need to do is type $this->render('view_name','ajax'); > > > ajax is a layout which just contains > > > without all the usual layout.ctp stuff. > > > this also follows if for whatever reason you need to change the > > layout. (checkout the manual page on controllers for how render works) > > > Simon > > > On Jul 4, 5:07 pm, Contrid <[EMAIL PROTECTED]> wrote: > > > > Hi there, > > > > Within my current view, I want to include another view. > > > I tried using : > > > > render('view_name'); ?> > > > > ...but it renders the entire layout. > > > I just want the content inside of the view file. > > > > How can I accomplish this? > > > Thank you for your help. --~--~-~--~~~---~--~~ 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: Behaviors in Plugins
I ran into this problem with plugins a while ago, but I have not seen it fixed in the core yet. http://groups.google.com/group/cake-php/browse_thread/thread/9b67a52dcdf4322/e78c27478c7274de?lnk=gst&q=Geoff+Ford+plugins&rnum=3#e78c27478c7274de AD7six mentions some other trac tickets with patches in them relating to plugins. Geoff -- http://lemoncake.wordpress.com On Jul 5, 3:52 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > I've just submitted a note to bug #2447. > > Essentially, the problem in the bug is that behaviors are not loaded > in plugins. My answer is to bootstrap the plugin to alter the > Configure instance to give it an additional behaviorsPath like so: > > $path = Configure::getInstance(); > $path->behaviorPaths[] = APP . 'plugins' . DS . 'plugin_name' . DS . > 'models' . DS . 'behaviors' . DS; > > My question is, do people agree with this solution, and are the cake > core guys working on doing this as part of the plugin infrastructure, > or is that not where it belongs? > > I also thought I'd share it for any irritated plugin developers, who > like me have wrested with this one for a while. > > simon --~--~-~--~~~---~--~~ 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: Flay and Other Markup Translation Tools
BBCode is a well known alternative, this is from a recent thread Here is the Bakery's implementation as a helper :- https://cakeforge.org/plugins/scmsvn/viewcvs.php/trunk/bakery/views/h... Basically in the view you call $bbcode->format($this- >data['ModelName'] ['bbcode']); Geoff -- http://lemoncake.wordpress.com On Jul 5, 3:42 am, GreyCells <[EMAIL PROTECTED]> wrote: > I'm investigating 'markup translation tools' to allow untrusted users > to create content - Flay seems an obvious choice, but I cannot seem to > find any documentation on it - just four article in this group, one of > which casts doubt on it's longevity. > > http://groups.google.com/group/cake-php/browse_thread/thread/2c8d5d9c... > > I haven't yet found the trac reference at the end of that thread. > > If it's around for the long haul, I'd like to get my hands on some > docs and put together an article for the bakery. > > Textile is another obvious choice, but by default allows raw html (and > my implementation/fix for that feels like a bit of a kludge). > > So... any recommendations for implementing a clean cake-ish solution > for allowing untrusted users to enter content? > > Many thanks > > ~GreyCells --~--~-~--~~~---~--~~ 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: admin backend best practice
I've been wondering about the same thing for a while now. I came to the conclusion that a different for the admin would *almost* give the impression of a whole separate backend anyway. The thing I'm wondering is how best to set the layout for the admin. I was thinking about using either *beforeRender() or beforeFilter()* in AppController to set the layout based on the user group. Is this the bast way to go for the approach 2? Cheers, Sonic ** --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
install partially failed
hi i put cakephp on a /cake folder in my document root, the problem is that when i go to localhost/cake the css and images of the cake index page are not being shown, how can i fix this? thanks --~--~-~--~~~---~--~~ 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: Why dispatcher return a blank page?
I found something interesting but don't know what! At sf.net [Session] => sessioncomponent Object ( [__active] => 1 [valid] => 1 [error] => Array ( [2] => Config doesn't exist [1] => Session is valid ) [_userAgent] => dde3c1f5760fa123c1c0436135c6399f [path] => /caketest/ [lastError] => 1 On my pc: [Session] => SessionComponent Object ( [__active] => 1 [valid] => 1 [error] => [_userAgent] => d9fd8457f94661075e763061f6305e20 [path] => /cake_1.2.0.5146alpha/ [lastError] => On Jul 4, 2:19 pm, "chanh.ong" <[EMAIL PROTECTED]> wrote: > On line 526 in _invoke I put my debug right after $output = > call_user_func_array(array(&$controller, $params['action']), > empty($params['pass'])? null: $params['pass']); > > I got lot of output on my pc here at the bin: > > http://bin.cakephp.org/view/751268208 > > But on sf.net same line but I just got blank: > > So the problem in at this line 526 > > Here is the bin for before line 526:http://bin.cakephp.org/view/771816764 > > The debug is set to 3. > > Please let me know what you see from a Cake expert eyes. > > Thanks > > On Jul 4, 1:39 pm, AD7six <[EMAIL PROTECTED]> wrote: > > > On Jul 4, 10:27 pm, "chanh.ong" <[EMAIL PROTECTED]> wrote: > > > > Here is the bin of the debugging session: > > > > === BEFORE _invoke function call I got something > > > invoke may aswell be called "do everything". > > > You need to debug yourself to find the (much) lower cause for your > > blank page and then figure out what on your server is the cause. I do > > hope that you already set debug to > 0 btw.. > > > hth, > > > AD --~--~-~--~~~---~--~~ 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: Why dispatcher return a blank page?
On line 526 in _invoke I put my debug right after $output = call_user_func_array(array(&$controller, $params['action']), empty($params['pass'])? null: $params['pass']); I got lot of output on my pc here at the bin: http://bin.cakephp.org/view/751268208 But on sf.net same line but I just got blank: So the problem in at this line 526 Here is the bin for before line 526: http://bin.cakephp.org/view/771816764 The debug is set to 3. Please let me know what you see from a Cake expert eyes. Thanks On Jul 4, 1:39 pm, AD7six <[EMAIL PROTECTED]> wrote: > On Jul 4, 10:27 pm, "chanh.ong" <[EMAIL PROTECTED]> wrote: > > > Here is the bin of the debugging session: > > > === BEFORE _invoke function call I got something > > invoke may aswell be called "do everything". > > You need to debug yourself to find the (much) lower cause for your > blank page and then figure out what on your server is the cause. I do > hope that you already set debug to > 0 btw.. > > hth, > > AD --~--~-~--~~~---~--~~ 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: admin backend best practice
Chris knows of what he speaks (I do the same thing for the same reason) On 7/4/07, danfreak <[EMAIL PROTECTED]> wrote: > > > > Cheers Chris! > > Any other opinion? > > > > > -- (the old fart) the advice is free, the lack of crankiness will cost you - its a fine line between a real question and an idiot http://blog.samdevore.com/archives/2007/03/05/when-open-source-bugs-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 group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Why dispatcher return a blank page?
On Jul 4, 10:27 pm, "chanh.ong" <[EMAIL PROTECTED]> wrote: > Here is the bin of the debugging session: > > === BEFORE _invoke function call I got something invoke may aswell be called "do everything". You need to debug yourself to find the (much) lower cause for your blank page and then figure out what on your server is the cause. I do hope that you already set debug to > 0 btw.. hth, AD --~--~-~--~~~---~--~~ 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: admin backend best practice
Cheers Chris! Any other opinion? --~--~-~--~~~---~--~~ 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: Why dispatcher return a blank page?
Here is the bin of the debugging session: === BEFORE _invoke function call I got something mydebug($controller); return $this->_invoke($controller, $params, $missingAction); http://bin.cakephp.org/view/1333926955 === inside _invoke function call before return I got blank just as before So the problem is in the invoke somewhere. Would someone take a look at the bin and provide some insight? Thanks On Jul 3, 8:56 pm, "chanh.ong" <[EMAIL PROTECTED]> wrote: > I can't access my sf shell account at all so I can't try out your > tips. > > That's very help tip! > > Thanks very much! > > On Jul 3, 1:19 pm, AD7six <[EMAIL PROTECTED]> wrote: > > > On Jul 3, 9:34 pm, "chanh.ong" <[EMAIL PROTECTED]> wrote: > > > > I did you you suggest. > > > > . Copy my cake 1.1 to caketest. > > > . copy .htacess and edit the rewritebase to caketest > > > . Test it to make sure it still work and it does > > > . Then rename cake to cakecore11 > > > . Copy cake core 1.2 to caketest and all I got is a blank page just > > > like before. > > > > I just wondering what was changed in dispatcher.php for Cake 1.2 so I > > > can have a starting point to attempt to look. > > > echo ""; > > print_r($aVariable); // Anything in the code you want to see the value > > of > > print_r('Made it to:' .__FILE__.':'.__LINE__); die; > > > paste that as the first line of your index.php file. If you don't see > > anything then the problem isn't cake. If you see your debug message > > copy and paste moving forwards in the same file until you don't see it > > anymore. when you see nothing go into the method you just stepped over > > pasting at the beginning. etc. until you see something you can fix. > > > hth, > > > AD --~--~-~--~~~---~--~~ 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: admin backend best practice
On 7/4/07, danfreak <[EMAIL PROTECTED]> wrote: > > Hey guys, > > I saw a couple of different approaches for building an admin backend: > > 1) exploit CAKE admin routes and then show the relative controllers > actions only if an user belongs to certain administrative groups > > 2) build 2 applications (frontend and backend) and then manage > everything from the backend I prefer #1 myself...less work to maintain everything. -- Chris Hartjes Senior Developer Cake Development Corporation My motto for 2007: "Just build it, damnit!" @TheBallpark - http://www.littlehart.net/attheballpark @TheKeyboard - http://www.littlehart.net/atthekeyboard --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
admin backend best practice
Hey guys, I saw a couple of different approaches for building an admin backend: 1) exploit CAKE admin routes and then show the relative controllers actions only if an user belongs to certain administrative groups 2) build 2 applications (frontend and backend) and then manage everything from the backend What I was wondering with regard to method 2 is to avoid to duplicate the models. Which method would you recomend? Cheers Dan --~--~-~--~~~---~--~~ 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: Render view without layout
Thanks for the responses guys! Greatly appreciated! I could use the 'ajax' feature... But the problem is that I'll then need the Scriptaculous libraries included. I don't want that, since I already have jQuery integrated. How can I make jQuery work with this? Best, On Jul 4, 8:00 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > All you need to do is type $this->render('view_name','ajax'); > > ajax is a layout which just contains > > without all the usual layout.ctp stuff. > > this also follows if for whatever reason you need to change the > layout. (checkout the manual page on controllers for how render works) > > Simon > > On Jul 4, 5:07 pm, Contrid <[EMAIL PROTECTED]> wrote: > > > Hi there, > > > Within my current view, I want to include another view. > > I tried using : > > > render('view_name'); ?> > > > ...but it renders the entire layout. > > I just want the content inside of the view file. > > > How can I accomplish this? > > Thank you for your help. --~--~-~--~~~---~--~~ 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: renderElement vs nesting views
Hi, > If I understand you right, it sounds like you may wish to go down the > ajax route. > In essence, have an action for the parent that renders all the stuff > it needs to do, > but has placeholders (div's) that you preload with child actions (ie a > form). Thanks for your answer - I had a quick play with the Ajax method and found that this is certainly a possibility, but as I am totally new to Ajax I don't want to start integrating it into a production site without knowing a little more about the issues - security, browser support, bugs, etc. Part of this was running into issues with effects very quickly. The problem I had originally with renderElement was because the data was passed to the function, but the tree was different for my nested structure and my non-nested edit form. I also think there is a bug with the renderElement that means that $html->tagValue or $html- >input, etc does not "find" the data from the model, even if you get the structure the same as you would for the proper view. I am not 100% on this, so I need to investigate further before submitting a report. What I did find was a workaround to create my nested editing views using the original element method which is shown below - it may seem a bit of a hack, but all I do is wrap up my elements with the view - then I can use them elsewhere. It also makes for less unwieldy views because I split it up into chunks. It also means I could still quite easily switch my elements over to Ajax ones by adding an if / else clause in the view and also in the controller so that the same functions use Ajax or normal functionality - this is why I need to read up a bit more too. Hope this helps anyone else looking for an idea. Anyway, my workaround is like this for my original view: $this- >data['ChildModelName'])); ?> For my nested views: $child)); } ?> For my element: input('ChildModelName/title', array('value' => $fm_data['title'])); ?> ?> --~--~-~--~~~---~--~~ 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: Render view without layout
All you need to do is type $this->render('view_name','ajax'); ajax is a layout which just contains without all the usual layout.ctp stuff. this also follows if for whatever reason you need to change the layout. (checkout the manual page on controllers for how render works) Simon On Jul 4, 5:07 pm, Contrid <[EMAIL PROTECTED]> wrote: > Hi there, > > Within my current view, I want to include another view. > I tried using : > > render('view_name'); ?> > > ...but it renders the entire layout. > I just want the content inside of the view file. > > How can I accomplish this? > Thank you for your help. --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
Behaviors in Plugins
I've just submitted a note to bug #2447. Essentially, the problem in the bug is that behaviors are not loaded in plugins. My answer is to bootstrap the plugin to alter the Configure instance to give it an additional behaviorsPath like so: $path = Configure::getInstance(); $path->behaviorPaths[] = APP . 'plugins' . DS . 'plugin_name' . DS . 'models' . DS . 'behaviors' . DS; My question is, do people agree with this solution, and are the cake core guys working on doing this as part of the plugin infrastructure, or is that not where it belongs? I also thought I'd share it for any irritated plugin developers, who like me have wrested with this one for a while. simon --~--~-~--~~~---~--~~ 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: Render view without layout
I'd suggest you create an element containing the common markup from the first page and call $this->renderElement('my/element') from both pages. There may be other solutions, but this worksforme. On Jul 4, 5:07 pm, Contrid <[EMAIL PROTECTED]> wrote: > Hi there, > > Within my current view, I want to include another view. > I tried using : > > render('view_name'); ?> > > ...but it renders the entire layout. > I just want the content inside of the view file. > > How can I accomplish this? > Thank you for your help. --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
Flay and Other Markup Translation Tools
I'm investigating 'markup translation tools' to allow untrusted users to create content - Flay seems an obvious choice, but I cannot seem to find any documentation on it - just four article in this group, one of which casts doubt on it's longevity. http://groups.google.com/group/cake-php/browse_thread/thread/2c8d5d9c83901436/dec610597fdf9bda?lnk=gst&q=flay&rnum=1#dec610597fdf9bda I haven't yet found the trac reference at the end of that thread. If it's around for the long haul, I'd like to get my hands on some docs and put together an article for the bakery. Textile is another obvious choice, but by default allows raw html (and my implementation/fix for that feels like a bit of a kludge). So... any recommendations for implementing a clean cake-ish solution for allowing untrusted users to enter content? Many thanks ~GreyCells --~--~-~--~~~---~--~~ 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: My view cache do not work?
The article linked above is spot on. Caching views is really a misnomer - it's the *data* used by the views that usually needs caching, and that should be handled by the controller (the place where all the business logic is implemented). As usual, cake is heading in the right direction with it's multiple cache engines - I've only used the file cache engine so far and it does exactly what it says on the tin. If you /really/ want to cache views, then transform the data before caching it. ~GreyCells On Jul 4, 12:31 pm, Fordnox <[EMAIL PROTECTED]> wrote: > cache works using this > articlehttp://jirikupiainen.com/2007/05/21/cakephp-cache/ > , but still, is it the same cahe ? DB queries cahe and views cache ? > > On Jul 4, 1:54 pm, Fordnox <[EMAIL PROTECTED]> wrote: > > > I have the same problem as hi and hello, but setting debug to 0, > > doesnt help. > > what i'm missing here ? > > cakephp 1.2.0.5146alpha > > > On Jul 4, 1:09 pm, Geoff Ford <[EMAIL PROTECTED]> wrote: > > > > Caching only works when DEBUG is set to 0 > > > > Geoff > > > --http://lemoncake.wordpress.com > > > > On Jul 4, 7:07 pm, hi and hello <[EMAIL PROTECTED]> wrote: > > > > > At core.php I have: > > > > define('CACHE_CHECK', true); > > > > > At the controller file I have: > > > > var $helpers = array('Html', 'Form', 'Javascript', 'Ajax', > > > > 'Cache' ); > > > > var $cacheAction = true; > > > > > But when I visit the url to call the controller I found theview > > > >cachedoesnot work and in the app/tmp/cache/views directory there is > > > > nothing. > > > > >Is something wrong? --~--~-~--~~~---~--~~ 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: "webroot" getting appended in subsequent links?
I'm curious about this too, Rajesh. It actually causes my sessions to expire when the webroot link is appended. Has anyone fixed this before? Thanks, Wilson On Jul 4, 11:32 am, "R. Rajesh Jeba Anbiah" <[EMAIL PROTECTED]> wrote: > I have setup like this: > > ROOT\.cake\ > ROOT\public_html\ > > 'CAKE_CORE_INCLUDE_PATH' set to ROOT.DS.'.cake' in ROOT\public_html > \webroot\index.php > > When I accesshttp://foo.com/, the subsequent links are appended > with "webroot", sayhttp://foo.com/webroot/users/login > > I have trapped up to dispatcher, but still couldn't find the > reason. Could anyone has any idea? TIA > > -- > > Email: rrjanbiah-at-Y!comBlog:http://rajeshanbiah.blogspot.com/ --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
Render view without layout
Hi there, Within my current view, I want to include another view. I tried using : render('view_name'); ?> ...but it renders the entire layout. I just want the content inside of the view file. How can I accomplish this? Thank you for your help. --~--~-~--~~~---~--~~ 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: 1.2 Pagination SQL Injection
It is not needed either dbo level when using these conventions. > > I'm sorry, I meant Sanitize::escape() > > It is not needed either, the core handles everything if you follow conventions. -- /** * @author Larry E. Masters * @var string $userName * @param string $realName * @returns string aka PhpNut * @access public */ --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
"webroot" getting appended in subsequent links?
I have setup like this: ROOT\.cake\ ROOT\public_html\ 'CAKE_CORE_INCLUDE_PATH' set to ROOT.DS.'.cake' in ROOT\public_html \webroot\index.php When I access http://foo.com/, the subsequent links are appended with "webroot", say http://foo.com/webroot/users/login I have trapped up to dispatcher, but still couldn't find the reason. Could anyone has any idea? TIA -- Email: rrjanbiah-at-Y!comBlog: http://rajeshanbiah.blogspot.com/ --~--~-~--~~~---~--~~ 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: DB Schema Help
Hi Geoff, Thanks for the response. Your solution would be fine if I didn't have the stock images in the mix. Some images will be associated with multiples homes, so I think I need to have a separate table that is somehow keeping track of what homes they are associated with, in addition to what order they appear in for that particular home. Just not quite sure how to pull this off... On Jul 3, 8:11 pm, Geoff Ford <[EMAIL PROTECTED]> wrote: > What about a field in the images table that is used for ordering and > then use 'Images.order_field' as the 3rd parameter in your findAll() > > Geoff > --http://lemoncake.wordpress.com > > On Jul 4, 11:14 am, McFadly <[EMAIL PROTECTED]> wrote: > > > Hello Bakers - > > > I have a situation where I can't agree on the best database schema / > > logic for my project. > > > Here's a simplified version of my project: > > > table: Homes > > table: Images > > > Each Home will have zero to many Images. Some Images will be "stock" > > images that can be used by many Homes. Each group of Images > > associated with a Home will be in a user defined and changeable > > order. > > > Homes HABTM Images would provide the ability to associate images to > > homes, but how do I keep them in a specific and changeable order? > > > My initial thought is a table: galleries, which has a serialized list > > of image_ids, in a particular order. Is this my best bet, or am I > > overlooking a possibility? > > > Your thoughts and direction, please. > > Thanks! --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
how to use html character code in title for paginationHelper
Hello, I'm using cake 1.2 and implemented pagination. It works like a charm and was very (!) easy to implement. There is only one very small thing I can't solve. The default title for the prev and next functions ($paginator->next() and $paginator->prev()) is "<< Prev" and "Next >>". I want to change this to Dutch and use the character « and ». The translating is no problem, but the special characters are. To change the default title I use $paginator->next($title = "« Volgende"). The problem is that cake translates the « to «. Does anybody know how to solve this without tweaking the source? Thanks! --~--~-~--~~~---~--~~ 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: How can I get the version of cakephp used in my project?
On 7/4/07, hi and hello <[EMAIL PROTECTED]> wrote: > Yes, and I found it at cake/config/config.php. There's also cake/VERSION.txt - Gonzalo --~--~-~--~~~---~--~~ 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: My view cache do not work?
cache works using this article http://jirikupiainen.com/2007/05/21/cakephp-cache/ , but still, is it the same cahe ? DB queries cahe and views cache ? On Jul 4, 1:54 pm, Fordnox <[EMAIL PROTECTED]> wrote: > I have the same problem as hi and hello, but setting debug to 0, > doesnt help. > what i'm missing here ? > cakephp 1.2.0.5146alpha > > On Jul 4, 1:09 pm, Geoff Ford <[EMAIL PROTECTED]> wrote: > > > Caching only works when DEBUG is set to 0 > > > Geoff > > --http://lemoncake.wordpress.com > > > On Jul 4, 7:07 pm, hi and hello <[EMAIL PROTECTED]> wrote: > > > > At core.php I have: > > > define('CACHE_CHECK', true); > > > > At the controller file I have: > > > var $helpers = array('Html', 'Form', 'Javascript', 'Ajax', > > > 'Cache' ); > > > var $cacheAction = true; > > > > But when I visit the url to call the controller I found theview > > >cachedoesnot work and in the app/tmp/cache/views directory there is > > > nothing. > > > >Is something wrong? --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
session does not expire
Hi, my session doesn't expire even in IE when new browser opened i have following setting i am using cake1.2 with following setting in core.php define('CAKE_SESSION_SAVE', 'database'); define('CAKE_SECURITY','low'); define('CAKE_SESSION_TIMEOUT', '12'); Please help Thank --~--~-~--~~~---~--~~ 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: How to make session expire after browser close?
Hi, i am having same problem : i have following setting in core, but session does' not expire even in IE when new browser is opened define('CAKE_SESSION_SAVE', 'database'); define('CAKE_SECURITY','low'); define('CAKE_SESSION_TIMEOUT', '12'); Please help Rajesh Soni http://www.smarteguru.com";>Smarteguru --~--~-~--~~~---~--~~ 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: My view cache do not work?
I have the same problem as hi and hello, but setting debug to 0, doesnt help. what i'm missing here ? cakephp 1.2.0.5146alpha On Jul 4, 1:09 pm, Geoff Ford <[EMAIL PROTECTED]> wrote: > Caching only works when DEBUG is set to 0 > > Geoff > --http://lemoncake.wordpress.com > > On Jul 4, 7:07 pm, hi and hello <[EMAIL PROTECTED]> wrote: > > > At core.php I have: > > define('CACHE_CHECK', true); > > > At the controller file I have: > > var $helpers = array('Html', 'Form', 'Javascript', 'Ajax', > > 'Cache' ); > > var $cacheAction = true; > > > But when I visit the url to call the controller I found theview > >cachedoesnot work and in the app/tmp/cache/views directory there is > > nothing. > > >Is something wrong? --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
Beginner questions about the blog tutorial
Hi ! I'm learning cakephp, i juste read the blog tutorial, but there is something i didn't understand : in the add method, this line saves the data to the model : $this->Post->save($this->data) while, in the edit methode, it's this line : $this->Post->save($this->data['Post']) What's the exact difference between the two ? why "data" fot the add method and "data['Post']" for the edit one ?? thanks --~--~-~--~~~---~--~~ 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: My view cache do not work?
Caching only works when DEBUG is set to 0 Geoff -- http://lemoncake.wordpress.com On Jul 4, 7:07 pm, hi and hello <[EMAIL PROTECTED]> wrote: > At core.php I have: > define('CACHE_CHECK', true); > > At the controller file I have: > var $helpers = array('Html', 'Form', 'Javascript', 'Ajax', > 'Cache' ); > var $cacheAction = true; > > But when I visit the url to call the controller I found the view > cache doesnot work and in the app/tmp/cache/views directory there is > nothing. > >Is something wrong? --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
My view cache do not work?
At core.php I have: define('CACHE_CHECK', true); At the controller file I have: var $helpers = array('Html', 'Form', 'Javascript', 'Ajax', 'Cache' ); var $cacheAction = true; But when I visit the url to call the controller I found the view cache doesnot work and in the app/tmp/cache/views directory there is nothing. Is something wrong? --~--~-~--~~~---~--~~ 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: I need help with Set::extract
Hi, Have a look at this, http://bakery.cakephp.org/articles/view/simpleresults-behavior-re-index-results-from-findall, its a behaviour for 1.2 that changes the indexing. If it doesn't do what you need, hopefully it will give you a place to start. Penfold On 4 Jul, 04:05, Ketan Patel <[EMAIL PROTECTED]> wrote: > The following is my array structure: > Array > ( > [0] => Array > ( > [0] => Array > ( > [TagCount] => 5 > ) > > [TagsPost] => Array > ( > [TagId] => 1 > ) > > [Tag] => Array > ( > [TagName] => personal > ) > > ) >[1] => Array > ( > [0] => Array > ( > [TagCount] => 3 > ) > > [TagsPost] => Array > ( > [TagId] => 3 > ) > > [Tag] => Array > ( > [TagName] => general > ) > > ) > ) > which I want to organize as follows > array > ( >[0] => Array( > [TagCount]=>5, > [TagId] =>1, > [TagName] => personal >) > [1] => Array( > [TagCount]=>3, > [TagId] =>3, > [TagName] => general > ) > ) > Using set I am able to extract tagcount, tagId and tagName separately > in individual array, but is there a way directly that could give me > what I want without coding manual loop. > > Cheers, > Ketan ;-) --~--~-~--~~~---~--~~ 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: How can I get the version of cakephp used in my project?
Yes, and I found it at cake/config/config.php. On 7月4日, 下午2时31分, francky06l <[EMAIL PROTECTED]> wrote: > Configure::version() > > On Jul 4, 7:48 am, hi and hello <[EMAIL PROTECTED]> wrote: > > > > >thanks- 隐藏被引用文字 - > > - 显示引用的文字 - --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
hyphen in action part of url
Hi there I have set up a routing like this: Router::connect('/pages/:action/*', array('controller' => 'dynPages', 'action' => 'index')); This works fine if the action does not contain a hyphen. But I have an url like e.g. /pages/read-me CakePHP looks for a function read-me in my dynPages controller which of course does not exist. I would like to transform the action parameter by replacing the hyphen with an underscore. Thus an url like /pages/read-me would call the action read_me. For now I solved this problem by adding a str_replace in the parse function of the router class but I hope that there is a way without hacking core cake files. Any tips? Thanks Claudia --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---