mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-15 19:54:57 +08:00
Fixing culture list encoding
This commit is contained in:
@@ -65,7 +65,7 @@
|
|||||||
|
|
||||||
|
|
||||||
@functions{
|
@functions{
|
||||||
private string BuildSelectedCultureList(string id, string name, IEnumerable<string> siteCultures, string culture) {
|
private IHtmlString BuildSelectedCultureList(string id, string name, IEnumerable<string> siteCultures, string culture) {
|
||||||
TagBuilder selectTag = new TagBuilder("select");
|
TagBuilder selectTag = new TagBuilder("select");
|
||||||
selectTag.Attributes["id"] = id;
|
selectTag.Attributes["id"] = id;
|
||||||
selectTag.Attributes["name"] = name;
|
selectTag.Attributes["name"] = name;
|
||||||
@@ -77,11 +77,11 @@
|
|||||||
if (siteCulture == culture) {
|
if (siteCulture == culture) {
|
||||||
optionTag.Attributes["selected"] = "selected";
|
optionTag.Attributes["selected"] = "selected";
|
||||||
}
|
}
|
||||||
optionTag.SetInnerText(siteCulture);
|
optionTag.SetInnerText(Html.Encode(siteCulture));
|
||||||
selectTag.InnerHtml += optionTag.ToString();
|
selectTag.InnerHtml += optionTag.ToString();
|
||||||
}
|
}
|
||||||
|
|
||||||
return selectTag.ToString();
|
return Html.Raw(selectTag);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@using (Script.Foot()) {
|
@using (Script.Foot()) {
|
||||||
|
Reference in New Issue
Block a user