aboutsummaryrefslogtreecommitdiffhomepage
path: root/lib/sisu/v5/html_segments.rb
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2013-07-30 21:42:02 -0400
committerRalph Amissah <ralph@amissah.com>2013-07-30 21:42:02 -0400
commitd15713b728f0c923837e6c417d095e5e1fe2d443 (patch)
treeb293b1310a352fb99b5bd7a3b6fed46ba49b9a46 /lib/sisu/v5/html_segments.rb
parentdebian/changelog (4.1.7-1) (diff)
parentv5: cgi helper script, sample search form, single form, monolingual option (diff)
Merge tag 'sisu_4.1.8' into debian/sid
SiSU 4.1.8
Diffstat (limited to 'lib/sisu/v5/html_segments.rb')
-rw-r--r--lib/sisu/v5/html_segments.rb14
1 files changed, 12 insertions, 2 deletions
diff --git a/lib/sisu/v5/html_segments.rb b/lib/sisu/v5/html_segments.rb
index 54292175..ec604327 100644
--- a/lib/sisu/v5/html_segments.rb
+++ b/lib/sisu/v5/html_segments.rb
@@ -273,7 +273,12 @@ module SiSU_HTML_Seg
FileUtils::mkdir_p(@file.output_path.html_seg.dir) if File.writable?("#{@file.output_path.base.dir}/.")
end
SiSU_HTML_Seg::Seg.new(@md).tail
- segfilename="#{@file.output_path.html_seg.dir}/#{@@seg_name_html[tracking-1]}#{@md.lang_code_insert}#{Sfx[:html]}"
+ fnh={
+ fn: @@seg_name_html[tracking-1],
+ lng: @md.lang_code_insert
+ }
+ fn=@md.file.base_filename.html_seg(fnh)
+ segfilename="#{@file.output_path.html_seg.dir}/#{fn}"
output_seg_file=File.new(segfilename,'w') if @@seg_name_html[tracking-1]
minitoc=(@make.build.html_minitoc?) \
? @minitoc
@@ -298,7 +303,12 @@ module SiSU_HTML_Seg
head(dob)
#keep use for last segment, eg if metadata is last segment
if @@seg_name_html[tracking] =='metadata' # this is for metadata
- segfilename="#{@file.output_path.html_seg.dir}/#{@@seg_name_html[tracking]}#{@md.lang_code_insert}#{Sfx[:html]}"
+ fnh={
+ fn: @@seg_name_html[tracking],
+ lng: @md.lang_code_insert
+ }
+ fn=@md.file.base_filename.html_seg(fnh)
+ segfilename="#{@file.output_path.html_seg.dir}/#{fn}"
output_seg_file=File.new(segfilename,'w')
SiSU_HTML_Seg::Output.new(@md,output_seg_file,@@seg,minitoc,'metadata').output
Seg.new.reinitialise