Thanks for your reply, it triggered some grey cell activity :)

I forgot to mention I'm using 1.1.15 and its html content to be
delivered in both cases. But, I'm starting to think a simple solution
may be to hijack the "CAKE_ADMIN" functionality. This would allow me
to have functions such as mobile_index() in the controller and the
same with the views. l need to check this further try and see if it
works the way I think it should..


On Jun 8, 11:24 pm, "jitka (poLK)" <[EMAIL PROTECTED]> wrote:
> Possible solution for cake 1.2 could be:
>
> a) in AppController var $components = array('RequestHandler');
>
> b) in AppController::beforeRender() switch theme in dependency of
> result of $this->RequestHandler->isMobile()
>
> c) let router parse extensions by call Router::parseExtensions() in
> app/config/routes.php
>
> That's all. Now:
>
> a) requests from mobile devices can be rendered with theme another
> then default
>
> b) you can call your actions like example.com/controller/action.xml
> (or any other supported or user-defined content type extension) and
> browser will obtain proper headers and rendered content will use
> layout and view from 'xml' subfolder (if proper views/layout exist)
>
> For 1.1 you should use ThemeView from cakeforge.org (in 1.2 it is in
> core) and either use 1.1 cake's built-in webservices support, or parse
> $this->params['url']['url'] for extension, alter $this->layoutPath and
> $this->viewPath in controller and send proper headers from layouts for
> non-html content types.
>
> I am sure there are another ways how to solve your problem, but this
> is way I am using.


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to [email protected]
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to