[themes] All page titles identical

Progga proggaprogga at gmail.com
Sat Aug 20 15:00:09 UTC 2011


On Sat, Aug 20, 2011 at 03:41:24PM +0200, Agon S. Buchholz wrote:
> 
> However, as it seems, this has nothing to do with the theming layer and
> would require serious debugging skills which are far beyond my
> capabilities, so there's not much I can do against it.
 
I understand your problem.  If you are not shy about writing some PHP code,
then you can call the debug_backtrace() function [0] from inside
drupal_set_title() to find out who is calling whom.  Something like the
following will do:

...
drupal_set_title(....);
drupal_set_message(print_r(debug_backtrace(), TRUE));
...


Thanks,
Adnan

[0] http://uk2.php.net/debug_backtrace


On Sat, Aug 20, 2011 at 03:41:24PM +0200, Agon S. Buchholz wrote:
> Hi Adnan,
> 
> > [...] This function is actually a menu callback for the "image" path.
> > So any path like "http://foo.com/image",
> > "http://foo.com/image/foo/bar", etc. should trigger this function.
> > But you are seeing the title everywhere.  So it could be that some
> > other function is calling image_gallery_page() as well. You can
> > debug around both the drupal_set_title() and image_gallery_page() to
> > see who is really calling them.
> 
> Thanks for this pointer; drupal_set_title() might explain what is going
> on behind the scenes, indeed.
> 
> However, as it seems, this has nothing to do with the theming layer and
> would require serious debugging skills which are far beyond my
> capabilities, so there's not much I can do against it.
> 
> Thanks again for the pointer! At least I wasn't attacked by black magic ;)
> 
> Greetings, -asb
> _______________________________________________
> themes mailing list
> themes at drupal.org
> http://lists.drupal.org/mailman/listinfo/themes


More information about the themes mailing list