コメント
すごく助かりました
自分一人だと解決にどれだけ時間がかかったかわからないです。
コメントの投稿
※名前とタイトルが入力されていないコメントでは他のコメントとの区別ができません。
入力されていないコメントには返信しませんのであらかじめご了承くださいませ。
<%@ Master Language="VB" AutoEventWireup="false" CodeBehind="Base.master.vb" Inherits="AspNetTest.Base" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server"><%--VBから変更できるようにサーバーコントロールになっています。--%>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title></title>
<%--インライン式--%>
<%--表示式--%>
<link href="<%= Me.ResolveUrl("~/App_Themes/default/css/style.css") %>" rel="stylesheet" type="text/css" />
<%--埋め込みコードブロック--%>
<% If False Then %>
<% End If %>
</head>
<body>
</body>
</html>
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
If Not IsPostBack Then
Dim meta As New HtmlMeta()
meta.Attributes.Add("name", "著者名")
meta.Attributes.Add("content", "任意の著者情報")
Me.Page.Master.Controls.Add(meta)
End If
End Sub
<%@ Master Language="VB" AutoEventWireup="false" CodeBehind="Base.master.vb" Inherits="AspNetTest.Base" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title></title>
<%--インライン式--%>
<%--表示式--%>
<link href="<%= Me.ResolveUrl("~/App_Themes/default/css/style.css") %>" rel="stylesheet" type="text/css" />
<%--埋め込みコードブロック--%>
<% If False Then %>
<% End If %>
<meta name="<%= Me.GetAuthorName %>" content="<%= Me.GetAuthorContent %>"/>
</head>
<body>
</body>
</html>
Public Class Base
Inherits System.Web.UI.MasterPage
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
If Not IsPostBack Then
End If
End Sub
Public ReadOnly Property GetAuthorName As String
Get
Return "著者名"
End Get
End Property
Public ReadOnly Property GetAuthorContent As String
Get
Return "任意の著者情報"
End Get
End Property
End Class
<%@ Master Language="VB" AutoEventWireup="false" CodeBehind="Base.master.vb" Inherits="AspNetTest.Base" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server"><%--VBから変更できるようにサーバーコントロールになっています。--%>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title></title>
</head>
<body>
</body>
</html>
Public Class Base
Inherits System.Web.UI.MasterPage
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
If Not IsPostBack Then
Dim link As New HtmlLink()
link.Href = Me.ResolveUrl("~/App_Themes/default/css/style.css")
link.Attributes.Add("rel", "stylesheet")
link.Attributes.Add("type", "text/css")
Me.Page.Master.Controls.Add(link)
Dim meta As New HtmlMeta()
meta.Attributes.Add("name", "著者名")
meta.Attributes.Add("content", "任意の著者情報")
Me.Page.Master.Controls.Add(meta)
End If
End Sub
End Class
<%@ Master Language="VB" AutoEventWireup="false" CodeBehind="Base.master.vb" Inherits="AspNetTest.Base" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server"><%--VBから変更できるようにサーバーコントロールになっています。--%>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title></title>
<asp:PlaceHolder ID="plcStyle" runat="server">
<%--インライン式--%>
<%--表示式--%>
<link href="<%= Me.ResolveUrl("~/App_Themes/default/css/style.css") %>" rel="stylesheet" type="text/css" />
<%--埋め込みコードブロック--%>
<% If False Then %>
<% End If %>
</asp:PlaceHolder>
</head>
<body>
</body>
</html>
Public Class Base
Inherits System.Web.UI.MasterPage
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
If Not IsPostBack Then
Dim meta As New HtmlMeta()
meta.Attributes.Add("name", "著者名")
meta.Attributes.Add("content", "任意の著者情報")
Me.Page.Master.Controls.Add(meta)
End If
End Sub
End Class
※名前とタイトルが入力されていないコメントでは他のコメントとの区別ができません。
入力されていないコメントには返信しませんのであらかじめご了承くださいませ。