473,383 Members | 1,862 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,383 software developers and data experts.

possible to render into the <HEAD> section?

PJ6
I want to render this text into the <HEAD> section of a page (and perhaps
mute any existing title declaration, or alter it to be this instead) -

<title runat="server" id=HtmlTitle></title>

It seems Render only sends items into the <BODY>.

Actually, it would be nice if I had control over the entire rendering
process, including the whole <HEAD>.

It what I want to do possible?

Paul
Nov 19 '05 #1
3 1384
You can do this. I do it all the time. Just reference it as an
HtmlGenericControl in your code and it should be fine.

Hope this helps,
Mark Fitzpatrick
Microsoft MVP - FrontPage

"PJ6" <no****@nowhere.net> wrote in message
news:%2****************@TK2MSFTNGP10.phx.gbl...
I want to render this text into the <HEAD> section of a page (and perhaps
mute any existing title declaration, or alter it to be this instead) -

<title runat="server" id=HtmlTitle></title>

It seems Render only sends items into the <BODY>.

Actually, it would be nice if I had control over the entire rendering
process, including the whole <HEAD>.

It what I want to do possible?

Paul

Nov 19 '05 #2
Yes, this is possible. The approach I've taken in the past is to create my
own custom control that I place at the top of the document, right after the
<html> element. My custom control then is responsible for rendering <head>
and anything else I want in the <head>. Each page controls what is emitted
based upon properties on my custom head control. So, yep, it's possible;
it's just code, so make it do what you want :)

-Brock
DevelopMentor
http://staff.develop.com/ballen
I want to render this text into the <HEAD> section of a page (and
perhaps mute any existing title declaration, or alter it to be this
instead) -

<title runat="server" id=HtmlTitle></title>

It seems Render only sends items into the <BODY>.

Actually, it would be nice if I had control over the entire rendering
process, including the whole <HEAD>.

It what I want to do possible?

Paul


Nov 19 '05 #3
Put this in the HTML view of your header section:

<%=MyScriptBlockFunction()%>

Then define MyScriptBlockFunction to return whatever script text you'd like.

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net
"PJ6" <no****@nowhere.net> wrote in message
news:%2****************@TK2MSFTNGP10.phx.gbl...
I want to render this text into the <HEAD> section of a page (and perhaps
mute any existing title declaration, or alter it to be this instead) -

<title runat="server" id=HtmlTitle></title>

It seems Render only sends items into the <BODY>.

Actually, it would be nice if I had control over the entire rendering
process, including the whole <HEAD>.

It what I want to do possible?

Paul

Nov 19 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: ryan.mclean | last post by:
Hello everyone. Hope ya'll had a nice New Year. Anyway, my question is why won't this work? I must be doing something dumb . . . here is the code: in the body tag, I have this code (just to...
7
by: Ignac Vucko | last post by:
Is writing a document *during* page load safe and supported for all 4th and 5th generation browsers? If not, can you show me a specific example/browser where it causes problems? <html> <head>...
10
by: Brian W | last post by:
Hi All, I have a web user control that, among other things, provides Print this page, and Email this page functionality I have this script that is to execute on the click of the asp:hyperlinks ...
6
by: Ken Varn | last post by:
I want to add my own custom <STYLE> section in the <HEAD> section of my ASP.NET page within a custom control. Can someone tell me how I can have my custom control add tags to the <HEAD> section of...
3
by: jsh02_nova | last post by:
Anybody know how to add a script block to the html <head> section programmatically without using the 'RegisterScriptBlock' functions? -- thx -jsh
7
by: ericgla | last post by:
I am creating a web app using asp.net 2.0 where all pages are based a single master page. On some of the aspx pages I need to add javascript to the head tag in order to use Google maps. I tried...
5
by: Arne | last post by:
I need literal controls in the <head> section of my page. I need to be able to load dynamic values in the head section. It works fine in ASP.Net 1.1, but Asp.net 2.0 gives a compile error. I need...
2
by: Frank | last post by:
From: "Frank" <fkaesser@pfmail.com> Subject: Can I Use HTML Text Writer i a Custom Control to Render the <head> Section? Date: Wednesday, January 18, 2006 11:38 AM I would like to create a...
2
by: Rex | last post by:
I am writing a script that executes a bunch of queries through a form on a website and reads the results. I am only interested in the <titlesection in the <headof each web page. Currently, each...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.