diff options
author | Ralph Amissah <ralph@amissah.com> | 2014-10-03 19:28:27 -0400 |
---|---|---|
committer | Ralph Amissah <ralph@amissah.com> | 2014-10-03 19:31:48 -0400 |
commit | 14b5f96494f79b75e3e77844561678c793d0caa6 (patch) | |
tree | 11fca7cbe115634564254e6b7926ad24cd98c6f8 /lib/sisu/v5 | |
parent | v5 v6: --act provides info on current --act0 to --act9 settings (diff) |
v5 v6: html, tiny first nudge toward html5 (v5 v6 differ)
* document headers, other minor
Diffstat (limited to 'lib/sisu/v5')
-rw-r--r-- | lib/sisu/v5/cgi_sql_common.rb | 21 | ||||
-rw-r--r-- | lib/sisu/v5/harvest_authors.rb | 10 | ||||
-rw-r--r-- | lib/sisu/v5/harvest_topics.rb | 10 | ||||
-rw-r--r-- | lib/sisu/v5/html_concordance.rb | 3 | ||||
-rw-r--r-- | lib/sisu/v5/html_format.rb | 29 | ||||
-rw-r--r-- | lib/sisu/v5/html_manifest.rb | 8 | ||||
-rw-r--r-- | lib/sisu/v5/html_segments.rb | 2 | ||||
-rw-r--r-- | lib/sisu/v5/se_css.rb | 6 | ||||
-rw-r--r-- | lib/sisu/v5/shared_metadata.rb | 14 |
9 files changed, 50 insertions, 53 deletions
diff --git a/lib/sisu/v5/cgi_sql_common.rb b/lib/sisu/v5/cgi_sql_common.rb index 187859ec..a16ca0db 100644 --- a/lib/sisu/v5/cgi_sql_common.rb +++ b/lib/sisu/v5/cgi_sql_common.rb @@ -144,18 +144,17 @@ module SiSU_CGI_SQL end def header_desc <<-WOK_SQL - <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" - "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> - <html xmlns="http://www.w3.org/1999/xhtml"> + <!DOCTYPE html> + <html> <head> - <title> - SiSU search form (sample): SiSU information Structuring Universe - </title> - <meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> - <meta name="sourcefile" content="SiSU._sst" /> - <link rel="generator" href="http://www.jus.uio.no/sisu" /> - <link rel="shortcut icon" href="#{@image_src}/rb7.ico" /> - <link rel="stylesheet" href="../_sisu/css/html.css" type="text/css" /> + <title> + <meta charset="utf-8"> + <meta name="sourcefile" content="SiSU._sst" /> + SiSU search form (sample): SiSU information Structuring Universe + </title> + <link rel="generator" href="http://www.jus.uio.no/sisu" /> + <link rel="shortcut icon" href="#{@image_src}/rb7.ico" /> + <link href="../_sisu/css/html.css" rel="stylesheet"> </head> <body bgcolor="#ffffff" text="#000000" link="#003090" lang="en" xml:lang="en"> <table summary="band" border="0" cellpadding="3" cellspacing="0"> diff --git a/lib/sisu/v5/harvest_authors.rb b/lib/sisu/v5/harvest_authors.rb index 1ea2167a..8db14eee 100644 --- a/lib/sisu/v5/harvest_authors.rb +++ b/lib/sisu/v5/harvest_authors.rb @@ -318,20 +318,20 @@ module SiSU_HarvestAuthors output_structure_by='(output organised by ?)' end <<WOK -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" -"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml"> +<!DOCTYPE html> +<html> <head> +<meta charset="utf-8"> <title>SiSU Metadata Harvest - Authors</title> <meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> <meta name="dc.title" content= "SiSU metadata harvest, Authors - SiSU information Structuring Universe, Structured information Serialised Units" /> <meta name="dc.subject" content= "document structuring, ebook, publishing, PDF, LaTeX, XML, ODF, SQL, postgresql, sqlite, electronic book, electronic publishing, electronic document, electronic citation, data structure, citation systems, granular search, digital library" /> <meta name="generator" content="#{sv[:project]} #{sv[:version]} of #{sv[:date_stamp]} (n*x and Ruby!)" /> <link rel="generator" href="http://www.jus.uio.no/sisu/SiSU" /> -<link rel="stylesheet" href="#{css_path}" type="text/css" /> +<link href="#{css_path}" rel="stylesheet" > <link rel="shortcut icon" href="../_sisu/image/rb7.ico" /> </head> -<body bgcolor="#ffffff" text="#000000" link="#003090" lang="en" xml:lang="en"> +<body lang="en" xml:lang="en"> <a name="top" id="top"></a> <a name="up" id="up"></a> <a name="start" id="start"></a> diff --git a/lib/sisu/v5/harvest_topics.rb b/lib/sisu/v5/harvest_topics.rb index bb0bbe22..b2e83683 100644 --- a/lib/sisu/v5/harvest_topics.rb +++ b/lib/sisu/v5/harvest_topics.rb @@ -688,20 +688,20 @@ module SiSU_HarvestTopics output_structure_by='(output organised by ?)' end <<WOK -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" -"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml"> +<!DOCTYPE html> +<html> <head> +<meta charset="utf-8"> <title>SiSU Metadata Harvest - Topics</title> <meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> <meta name="dc.title" content= "SiSU metadata harvest, Topics - SiSU information Structuring Universe, Structured information Serialised Units" /> <meta name="dc.subject" content= "document structuring, ebook, publishing, PDF, LaTeX, XML, ODF, SQL, postgresql, sqlite, electronic book, electronic publishing, electronic document, electronic citation, data structure, citation systems, granular search, digital library" /> <meta name="generator" content="#{sv[:project]} #{sv[:version]} of #{sv[:date_stamp]} (n*x and Ruby!)" /> <link rel="generator" href="http://www.jus.uio.no/sisu/SiSU" /> -<link rel="stylesheet" href="#{css_path}" type="text/css" /> +<link href="#{css_path}" rel="stylesheet"> <link rel="shortcut icon" href="../_sisu/image/rb7.ico" /> </head> -<body bgcolor="#ffffff" text="#000000" link="#003090" lang="en" xml:lang="en"> +<body lang="en" xml:lang="en"> <a name="top" id="top"></a> <a name="up" id="up"></a> <a name="start" id="start"></a> diff --git a/lib/sisu/v5/html_concordance.rb b/lib/sisu/v5/html_concordance.rb index 44a6cd69..51acabef 100644 --- a/lib/sisu/v5/html_concordance.rb +++ b/lib/sisu/v5/html_concordance.rb @@ -156,9 +156,10 @@ WOK else '' end <<WOK -<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<!DOCTYPE html> <html> <head> + <meta charset="utf-8"> <title> SiSU created WordIndex for: #{@md.title.full} </title> diff --git a/lib/sisu/v5/html_format.rb b/lib/sisu/v5/html_format.rb index b8db9445..c34759cf 100644 --- a/lib/sisu/v5/html_format.rb +++ b/lib/sisu/v5/html_format.rb @@ -89,7 +89,7 @@ module SiSU_HTML_Format end end def id #w3c? "tidy" complains about numbers as identifiers ! annoying - (@ocn==nil || @ocn.empty?) ? '' : %{id="o#{@ocn}"} + (@ocn==nil || @ocn.empty?) ? '' : %{id="#{Mx[:ocn_id_char]}#{@ocn}"} end def goto (@ocn==nil || @ocn.empty?) ? '' : %{<a href="##{@ocn_html_identifier}#{@ocn}">} @@ -173,9 +173,8 @@ module SiSU_HTML_Format SiSU_XML_Tags::RDF.new(md) end def doc_type - %{<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" -"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml">\n} + %{<!DOCTYPE html> +<html>\n} end def table_close %{ </font> @@ -414,6 +413,7 @@ WOK rdf=SiSU_XML_Tags::RDF.new(@md) %{#{doc_type} <head> + <meta charset="utf-8"> <title> #{@md.html_title} </title> @@ -597,11 +597,7 @@ WOK #{@vz.credits_splash} #{@vz.credits_sisu} <a name="bottom" id="bottom"></a> -<a name="down" id="down"></a> <a name="end" id="end"></a> -<a name="finish" id="finish"></a> -<a name="stop" id="stop"></a> -<a name="credits"></a> </div> </div> </div> @@ -615,11 +611,7 @@ WOK #{@vz.credits_splash} #{@vz.credits_sisu} <a name="bottom" id="bottom"></a> -<a name="down" id="down"></a> <a name="end" id="end"></a> -<a name="finish" id="finish"></a> -<a name="stop" id="stop"></a> -<a name="credits"></a> </div> } end @@ -630,11 +622,7 @@ WOK #{@vz.credits_splash} #{@vz.credits_sisu} <a name="bottom" id="bottom"></a> -<a name="down" id="down"></a> <a name="end" id="end"></a> -<a name="finish" id="finish"></a> -<a name="stop" id="stop"></a> -<a name="credits"></a> </div> </div> </div> @@ -775,11 +763,7 @@ WOK #{@vz.credits_splash} #{@vz.credits_sisu} <a name="bottom" id="bottom"></a> -<a name="down" id="down"></a> <a name="end" id="end"></a> -<a name="finish" id="finish"></a> -<a name="stop" id="stop"></a> -<a name="credits" id="credits"></a> </div></div> } end @@ -832,6 +816,7 @@ WOK rdf=SiSU_XML_Tags::RDF.new(@md) %{#{doc_type} <head> + <meta charset="utf-8"> <title> #{@seg_name_html[@seg_name_html_tracker]} - #{@md.html_title} @@ -841,9 +826,7 @@ WOK #{@stylesheet.css_head_seg} </head> #{@vz.color_body} -<a name="top" id="top"></a> -<a name="up" id="up"></a> -<a name="start" id="start"></a>} +<a name="top" id="top"></a>} end def title_banner(title,subtitle,creator) %{ diff --git a/lib/sisu/v5/html_manifest.rb b/lib/sisu/v5/html_manifest.rb index a31420ac..45ee2aae 100644 --- a/lib/sisu/v5/html_manifest.rb +++ b/lib/sisu/v5/html_manifest.rb @@ -888,10 +888,10 @@ WOK vz=SiSU_Viz::Defaults.new format_head_toc=SiSU_HTML_Format::HeadToc.new(@md) @manifest[:html] <<<<WOK -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" - "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml"> +<!DOCTYPE html> +<html> <head> +<meta charset="utf-8"> <title> SiSU manifest: #{@md.title.full} </title> @@ -901,7 +901,7 @@ SiSU manifest: #{@md.title.full} <link rel="shortcut icon" href="#{@f.path_rel_links.html_scroll_css}_sisu/image_sys/rb7.ico" /> #{@stylesheet.css_head} </head> -<body bgcolor="#ffffff" text="#000000" link="#003090" lang="en" xml:lang="en"> +<body lang="en" xml:lang="en"> #{format_head_toc.seg_head_navigation_band(:manifest)} WOK if make.build.manifest_minitoc? diff --git a/lib/sisu/v5/html_segments.rb b/lib/sisu/v5/html_segments.rb index 0467a128..555b75bb 100644 --- a/lib/sisu/v5/html_segments.rb +++ b/lib/sisu/v5/html_segments.rb @@ -120,7 +120,7 @@ module SiSU_HTML_Seg << @seg[:idx] \ << '</div>' # << '</div>' elsif @type=='metadata' - metadata=SiSU_Metadata::Summary.new(@md).xhtml_display.metadata + metadata=SiSU_Metadata::Summary.new(@md).html_display.metadata @seg[:headings]=[] format_head_seg=SiSU_HTML_Format::HeadSeg.new(@md) if @title_banner_ diff --git a/lib/sisu/v5/se_css.rb b/lib/sisu/v5/se_css.rb index 378fece8..4d4713e1 100644 --- a/lib/sisu/v5/se_css.rb +++ b/lib/sisu/v5/se_css.rb @@ -169,21 +169,21 @@ module SiSU_CSS @file.path_rel_links.html_scroll_css \ + @env.path.style + '/' \ + @css.html - %{ <link rel="stylesheet" href="#{stylesheet}" type="text/css" />} + %{ <link href="#{stylesheet}" rel="stylesheet">} end def html_seg stylesheet= @file.path_rel_links.html_seg_css \ + @env.path.style + '/' \ + @css.html - %{ <link rel="stylesheet" href="#{stylesheet}" type="text/css" />} + %{ <link href="#{stylesheet}" rel="stylesheet">} end def html_tables stylesheet= @file.path_rel_links.html_seg_css \ + @env.path.style + '/' \ + @css.html - %{ <link rel="stylesheet" href="#{stylesheet}" type="text/css" />} + %{ <link href="#{stylesheet}" rel="stylesheet">} end def xhtml_epub %{ <link rel="stylesheet" href="css/xhtml.css" type="text/css" />} diff --git a/lib/sisu/v5/shared_metadata.rb b/lib/sisu/v5/shared_metadata.rb index 3a83d674..9f4f4362 100644 --- a/lib/sisu/v5/shared_metadata.rb +++ b/lib/sisu/v5/shared_metadata.rb @@ -829,6 +829,20 @@ WOK end self end + def html_display + def meta_para + inf_xml=char_enc(@inf).amp + inf_xml=char_enc(inf_xml).utf8 + inf_xml=char_enc(inf_xml).br + %{<p class="norm"> + <b>#{@tag}</b>: #{inf_xml} +</p>} + end + def metadata + SiSU_Metadata::Summary.new(@md,true).metadata_base + end + self + end def xml_sax def meta_para inf_xml=char_enc(@inf).utf8 |