M
Martin Knott
First, I hope I've posted in the right group.
So, to the problem.
I'm building an app and I want to use inheritance withthe pages so that
common elements are included at the base level. All goes well up to now,
the generic page adds the standard components (nav links and banner) and
the children then add their specific information.
The problem is, how can I add a reference to the CSS stylesheet in the
Head section of each derived page? I don't want to add it explicitly to
each page.aspx file. I would rather add it to the base, but it seems
that the base.aspx isn't parsed. I've tried to get around this by
completely removing the head section from childpage.aspx and using the
InitializeComponent method of basepage to add the "<!DOCTYPE.....through
to <body>" header information including the css link. The problem then
is that I don't know where to add the closing tags for the body and the
html.
I understand that ASP 2.0 tries to solve this kind of thing with Master
pages. What's the proper 1.0 way to do this? Just manually add css
links? (Hopefully not, since I was thinking of storing the users style
preference and then dynamically using it for the app)
Thanks in advance, sorry if I'm in the wrong group or my problem was
unclear.
Martin
So, to the problem.
I'm building an app and I want to use inheritance withthe pages so that
common elements are included at the base level. All goes well up to now,
the generic page adds the standard components (nav links and banner) and
the children then add their specific information.
The problem is, how can I add a reference to the CSS stylesheet in the
Head section of each derived page? I don't want to add it explicitly to
each page.aspx file. I would rather add it to the base, but it seems
that the base.aspx isn't parsed. I've tried to get around this by
completely removing the head section from childpage.aspx and using the
InitializeComponent method of basepage to add the "<!DOCTYPE.....through
to <body>" header information including the css link. The problem then
is that I don't know where to add the closing tags for the body and the
html.
I understand that ASP 2.0 tries to solve this kind of thing with Master
pages. What's the proper 1.0 way to do this? Just manually add css
links? (Hopefully not, since I was thinking of storing the users style
preference and then dynamically using it for the app)
Thanks in advance, sorry if I'm in the wrong group or my problem was
unclear.
Martin