From b4577ed4f3ffde6a7fcb2f77f8b3a7efbfe6a765 Mon Sep 17 00:00:00 2001 From: Kai Moritz Date: Sat, 16 Jul 2016 22:02:42 +0200 Subject: [PATCH] Fixed problems with the page-title The -tag of the page is taken from the velocity-variable tile, if the variable shortTitle is set. For XHTML-templates, this is the case, if the <title>-tag on the input-xhtml is set. If the variable is not set, the page-title is constructed from the project-name and the name of the page, that was found in the menu-data. A leading head in the content is not generated automatically, because the pages, that are generated automatically by maven differ to much. Hence, the leading head in the content must be specified by hand in the content. --- src/main/resources/META-INF/maven/site.vm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/resources/META-INF/maven/site.vm b/src/main/resources/META-INF/maven/site.vm index a6055e5..86006d7 100644 --- a/src/main/resources/META-INF/maven/site.vm +++ b/src/main/resources/META-INF/maven/site.vm @@ -102,6 +102,7 @@ #end #set ( $siteCrumbs = $decoration.custom.getChild( 'thymeproxy' ).getChild( 'crumbs' ).getValue() ) +<!-- name: $pages.get($alignedFileName).name --> <!-- title: $title --> <!-- short title: $shortTitle --> <!-- current page: $alignedFileName --> @@ -121,7 +122,7 @@ " > <head> - <title>juplo - $title + #if($shortTitle and $shortTitle != '')$title#else$project.name — $pages.get($alignedFileName).name#end @@ -134,7 +135,6 @@


-

$shortTitle

$bodyContent

-- 2.20.1