Re: highest traffic cakePHP 1.2 sites?

2010-01-11 Thread keymaster
These sites don't have the enviable alexa traffic rank of 312 that mozilla.org has, but are still relatively high. Anyone know a cake site with higher rankings? cyclingnews.com (alexa traffic rank: 10,400 worldwide) totalfilm.com(alexa traffic rank: 19,795 worldwide) Check out the new CakeP

Re: how to setup 3 distinct Layouts: Public / UserLoggedIn / AdminLoggedin ?

2010-01-11 Thread Everton Yoshitani
Another option would be keep tree apps sharing the same core, vendors. On Tue, Jan 12, 2010 at 9:28 AM, Alexandru Ciobanu wrote: > On 1/9/2010 10:16 PM, kyle wrote: > >> >> LAYOUT1: (public no auth required): Homepage + BlogArticles + Login >> LAYOUT2: (user logged into system): User Homepage +

Re: How to format numbers in an e-mail template

2010-01-11 Thread Everton Yoshitani
I'm not sure about the number helper in the element, anyway if you arent allowed to use it you could simple use the php function http://jp2.php.net/number_format? Att, Everton On Tue, Jan 12, 2010 at 2:09 PM, FrederickD wrote: > I have added the helper 'Number' in to controller actions using the

How to format numbers in an e-mail template

2010-01-11 Thread FrederickD
I have added the helper 'Number' in to controller actions using the statement $this->helpers[] = 'Number';". My goal is to format two whole numbers with commas in the thousands position when sending an e- mail for a more professional presentation. The .ctp file paragraph (../app/views/elements/ema

CakePHP HABTM Plugin table naming conventions (for 1.3)

2010-01-11 Thread Parris
I posted this on stackoverflow, but didn't really get the response I was looking for Hi everyone, I know naming conventions for tables used by plugins generally start with the name of the plugin and then the model pluralized. For example lets say I had a plugin called Poll, with a model also c

Re: 1.3 on a production server?

2010-01-11 Thread Larry E. Masters aka PhpNut
Yes all client work is on 1.3 -- /** * @author Larry E. Masters * @var string $userName * @param string $realName * @returns string aka PhpNut * @access public */ On Mon, Jan 11, 2010 at 9:17 PM, Jamie wrote: > Is anyone using 1.3 on their live, high traffic production servers? > I'm not jus

1.3 on a production server?

2010-01-11 Thread Jamie
Is anyone using 1.3 on their live, high traffic production servers? I'm not just talking about blogs, but websites for paying clients and that sort of thing (no offense to the 1.3 bloggers out there!). I'm considering upgrading some of the domains I manage at my work to 1.3, but since it's still in

Re: how to setup 3 distinct Layouts: Public / UserLoggedIn / AdminLoggedin ?

2010-01-11 Thread Alexandru Ciobanu
On 1/9/2010 10:16 PM, kyle wrote: LAYOUT1: (public no auth required): Homepage + BlogArticles + Login LAYOUT2: (user logged into system): User Homepage + Links to the parts of the backend System LAYOUT3: (admin user): Admin Homepage + Links to edit and manage all aspects of system This is

Ajax Star Rating

2010-01-11 Thread Andre Luis silva
I tried use this rating plugin for cake but I didn't. Ajax Star Rating: http://bakery.cakephp.org/articles/view/ajax-star-rating-plugin-1 I can't understand how save the ratings in MYSQL e show them in the view... and how link rating to the article... I need help, please. Thanks for the attent

Re: Component's method that does weird things

2010-01-11 Thread David Brisebois
I did a little workaround that will permit me to continue development though I would have preferred it to work as is. I base64 encode the result of the hash in the return of the derive function then I decode it when I need it. It someone has a better idea to solve this that would be appreciated.

Re: CakeFest IV - America - Help us pick a location!

2010-01-11 Thread gremlin
Portland OR, San Francisco CA, Sacramento CA, San Jose CA so that some of us West Coasters can get some love. Corporate travel is expensive and difficult to get approved these days so something for us Left Coasters would be appreciated this time around. On Jan 7, 7:18 pm, Chris Roush wrote: > Ne

Re: Component's method that does weird things

