Go Back  HTML Forums - Free Webmaster Forums and Help Forums > WEBSITE DEVELOPMENT > All Around Tutorials > Serverside Scripting Tutorials
User Name:
Password:
 

Reply
Thread Tools   Display Modes
  View First Unread
 
Old 04-04-2002, 08:54 AM
  #1
scoutt
Mister Admin to you
 
scoutt's Avatar
 
Join Date: Jul 2001
Posts: 30,730
iTrader: (0)
scoutt is a jewel in the roughscoutt is a jewel in the roughscoutt is a jewel in the rough
How do I include a file using ServerSide Includes?

Q. How do I include a file using ServerSide Includes?

A. You need to have the main file index.shtml to have the shtml extension. then on the files you include you don't need the <html><body> tags. The Menu file can be any extension you want.

index.shtml
<html>
<head>
<title></title>
</head>
<body>
<table>
<!-- #include file="menu.txt" -->
<td></td>
<td></td>
</tr></table>
</body>
</html>

menu.txt
<tr>
<td>
<p><a href="link1.html>link 1 </a></p>
<p><a href="link2.html>link 2 </a></p>
<p><a href="link3.html>link 3 </a></p>
<p><a href="link4.html>link 4 </a></p></td>
__________________
Have a Script or Snippet you want to share?

WWW Standards: HTML 4.01, CSS2.1, CSS3, XHTML 1.0
PHP Standards: PHP Standards
scoutt is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Old 04-04-2002, 11:52 AM
  #2
pixelmonkey
Wrench Thrower, Keeper of The Trees, and Lord of the Apes
 
pixelmonkey's Avatar
 
Join Date: Dec 2000
Location: the trees with several other brush apes
Posts: 1,085
iTrader: (0)
pixelmonkey will become famous soon enough
My SSI arent working but in the root...

if your SSI pages are not showing but on your homepage, try this...

address them virtually with (this style of include works on most NT / IIS 4 servers)
<!--#include virtual="footer.html"-->

depending on the servers configuration this might take some time, as it may require an additional / and or ..

<!--#include virtual="/footer.html"-->
<!--#include virtual="../footer.html"-->

Starting simple with a few test pages on the server is the best way to adapt your site and yourself to how the SSI is configed on your server.

chris<pixelmonkey>
__________________
pull my finger!
pixelmonkey is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Old 02-14-2006, 04:01 PM
  #3
Tham
Lord (Level 16)
 
Join Date: Dec 2005
Location: Michigan
Posts: 644
iTrader: (0)
Tham is an unknown quantity at this point
Then once you have mastered SSI, you can write programs that will write stuff from forms to your included file, and then you have a message board that will keep your webpage layout exactly the same!
__________________
Welcome to the HTML Forums!
I hope you find these wonderful people as helpful as I do!
www.askaninja.com
Tham is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote

Reply
KEEP TABS
SPONSORS
 
Boxedart
 
 


 
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
  
 
 
 



 
  POSTING RULES
 
 
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Thread Tools
Display Modes

Forum Jump

 

All times are GMT -5. The time now is 09:00 AM.

   

Mascot team created by Drawshop.com

Powered by vBulletin® Version 3.6.7
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.

Server Monitoring by ENIACmonitor 0.01
HTMLforums.com © Big Resources, Inc. Web Design by BoxedArt.com
vRewrite 1.5 beta SEOed URLs completed by Tech Help Forum and Chalo Na.