Add a website ontop of another with some code?
March 9th, 2010 | by admin |I made a header for a website with css and the main body part with html. I was just going to paste the html code below the css code but this doesn’t work. Is there anyway I can have my code display another webpage above/below itself so I can have my header and body in two seperate documents of code but displayed on the same page?
Well this can be done.
If you are using ASP.net, you can use web user controls and make 2 controls and paste these in one page. You can also use master pages.
If you are using servlets, you can use servlet chaining to render different parts of a page. Note XHTML will be an add for easy parsing.
If you are using ASP, you can import one file in another. and the resulting page will contain the code for both.
If you are using XML XSL, you can XSL:FO for a formatted output that uses multiple xml files.
If you are using HTML, you can use frames. Following is the code for frames that can show multiple html files as one page:
<html>
<frameset rows="25%,50%,25%">
<frame src="header.htm">
<frame src="File1.htm">
<frame src="Footer.htm">
</frameset>
</html>
One Response to “Add a website ontop of another with some code?”
By vikas sharma on Mar 9, 2010 | Reply
Well this can be done.
If you are using ASP.net, you can use web user controls and make 2 controls and paste these in one page. You can also use master pages.
If you are using servlets, you can use servlet chaining to render different parts of a page. Note XHTML will be an add for easy parsing.
If you are using ASP, you can import one file in another. and the resulting page will contain the code for both.
If you are using XML XSL, you can XSL:FO for a formatted output that uses multiple xml files.
If you are using HTML, you can use frames. Following is the code for frames that can show multiple html files as one page:
<html>
<frameset rows="25%,50%,25%">
<frame src="header.htm">
<frame src="File1.htm">
<frame src="Footer.htm">
</frameset>
</html>
References :