Re: What's the usage of app\views\layouts\js?

2009-03-27 Thread Brendon Kozlowski

For my own personal uses, I've kept my js layout empty.  If you wanted
a specific variable set in all of your JS though, you could set it in
the layout file quite easily.

On Mar 27, 12:56 pm, brian  wrote:
> Could you expand on that a bit? What would you put in the layout,
> then? For js specifically, I mean.
>
>
>
> On Fri, Mar 27, 2009 at 2:34 AM, Dr. Loboto  wrote:
>
> > For the same purpose as xml, rss, email and etc.
>
> > When you want to output pure JavaScript (to be executed, for example),
> > you should use $this->RequestHandler->renderAs($this, 'js') in
> > controller. It will set appropriate content-type header and layout/
> > view subfolder. So Cake will look for layout for such request not in
> > views/layouts but in views/layouts/js. Same for views, instead of
> > views/controller target folder will be views/controller/js
>
> > On Mar 26, 8:35 pm, joshua  wrote:
> >> Did anybody know the useage of this folder?
>
> >> --
> >> Thanks
> >> Joshua- Hide quoted text -
>
> - Show quoted text -
--~--~-~--~~~---~--~~
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 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: What's the usage of app\views\layouts\js?

2009-03-27 Thread brian

Could you expand on that a bit? What would you put in the layout,
then? For js specifically, I mean.

On Fri, Mar 27, 2009 at 2:34 AM, Dr. Loboto  wrote:
>
> For the same purpose as xml, rss, email and etc.
>
> When you want to output pure JavaScript (to be executed, for example),
> you should use $this->RequestHandler->renderAs($this, 'js') in
> controller. It will set appropriate content-type header and layout/
> view subfolder. So Cake will look for layout for such request not in
> views/layouts but in views/layouts/js. Same for views, instead of
> views/controller target folder will be views/controller/js
>
> On Mar 26, 8:35 pm, joshua  wrote:
>> Did anybody know the useage of this folder?
>>
>> --
>> Thanks
>> Joshua
> >
>

--~--~-~--~~~---~--~~
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 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: What's the usage of app\views\layouts\js?

2009-03-26 Thread Dr. Loboto

For the same purpose as xml, rss, email and etc.

When you want to output pure JavaScript (to be executed, for example),
you should use $this->RequestHandler->renderAs($this, 'js') in
controller. It will set appropriate content-type header and layout/
view subfolder. So Cake will look for layout for such request not in
views/layouts but in views/layouts/js. Same for views, instead of
views/controller target folder will be views/controller/js

On Mar 26, 8:35 pm, joshua  wrote:
> Did anybody know the useage of this folder?
>
> --
> Thanks
> Joshua
--~--~-~--~~~---~--~~
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 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



What's the usage of app\views\layouts\js?

2009-03-26 Thread joshua
Did anybody know the useage of this folder?

-- 
Thanks
Joshua

--~--~-~--~~~---~--~~
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 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---