From: Lee Atkinson on 16 Feb 2010 10:21 Could add the meta dynamically like this on a basepage - Dim head As HtmlHead = CType(Page.Header, HtmlHead) Dim title as New HtmlMeta() Title.id = "sdsds" title.Content = page.title head.Controls.Add(title) Lee On 16/02/2010 15:14, in article ullhFrxrKHA.4752(a)TK2MSFTNGP04.phx.gbl, "Cal Who" <CalWho(a)roadrunner.com> wrote: > I'm using a master page. > > For each context page I need to add a meta tag containing the title of that > page: > <meta name="title" content="This is the Title" /> > > Be nice if didn't have to insert the meta tag into each page since there is > many of them. > > Since my <%@ Page line already has the title in it, it would be nice if I > could lift it using code in the master page and create the meta tag there. > > Do you know how that can be done. > > hanks > >
From: Göran Andersson on 17 Feb 2010 03:16 Cal Who wrote: > I've been adding a title to the <%@ Page line on each page which is what I > want - different titles for different pages. > I also have one in the head on the master. It does not appear to override > the ones on the <%@ Page (which is good). > In fact it appears to do nothing. Maybe if a <%@ Page didn't have a title > the master title would be effective?? Yes, if you omit the title attribute in a Page directive, the default title from the master page will be used. -- G�ran Andersson _____ http://www.guffa.com
|
Pages: 1 Prev: simple xss question Next: HttpContext.Current.User returns old user id |