0

Hi guys

I hope this is the best section to get my answer.

I have 2 web pages that use the same html header markup via a template web page.

Know I use this template webpage to define my head in my webpage but I wish to redifine it so it can be page specific instead of being a general template.

Is this possible?

Coded Example:

<html>
 <head>
  <title></title>
  <meta ... />
  etc
 </head>
 <body>
   <!-- 
    can i redefine the header in this section??? something like 
   -->
   <head> <title><title> <meta /> etc </head>
 </body>
</html>

Now is something like this possible?
In short I wish to redefine the head children, how would I do this?

Thankyou, Regards X

3
Contributors
5
Replies
6
Views
8 Years
Discussion Span
Last Post by sillyboy
0

As far as I know, what you have done there is invalid. If you want to do something like this, you will need to use some scripting to change the head depending on your conditions. The best way would probably be to use a server-side language.

0

Ya I thought I might ask in HTML first but I was wondering.

Ya it is invalid code but I was hoping for sort of solution that is similar to the example where the head can be changed in the body if anyone has one :(

0

I don't understand exactly what you are trying to do.

What you presented is an example of the typical form of a web page, not code that works.

0

Its an example, in short I want to redefine the title, meta etc in the body tag.

Is this possible? (I gather have to use php)

0

I think you would be able to use JavaScript in the body section, but that would essentially just re-write you whole web page. When the html is read, the head is read before the body, so I don't think you can re-define the head in the way you want to.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.