if (homepage != null && !homepage.trim().equals("")) {
return dispatcher.getPublisherURL(request) + "/" + db.getDbReference().toLowerCase() + "/" + homepage;
}
// Try to find a document named "home" in the relevant languages
db = core.openContentDB(db, request, false);
if (db.isSessionOpen()) {
LanguageBehaviour langBehaviour = LanguageBehaviourTools.retrieve(db);
WGContent content = langBehaviour.requestSelectContentForName(db, request, "home", false);
if (content != null && content.mayBePublished(false, WGContent.DISPLAYTYPE_NONE)) {