|
.net
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
.Net 2, asp:Literal outside a server form = unrecognized tag prefixhi,
i have a master page, and i want to put an asp:literal control in the <head><title> section. but it won't build because it says it's an unrecognized tag prefix. if i put the control inside a server form it works fine, but i probably don't want to move the server form to encapsulate the body element, since that would not be a correct html structure. any ideas? thanks tim Don't think it's a compile time error. just an IDE warning. I get the
same error report in VS.Net, but it compiles fine and works. Also, in 2.0 there's a nice new property to the page class, Header. Page.Header.Controls.Add(), might not be useful in your case (unless you dynamically want to add a header), but thought I'd mention it anyways. Karl Show quoteHide quote "Tim_Mac" <t**@mackey.ie> wrote in message news:1134662395.631679.295730@g47g2000cwa.googlegroups.com... > hi, > i have a master page, and i want to put an asp:literal control in the > <head><title> section. but it won't build because it says it's an > unrecognized tag prefix. > > if i put the control inside a server form it works fine, but i probably > don't want to move the server form to encapsulate the body element, > since that would not be a correct html structure. > > any ideas? > thanks > tim > hi Karl,
thanks for the tip. it works great. just for any people stuck on the same thing, it's dead easy: this.Page.Header.Title = "Hello"; Thanks for Karl's nice suggestion.
Hi Tim, Feel free to post here when you need any further help. Regards, Steven Cheng Microsoft Online Support Get Secure! www.microsoft.com/security (This posting is provided "AS IS", with no warranties, and confers no rights.) -------------------- | From: "Tim_Mac" <t**@mackey.ie> 17:02:36 GMT)| Newsgroups: microsoft.public.dotnet.framework.aspnet | Subject: Re: .Net 2, asp:Literal outside a server form = unrecognized tag prefix | Date: 15 Dec 2005 09:02:31 -0800 | Organization: http://groups.google.com | Lines: 6 | Message-ID: <1134666151.282342.121***@f14g2000cwb.googlegroups.com> | References: <1134662395.631679.295***@g47g2000cwa.googlegroups.com> | <eUUW3NZAGHA.3***@TK2MSFTNGP10.phx.gbl> | NNTP-Posting-Host: 83.141.121.205 | Mime-Version: 1.0 | Content-Type: text/plain; charset="iso-8859-1" | X-Trace: posting.google.com 1134666156 5538 127.0.0.1 (15 Dec 2005 | X-Complaints-To: groups-ab***@google.com Gecko/20051111 Firefox/1.5,gzip(gfe),gzip(gfe)| NNTP-Posting-Date: Thu, 15 Dec 2005 17:02:36 +0000 (UTC) | In-Reply-To: <eUUW3NZAGHA.3***@TK2MSFTNGP10.phx.gbl> | User-Agent: G2/0.2 | X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8) | Complaints-To: groups-ab***@google.com TK2MSFTNGXA02.phx.gbl!TK2MSFTNGP08.phx.gbl!newsfeed00.sul.t-online.de!t-onli| Injection-Info: f14g2000cwb.googlegroups.com; posting-host=83.141.121.205; | posting-account=UaxKfw0AAAA4oMLJHydK195yIv1avAma | Path: ne.de!border2.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.gigan ews.com!postnews.google.com!f14g2000cwb.googlegroups.com!not-for-mail | Xref: TK2MSFTNGXA02.phx.gbl microsoft.public.dotnet.framework.aspnet:365125Show quoteHide quote | X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet | | hi Karl, | thanks for the tip. it works great. just for any people stuck on the | same thing, it's dead easy: | | this.Page.Header.Title = "Hello"; | |
Several clocks on the same page
Dynamic Controls in Panel - How to access them! Merge two tables of a Dataset in only one Datatable updateproblem with usercontrol, page and masterpage Upload into Word document with images Receive a post of XML Document RAM based cookies ASP.NET Renaming my forms Diagram component How to deploy iis 6.0 with Remotely Stored Content on UNC Servers and NAS Devices. |
|||||||||||||||||||||||