0
를이 코드를C# 및 추가 동적 META 태그
protected void Page_Load(object sender, EventArgs e)
{
DataSet.DestinationsDataTable GetDestinations = (DataSet.DestinationsDataTable)dta.GetData();
Page.Title = GetDestinations.Rows[0]["Meta_Title"].ToString();
HtmlMeta hm = new HtmlMeta();
HtmlHead head = (HtmlHead)Page.Header;
hm.Name = GetDestinations.Rows[0]["Meta_Desc"].ToString();
hm.Content = GetDestinations.Rows[0]["Meta_Key"].ToString();
head.Controls.Add(hm);
}
을 그리고 (콘텐츠 페이지)
The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>).
생각을이 오류를 반환이야?
아 :
는이 문제를 해결할 자리 표시자를 추가하고 거기 메타 태그를 넣어 :그리고 다음을 그것. 다시 한 번 감사드립니다! – balexander