2010-01-11 Thread David Brisebois
I tested the 1.3 alpha and I get the same result... and did the same with 1.1.20 and the dump get shown ! So I guess it is more likely to be a bug since the rewrite to 1.2 branch, don't you think ? On 11 jan, 14:59, John Andersen wrote: > A follow-up! It is not dependent on the variable name, bu

RE: Please help..stuck and no luck - SOLVED

2010-01-11 Thread Dave
I got it figured outsomething simple. json_encode($response); exit(); Added exit(); after the response was sent back. This gave me a clean JSON response with my view wrapped inside the JSON Thanks to those who helped along the way. Dave -Original Message- From: cake-php@googlegroups

Re: Component's method that does weird things

2010-01-11 Thread David Brisebois
Ok so I am totally lost, mhash is loaded and working, this is not the problem... As I said, the problem is that the controller dump when Config.debug is set to 3 doesn't show up at all when I store the binary result of the mhasing in $this->crypt_key Here is my component, so you can try it out by

Re: Component's method that does weird things

2010-01-11 Thread John Andersen
A follow-up! It is not dependent on the variable name, but I did configure PHP first, so maybe that is the error you get! I activated extension=php_mhash.dll in the PHP configuration! Please check that yours is active! Enjoy, John On Jan 11, 9:54 pm, John Andersen wrote: > Just tried the foll

Re: Component's method that does weird things

2010-01-11 Thread John Andersen
Just tried the following code, it works :) Only change is that I don't use the variable $key! [code] $hashCode = mhash(MHASH_SHA256, 'ENCRYPTIONISAGOODTHING', true); pr($hashCode); [/code] Or now that I look at it, maybe that your are using $key both as input and output! Check i

RE: Please help..stuck and no luck

2010-01-11 Thread Dave
Thanks for your help. That’s a little beyond me..no clue what's going on there. I will check around to see if anyone knows how to simply display the html from the response. Thanks, Dave -Original Message- From: cake-php@googlegroups.com [mailto:cake-...@googlegroups.com] On Behalf Of J

Re: How do I target a specific Controller from the AppController?

2010-01-11 Thread BrendonKoz
teknoid recently wrote an article about this. It was a bit more specifically geared towards Auth, but it can easily be adapted from his code examples. http://teknoid.wordpress.com/2010/01/06/quickly-grant-auth-access-to-multiple-controllers/ On Jan 10, 4:36 pm, andrewperk wrote: > Is there a wa

Re: Component's method that does weird things

2010-01-11 Thread David Brisebois
Thanks for your answer ! For the error, I was using $this->cakeError() but I taught it was the problem so that's why I replaced them with the comment so it is easy to put the error back. When reading your answer I made some search to find out that the mhash type exists, but that it is deprecated

Re: Howto get all "Posts" and its associated Ccategory tree

2010-01-11 Thread scs
Sorry I meant can you post your compete models On Jan 11, 1:57 pm, scs wrote: > Can you complete models for both Post and Category. This will help me > and anyone else looking at this trhead understand the issue a little > more. I'm just starting to get use to help solve problems in chat > groups

Re: Please help..stuck and no luck

2010-01-11 Thread John Andersen
Ok, got it :) So now you have the response with the view included, when the result is a success! You have to look into how you process a JSON response in javascript! Googling, I found this, which may help you on the way: http://www.dynamicajax.com/fr/JSON_AJAX_Web_Chat-271_290_324.html Look at th

RE: Please help..stuck and no luck

2010-01-11 Thread Dave
Ok I tried a few things. My response is: {"data":{"title":"","year_rec":{"year":"2010"},"description":"","id":"9aaf36 272a1","profile_id":"2608"},"html":"this is a good test<\/p>\r\n"}this is a good test With in the controller: $response['data'] = $this->data['Award']; $response['html'] = $this-

Re: Howto get all "Posts" and its associated Ccategory tree

2010-01-11 Thread scs
Can you complete models for both Post and Category. This will help me and anyone else looking at this trhead understand the issue a little more. I'm just starting to get use to help solve problems in chat groups. On Jan 11, 1:52 pm, Deine Mutter wrote: > Addition: > And besides the internal categ

