Cake and JSON.

2007-12-10 Thread kchopein

Hi!!

First of all, thanks for the work!

I'm trying to use the JSON component with the Dojo Toolkit but I'm
having a problem: the generated json code includes the model level,
and I only need the data. I mean, I'm getting this:


{"timestamp":1193692111, "items":[
{"Post":{"id":"1","title":"The title","body":"This is the post
body.","created":"2007-11-07 00:44:54"}},
{"Post":{"id":"2","title":"A title once again","body":"And the post
body follows.","created":"2007-11-07 00:45:15"}},
{"Post":{"id":"3","title":"Title strikes back","body":"This is really
exciting! Not.","created":"2007-11-07 00:45:44"}},
{"Post":
{"id":"4","title":"aa","body":"aadadasdas","created":"2007-11-12
10:00:45"}}
]}

but I need something like this:


{"timestamp":1193692111, "items":[
{"id":"1","title":"The title","body":"This
is ...","created":"2007-11-07 00:44:54"},
{"id":"2","title":"A title once
again","body":"And ...","created":"2007-11-07 00:45:15"}
]}

Since I'm a Cake newbe I don't know if there's a way to do this or if
I have to do it myself. How do you solve this?

Thanks in advance!!

--~--~-~--~~~---~--~~
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: using dojo with cakephp

2007-12-08 Thread kchopein

Hi again!

Well, finally I've been able to dojo widgets working in Cake. The dojo
helper from the bakery is a little bit old, for the previous dojo
release (I think), so I've written some code to get a working
colorpicker. Now i'm stuck with the grid, the main reason I need dojo
working. Any ideas??

On 7 nov, 09:50, kchopein <[EMAIL PROTECTED]> wrote:
> Hi!
>
> The same problem here! I can see cake is great anddojois great too,
> but I'm not sure about how to use both together. I'm working on it, so
> I'll write here as I progress.
>
> Best regards!
>
> kchopein
>
> On 11 oct, 11:31, jimmyxx <[EMAIL PROTECTED]> wrote:
>
> > Hey guys, I've decided to jump in head first with cakephp and using it
> > for a large application I'm building. So far I'm loving it, I also
> > want to integratedojo(the tabbed navigation system & form elements/
> > validation particularly). Has anyone had any joy embeddingdojointo
> > their app and using the widget system? I've seen thedojohelper in
> > the bakery but more interested in hearing experiences & issues.
>
> > cheers,
> > Jimmy
--~--~-~--~~~---~--~~
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: using dojo with cakephp

2007-11-07 Thread kchopein

Hi!

The same problem here! I can see cake is great and dojo is great too,
but I'm not sure about how to use both together. I'm working on it, so
I'll write here as I progress.

Best regards!

kchopein

On 11 oct, 11:31, jimmyxx <[EMAIL PROTECTED]> wrote:
> Hey guys, I've decided to jump in head first with cakephp and using it
> for a large application I'm building. So far I'm loving it, I also
> want to integrate dojo (the tabbed navigation system & form elements/
> validation particularly). Has anyone had any joy embedding dojo into
> their app and using the widget system? I've seen the dojo helper in
> the bakery but more interested in hearing experiences & issues.
>
> cheers,
> Jimmy


--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---