Call to undefined function drupal_is_front_page()
shadyman@errora... - September 15, 2007 - 03:55
| Project: | Multiple Domains |
| Version: | 5.x-1.x-dev |
| Component: | code |
| Category: | support request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | patch (code needs work) |
Jump to:
Description
I'm getting this error occasionally when loading the front page of a secondary domain after loading the primary one:
Fatal error: Call to undefined function drupal_is_front_page() in /home/content/e/r/r/errorad/html/modules/multidomain/multidomain.module on line 532
It goes away with a refresh.
Any idea what causes it?

#1
I got it again on http://matthewlange.name/admin/settings/multidomain/settings/http_matthe...
This was by clicking on "http://matthewlange.name" on the Multiple Domains configuration page (http://erroraccessdenied.com/admin/settings/multidomain/settings)
I clicked once before, and got "You are not authorized to view this page." I tried again, and got the call to undefined function.
#2
Update: I used the settings.php patch for singlesignon (see http://drupal.org/node/129455 for details), and it seems to be working.
I'll re-open the ticket if it comes back.
#3
Nope, still does it. I changed the secondary domains to be rewritten as "www.", and it still has the problem.
#4
I encountered the same problem. When viewing the home page of a secondary domain I would get the "Call to undefined function drupal_is_front_page()" error. The error would not go away even if page was refreshed.
I had a project that needed to go out the door so was fairly desperate. I ended up adding the following to multidomain.module and it resolved the problem:
LINE 532:
$front = drupal_is_front_page();Change to:
if(function_exists('drupal_is_front_page')) {$front = drupal_is_front_page();
}
Not sure if this is a legitimate patch but it got the job done.