Re: Howto get all "Posts" and its associated Ccategory tree

2010-01-11 Thread Deine Mutter
Addition: And besides the internal category_model associations i don't know if a simple belongsTo association to the category model in the post_model is enough for what i seek. Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions. You rec

Re: Howto get all "Posts" and its associated Ccategory tree

2010-01-11 Thread Deine Mutter
With my current settings (posted in the beginning of my last post) recursion level only affects the User->Post->User->Post->etc. relationship. Cake doesn't understand my Category relationship yet. Could you give me a definite answer as to how my category_model has to look like? Especially concernin

Re: Please help..stuck and no luck

2010-01-11 Thread John Andersen
This was my answer :) [answer] Now, if I understand it correctly, and I don't have Ajax running yet on my site, then you just need to use the controllers method - render ( view name ) and save the result in your responce variable. [/answer] Enjoy, John On Jan 11, 8:28 pm, "Dave" wrote: > Sor

Re: Component's method that does weird things

2010-01-11 Thread John Andersen
Are you sure that the mhash type MHASH_SHA256 exists? Instead of just commenting out THROW ERROR, make a return( null ); Enjoy, John On Jan 11, 5:40 am, David Brisebois wrote: > Hi there ! > > I am "baking" up a new website which will use the Windows Live ID Web > Authentification service in o

Re: Howto get all "Posts" and its associated Ccategory tree

2010-01-11 Thread scs
Is recursive set at level 2 or 3? $conditions = 'Post.user_id = '.$userId; $posts = $this->Post->find('all', array( 'conditions'=>$conditions 'recursive'=>'3')); On Jan 11, 12:25 pm, Deine Mutter wrote: > my model configuration looks like that: > >

RE: Please help..stuck and no luck

2010-01-11 Thread Dave
Sorry I do not see an answer. I never got one...will check the Google board. For some reason my emails from the cake group are sparatic...don't seem to be getting all of them for some reason. Dave -Original Message- From: cake-php@googlegroups.com [mailto:cake-...@googlegroups.com] On B

Re: Please help..stuck and no luck

2010-01-11 Thread John Andersen
Ok, did my answer above solve your issue? John On Jan 11, 8:08 pm, "Dave" wrote: > Will do that...just added more info to detail the problem so I thought best > to start new but wont do that any more...will continue on. > > But back to the question. > > Just the controller is correct. My JS wo

Re: iPhone users: help with idea of a CakePHP plugin

2010-01-11 Thread BrendonKoz
Thank you for the feedback, FrederickD. Unfortunately that's not what I'm trying to do here. I don't want to help create a native iPhone app using CakePHP, nor do I want to create an iPhone enabled website using CakePHP (which is actually quite easy to do with RequestAction and custom layouts).

RE: Please help..stuck and no luck

2010-01-11 Thread Dave
Will do that...just added more info to detail the problem so I thought best to start new but wont do that any more...will continue on. But back to the question. Just the controller is correct. My JS works fine when I send true or false responses' (minus the html view code) so all I need to add is

Re: Please help..stuck and no luck

2010-01-11 Thread John Andersen
Hi Dave, Please don't start another thread on the same issue, when no-one has answered the previous one. Just add your message to the existing thread so it bounces to the top of the list :) Now, if I understand it correctly, and I don't have Ajax running yet on my site, then you just need to use

Re: Find Query

2010-01-11 Thread John Andersen
Use the BETWEEN in your condition as: [code] $conditions = array($yourDate in dateformat.' BETWEEN Model.checkin AND Model.checkout'); [/code] Enjoy, John On Jan 11, 6:06 pm, sixthpoint wrote: > I have been scratching my head on how to do this for a few days now. > Lets say the user enters a

Re: how to setup 3 distinct Layouts: Public / UserLoggedIn / AdminLoggedin ?

2010-01-11 Thread danashan
I too would love this information. On Jan 9, 12:16 pm, kyle wrote: > Im new to cakephp but I love the concept thus far. I understand how to > create views and change the default layout but its unclear to me how > to make different layouts with different images and css. > > My question is... I wan

Re: Howto get all "Posts" and its associated Ccategory tree

