CodingForums.com

CodingForums.com (http://www.codingforums.com/index.php)
-   ASP (http://www.codingforums.com/forumdisplay.php?f=8)
-   -   showing only html content from #included file (http://www.codingforums.com/showthread.php?t=282571)

DanInMa 11-19-2012 06:13 PM

showing only html content from #included file
 
ok so I want to deploy a new default.asp to all of my web site's sub pages ( department pages)

I dont want admins to edit default.asp directly

in each folder Im goign to include sidebar.asp and mycontent.asp

I wantsidebar.asp and mycontent.asp to be full fledged documents including doctypes and css references.


My question , is it possible, in this scenario, to use includes to display the html content only of the included files? - meaning how can i strip everything but the contents of the <body> element when including sidebar.asp and mycontent.asp?

- I think you can do this in php, I jsu have no idea what this method is called so google didnt help much

DanInMa 11-19-2012 06:49 PM

nevermind I found it, but as it turns out this isnt a good way to go for this purpose anyhow.

Old Pedant 11-19-2012 08:08 PM

So what did you go with?

I would do it by breaking up the files.

So, for example, I might have:
sidebar-header.asp
sidebar-body.asp
sidebar-footer.asp

And then sidebar.asp simply #include's those 3 files. Whereas a page that needs only the body of the sidebar #include's sidebar-body.asp.

And so on.


All times are GMT +1. The time now is 11:12 AM.

Powered by vBulletin®
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.