Specify link base in saved HTML pages

This commit is contained in:
FliegendeWurst 2021-06-04 10:12:28 +02:00
parent 75a22fd275
commit 4967e8afba

View File

@ -260,7 +260,10 @@ impl ILIAS {
&& el.inner_html().len() > 40 && el.inner_html().len() > 40
{ {
// ^ minimum length of useful content? // ^ minimum length of useful content?
Some(el.inner_html()) // specify a base URL for relative links
let mut link_base = format!(r#"<base href="{}">"#, ILIAS_URL);
link_base += &el.inner_html();
Some(link_base)
} else { } else {
// first element is the content overview => no custom text (?) // first element is the content overview => no custom text (?)
None None