2010-01-11 Thread Deine Mutter
my model configuration looks like that: Post Model: belongsTo: User, Category Category Model: hasMany: Subcategory(classname: category), Post After having read this article (http://bakery.cakephp.org/articles/ view/coding-a-self-join-in-a-cake-application) I guess i also need a belongsTo associa

Please help..stuck and no luck

2010-01-11 Thread Dave
I will explain in detail what i am trying to do. Index page has a table with rows of the users entries. I have a "Add New Entry" which will toggle the add form so the user can add entries directly from the same page via Ajax. I need 2 things to happen based on the form being submitted. 1. If the

Re: How do I target a specific Controller from the AppController?

2010-01-11 Thread scs
I think your looking for the controller name if so $this->params ['controller'] will get it for you. On Jan 10, 4:36 pm, andrewperk wrote: > Is there a way to target a specific controller from within the > AppController? > > For instance inside of controllers I can do this: > > if ($this->action

Re: Howto get all "Posts" and its associated Ccategory tree

2010-01-11 Thread scs
do you have a $hasMany in you Category model that shows the connection from it to Post? On Jan 11, 8:57 am, Deine Mutter wrote: > Hey folks, > > I'm desperately trying to get a hang of how to establish the > following: > 1) Let's assume I have the following models: Post, User, Category > 2) My ca

Find Query

2010-01-11 Thread sixthpoint
I have been scratching my head on how to do this for a few days now. Lets say the user enters a date in a form and submits it.. the date is 10/2/10 for example. The database is setup to have a 'checkin' and 'checkout' date fields already assigned. In those fields for example we have records like ('

JSON View

2010-01-11 Thread Dave
Does anyone know how to return a JSON object from an ajax request to return the view and a success status? I see all these tutorials to retrn data but no html. Everything is layout = false, autoRender = false. I can return the view in normal html but I need to get a status = true or false to the js

Howto get all "Posts" and its associated Ccategory tree

2010-01-11 Thread Deine Mutter
Hey folks, I'm desperately trying to get a hang of how to establish the following: 1) Let's assume I have the following models: Post, User, Category 2) My category model contains a parent_id field, allowing for an endlessly deep tree structure of categories 3) Every Post belongs to a single catego

For making Client side & Admin side user login system

2010-01-11 Thread Anas
Can anybody help me actually I want to make a client side and Admin side , I have used Auth,Acl component in admin side but now how can make client side login system...It,s appears so difficult to me can you guys help me ,I am still new in Cake php. thanks in Advance .. C

Re: JSON data

2010-01-11 Thread Plugawy
On Jan 10, 8:48 pm, "Dave" wrote: > Does anyone know how I can get the id out of this JSON response in the js? > > {"success":true,"data":{"id":"b504f06aa30"}} > > alert(response.data); = undefied > > alert(response); = {"success":true,"data":{"id":"b504f06aa30"}} You have to eval (unserialize

Component's method that does weird things

2010-01-11 Thread David Brisebois
Hi there ! I am "baking" up a new website which will use the Windows Live ID Web Authentification service in order to access the web site. Based on the PHP file provided in the SDK, I made my own component which works fairly well (it still need some optimization). The only weird thing is that cal

Question

2010-01-11 Thread Steven Elliott Jr
Hello, I'm new to CakePHP and am coming from the Java world. I was interested in Ruby on Rails and CakePHP both but I feel more comfortable with the syntax of PHP. I'm just wondering if anyone has tried RoR and left it to use Cake and if so why? Thanks Steve Check out the new CakePHP Que

Re: How to retrieve the URL being accessed

2010-01-11 Thread SeeVik
Hello there Thanks for your replies guys. The params array works just fine. Just on a querying note, does "auth" component work with Cakephp 1.1 as well? Thanks and Regards ShiVik On Jan 10, 4:45 am, Pedro Nascimento wrote: > Yeah, you can check Auth->allow and deny methods. They're great. > >

How do I target a specific Controller from the AppController?

2010-01-11 Thread andrewperk
Is there a way to target a specific controller from within the AppController? For instance inside of controllers I can do this: if ($this->action == 'index') { // do something } to target a specific action. Is there something similar to this for inside of the AppController to target a spec