Please, take a look at:

http://api.cakephp.org/class_controller.html#8d64f371009811f1d5662a491ba5cf82-
when $this->set('title') will set $this->pageTitle and will not give
the
var to view.
Related tickets:
 - https://trac.cakephp.org/ticket/4817
 - https://trac.cakephp.org/ticket/4818

On Tue, Jul 1, 2008 at 12:32 PM, leo <[EMAIL PROTECTED]> wrote:

>
> Did you read what I wrote?
>
> On 1 Jul, 16:22, "Renan Gonçalves" <[EMAIL PROTECTED]> wrote:
> > Did you read the manual?
> > Anyway, take a look again, please:
> http://manual.cakephp.org/view/54/page-related-attributes-layout
> >
> > The $pageTitle controller attribute allows you to set the title of the
> >
> >
> >
> > > rendered page. In order for this to work properly, your layout needs to
> > > include the *$title_for_layout* variable, at least between <title> tags
> in
> > > the head of the HTML document.
> >
> > On Tue, Jul 1, 2008 at 8:27 AM, leo <[EMAIL PROTECTED]> wrote:
> >
> > >    $this->pageTitle = "my title";
> > >    $this->layout = 'pageDefault';
> >
> > > Works fine and $title_for_layout is set. The same if I miss out the
> > > second line as it then defaults to ... er.. default.
> >
> > > If, however, I say $this->layout = ''; then the page title is not
> > > visible in the view. Okay, I'll just do:
> > >    $this->set('title', "my title");
> >
> > > and in the view:
> > >    <title><?php echo $title; ?></title>
> >
> > > Oh no! The variable $title is still unset. I can see where this is
> > > coming from in the API. If I use a varName other than $title, it works
> > > okay.
> >
> > > My feeling is that this is a bug, as if a viewVar is set in the
> > > controller, its accessibility in the view should not depend on its
> > > name.
> >
> > --
> > Renan Gonçalves - Software Engineer
> > Cell Phone: +55 11 8633 6018
> > MSN: [EMAIL PROTECTED]
> > São Paulo - SP/Brazil
> >
>


-- 
Renan Gonçalves - Software Engineer
Cell Phone: +55 11 8633 6018
MSN: [EMAIL PROTECTED]
São Paulo - SP/Brazil

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" 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