mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-22 21:21:32 +00:00
We need to clean the HTML id before writing it.
This commit is contained in:
parent
b17250d7eb
commit
d89158df2a
@ -351,7 +351,8 @@ docstring InsetBibitem::xhtml(XHTMLStream & xs, OutputParams const &) const
|
|||||||
// need to use "name" anyway, eventually, because some browsers do not
|
// need to use "name" anyway, eventually, because some browsers do not
|
||||||
// handle jumping to ids. If we don't do that, though, we can just put the
|
// handle jumping to ids. If we don't do that, though, we can just put the
|
||||||
// id into the span tag.
|
// id into the span tag.
|
||||||
string const attrs = "id='LyXCite-" + to_utf8(getParam("key")) + "'";
|
string const attrs =
|
||||||
|
"id='LyXCite-" + to_utf8(html::cleanAttr(getParam("key"))) + "'";
|
||||||
xs << html::CompTag("a", attrs);
|
xs << html::CompTag("a", attrs);
|
||||||
xs << html::StartTag("span", "class='bibitemlabel'");
|
xs << html::StartTag("span", "class='bibitemlabel'");
|
||||||
xs << bibLabel();
|
xs << bibLabel();
|
||||||
|
@ -960,7 +960,8 @@ docstring InsetBibtex::xhtml(XHTMLStream & xs, OutputParams const &) const
|
|||||||
xs << html::StartTag("div", "class='bibtexentry'");
|
xs << html::StartTag("div", "class='bibtexentry'");
|
||||||
// FIXME XHTML
|
// FIXME XHTML
|
||||||
// The same name/id problem we have elsewhere.
|
// The same name/id problem we have elsewhere.
|
||||||
string const attr = "id='LyXCite-" + to_utf8(entry.key()) + "'";
|
string const attr =
|
||||||
|
"id='LyXCite-" + to_utf8(html::cleanAttr(entry.key())) + "'";
|
||||||
xs << html::CompTag("a", attr);
|
xs << html::CompTag("a", attr);
|
||||||
docstring citekey;
|
docstring citekey;
|
||||||
if (numbers)
|
if (numbers)
|
||||||
|
Loading…
Reference in New Issue
Block a user