Too avoid having to learn another language (PHP, Java, etc.), I opted for the SSI.
@almostbob: So, I read up on SSI. (Too bad I have to have so many extra files though...one for each set of lines that I want replicated on each page, right?)
When I ran a little test, it didn't work. So the tutorial recommended I contact my hosting service. I did. They said SSI was enabled for .shtml.
Any thoughts why the following lines don't work?
In two different locations in my default.htm (the first one didn't work...):
<!--#include file="test.shtml"-->
In a file labeled test.shtml in the same directory:
A::
the server is set up to parse some file extensions for serverside commands
eg. setup to only process cgi shtml php asp to use includes in your default.htm page it would have to be renamed default.shtml, when you make the change, remember to change the href in links that point to the homepage
B:: the code that you want replicated is likely to be Header, footer, menu, ads if used, all those items are css positioned in each page, their position is set in the external css file
so if your include file has
.header {top:0; bottom:auto; width:100%; position:fixed; z-index:10;}
.footer {top:auto; bottom:0; width:100%; position:fixed; z-index:10; }
#menu {list-style:none; /* bla bla style a ul to be a css menu didnt paste it lazy */ }
the positions of the included items will be identical on each page, whether the include is first, last, or anywhare in the file
all your includes can be in a single file if you wish
or all the common includes in one file, and any specific items for a specific page, in other files
Thanks! default.shtml worked (of course, you said it would).
Guess I need to spend time fix-positioning my header, footer (I like yours), navi menus, bla, bla, bla. ;-) Right now they are positioned in the "natural flow" of the pages.
So-o-o-o, stating the obvious: I would put the include line in the html above the first occurrence of any of the common elements...right?
You mentioned asp and php earlier. I s'pose java is in there, too? Which should I start with to extend my basic html/css skills (and I use the term loosely). Time to learn more!
the next logical development is php, ssi on steroids,& a gazillion apps code samples downloadable scripts, a half a gazillion IDEs so you can test, free for the download
but it depends on the host, if you have a MS host asp is the one, most hosts are nix of some sort, apache so php is installed
php & mysql, or asp sql both work, different approach, same result
none of the pages of this site exist as hard coded files and google shows a million results, generated by php and dont really exist, but are searchable and linkable et al, and customize on what the visitor searches for
DaniWeb runs on a script vBulletin I think
Wordpress & a heap of others
much easier than hand coding anything, even if you just use the ideas, there is proven logic to use
HeadSlap moment,RE: natural flow,, screws up more web pages than you could imagine, each browser interprets natural completely differently, what looks cool on the development pc, looks wierd on others becuase each browser renders the layout on its own, IE puts margins on the inside, FF puts margins on the outside, safari does something different again, tell them what you want it to look like, they screw up less, and you get a consistent(not identical but recognizable) design
*HeadSlap Mmoment:noun; sudden enlightenment, assault excluded, see also Doh moment; I HATE overhead lightbulbs :P
I dunno, there are heaps of IDEs that support dozens of languages, which ones support shtml have dropped out ouf sight because asp and php do everything ssi does, and more so ssi has been ignored NetBeans though supports everything else, so may be a place to start for ssi
I have WAMP installed on my pc and it will parse .shtml files as they should be on the localhost, so WAMP may be a possiblility
I looked before I posted - and after as well... Then I saw that by making a few configuration changes, DreamWeaver will allow you to preview the SSI files as well as WAMP.
May I request you guys to check my website eletsonline dot com and suggest me the best ways to improve its Alexa Ranking. I'm working hard from last couple of ...
Brands today popup and they go. This is because the attention span of the average consumer is far less than it has ever been. It is also because there is ...