Download Server-Side Includes (SSI)

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

URL redirection wikipedia , lookup

Transcript
Server-Side Includes (SSI)
an Introduction and Demonstration
presented by:
Sean Conklin
CMS Project Student-Assistant
MWF mornings WA 406, x4200
[email protected]
What exactly is SSI?

Server-Side Includes is a feature of all
major Web Server Applications (Microsoft
IIS, Apache, Netscape iPlanet, Etc.) that
allows for the simple including of modular
web content onto HTML web pages via
the Server. The machine itself processes
(or “parses”) SSI upon visitor request of
an HTML page having SSI commands.
“Modular”





SSI enables modular web page materials
Modular: breaking-down into separate
parts (ex: cars, computers)
Modular = Efficiency
Quicker implementation (easy copy-paste)
Ease of modification
“Server-Side” vs. “Client-Side”



“Server-Side” refers to processes taking place on
the Server (on the hosting web machine)
“Client-Side” refers to processes taking place on
the Client’s machine (ex: Internet Explorer,
Netscape, WebTV, JavaScript, Etc.)
SSI is done entirely on the Server-Side
*Therefore, SSI can’t be seen when constructing
pages on a PC – only live from the Web Server.
What will we use it for?


We are using SSI to insert (“include”) a
standard header onto all key pages of the
CSUH website, including main school and
department web pages.
The reasons for the standardization
include: consistency, modernization, &
accessibility
Why SSI?



SSI is EASY to learn and use -- simple 1 line
commands go a long way!
SSI makes CONSISTENT-looking pages that
realize the goal of our project.
SSI makes FUTURE updates much easier by
centralizing the included content. That means
only 1 person per server will need to make
template version updates, not dozens of
webmasters updating hundreds of pages.
What does SSI look like?

SSI has several commands, but only 1
that applies to us – the “INCLUDE”:
<!--#include virtual=“/PATH/FILE_NAME.EXT” -->

The INCLUDE command inserts the
contents of a file (ex: text-based template
file) onto HTML web pages. Includes also
work for graphics and can actually be
embedded (include within include)!
EXAMPLE!
CONTENTS:
1 - sample.shtml ……
2 – header.txt …………
3 – footer.txt …………
4 – [output] ………………
Sample
Header
Footer
Output
Page
Include
Include
in Internet Explorer
EXPLANATION: The page file on the left INCLUDES the
header and footer files above, which when called by a
visitor, causes the web server to put them together,
thus the output below
How do I get it working?



SSI must first be enabled on the server
that you are using. It might already be!
SSI, by default, works only on pages
named with the extention .shtml, but this
can be changed to work on .html, etc.
The set-up process will vary depending on
which Web Server Application being used.
Where to go for information?

http://www.csuhayward.edu/includes
(This page shows the exact commands that you should use)
THANK YOU!
Sean Conklin
CMS Project Student-Assistant
MWF mornings WA 406, x4200
[email protected]