473,407 Members | 2,326 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,407 software developers and data experts.

Why didn't the include work?


<html><head>
<link rel="stylesheet" type="text/css" href="style.css">
<script language="javascript" src="digits.js"></script>
</head><body>
<div id="topbar">
<h1>TOP BAR</h1>
<div class="barmnu">
<!--#include "top.html" -->
</div>
</div>
<div id="Content">
<p><!--#echo var="DATE_LOCAL" -->
<p><!--#include file="haha.html" -->
</div>
<div id="sbr">
<h5>ITEM 3</h5>
<div class="sbrbox">
<p><!--#include file="sidebar.html" -->
<p>Visitors:&nbsp;<script>shownumber("123");</script>
</div>
</div>
</body></html>
--
.~. Might, Courage, Vision, SINCERITY. http://www.linux-sxs.org
/ v \ Simplicity is Beauty! May the Force and Farce be with you!
/( _ )\ (Ubuntu 6.10) Linux 2.6.20.4
^ ^ 20:11:01 up 13 days 7:23 1 user load average: 1.16 1.05 1.01
news://news.3home.net news://news.hkpcug.org news://news.newsgroup.com.hk
Apr 6 '07 #1
5 2062
Scripsit Man-wai Chang:
<html><head>
Instead of throwing a bulk of markup at the public's face, please phrase
your question (Subject line is for telling about the message, not part of
the message) and illustrate it with a URL. Note that "didn't work" is
roughly as informative as it would be to tell a doctor "I have a problem".
And use US-ASCII when posting to international groups; your message headers
specify Big-5 for no good reason.

Also please note that this group is about HTML. The include directive is not
part of HTML.
<!--#include "top.html" -->
That directive corresponds to common SSI syntax. So the odds are that your
server does not support SSI, or has the support disabled (though it's
possible that you just mistyped the file name, e.g. "top.html" instead of
"TOP.HTML"). Contact the server administrator.

--
Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/

Apr 6 '07 #2
On 2007-04-06, Man-wai Chang wrote:
>
<html><head>
<link rel="stylesheet" type="text/css" href="style.css">
<script language="javascript" src="digits.js"></script>
</head><body>
<div id="topbar">
<h1>TOP BAR</h1>
<div class="barmnu">
<!--#include "top.html" -->
<!--#include file="top.html" -->

Or:

<!--#include virtual="top.html" -->

></div>
</div>
<div id="Content">
<p><!--#echo var="DATE_LOCAL" -->
<p><!--#include file="haha.html" -->
</div>
<div id="sbr">
<h5>ITEM 3</h5>
<div class="sbrbox">
<p><!--#include file="sidebar.html" -->
<p>Visitors:&nbsp;<script>shownumber("123");</script>
</div>
</div>
</body></html>


--
Chris F.A. Johnson <http://cfaj.freeshell.org>
========= Do not reply to the From: address; use Reply-To: ========
Author:
Shell Scripting Recipes: A Problem-Solution Approach (2005, Apress)
Apr 6 '07 #3
The file containing the <!--includemust be marked on the server as
executable. I generally mark such files executable "by all".

--
David E. Ross
Climate: California Mediterranean
Sunset Zone: 21 -- interior Santa Monica Mountains with some ocean
influence (USDA 10a, very close to Sunset Zone 19)
Gardening pages at <http://www.rossde.com/garden/>
Apr 6 '07 #4

thank you all for the replies.

--
.~. Might, Courage, Vision, SINCERITY. http://www.linux-sxs.org
/ v \ Simplicity is Beauty! May the Force and Farce be with you!
/( _ )\ (Ubuntu 6.10) Linux 2.6.20.6
^ ^ 17:42:01 up 33 min 0 users load average: 1.02 1.14 1.19
news://news.3home.net news://news.hkpcug.org news://news.newsgroup.com.hk
Apr 7 '07 #5

My fault.. the Apache2 of Ubuntu was configured to allow SSI. Need to
edit /etc/apache2/apache2.conf.

--
.~. Might, Courage, Vision, SINCERITY. http://www.linux-sxs.org
/ v \ Simplicity is Beauty! May the Force and Farce be with you!
/( _ )\ (Ubuntu 6.10) Linux 2.6.20.6
^ ^ 16:08:01 up 1 day 22:59 1 user load average: 1.01 1.04 1.01
news://news.3home.net news://news.hkpcug.org news://news.newsgroup.com.hk
Apr 9 '07 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Sugapablo | last post by:
Ok, say I have some data: $name = "Some Name" $email = "some@email.com" etc. I'd like to send these to a page as POST data, as if they were coming from a web form, but without having either...
43
by: steve | last post by:
I am quite frustrated with php’s include, as I have spent a ton of time on it already... anyone can tell me why it was designed like this (or something I don’t get)? The path in include is...
3
by: Zenobia | last post by:
I copy an application to wwwroot: wwwroot +--- myApp +--- common | +--- images | default.asp global.asa
1
by: Lynn.Tilby | last post by:
Hi, Please see the history below... Does AUTOCOMMIT as used here functionally replace VACUUM ANALYZE? If I turn on AUTOCOMMIT is every transaction commited as it is executed? If this is...
11
by: MBS | last post by:
I am playing around with some PHP code. I want to put in an include() function so I can include existing HTML code and output it to the browser. Lo and behold PHP does not support relative paths...
14
by: Jim Michaels | last post by:
mysql_query("START TRANSACTION", $link2); $q2=mysql_query("SELECT pictures.pid AS pid FROM pictures,counter WHERE pictures.pid>counter.pid LIMIT 1", $link2); if ($row2=mysql_fetch_assoc($q2)) {...
5
by: Tio | last post by:
I have project in MFC(vc++) . There are files and classes: classes:dialog1,dialog2,aaa,bbb ---------------------- main.cpp --------------------- #include "mainfrm.h" #include "dialog1.h"...
4
by: samimmu | last post by:
this is my code i made this code because to reverse the words and get the number or frequent characters.this my code below. #include <iostream> #include <cstring> using namespace std; ...
1
by: Dogandpony | last post by:
Our local club has about 15 Board members, and we vote online using a mySQL/php web interface. I have several different queries/results that I print which show varying displays of...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.