loading HTML to DIV:s?

W

Wÿrm

Is there simple way to "LOAD" external html file to some DIV?

Basically what I wanna do is that I make menu DIV and contents DIV on html
file. I want load external HTML:s from that menu DIV to contents DIV... I am
trying to avoid using frames etc. with this.

If it is possible, how widely it is supported by browsers?
 
P

PeterMcC

Wÿrm said:
Is there simple way to "LOAD" external html file to some DIV?

Basically what I wanna do is that I make menu DIV and contents DIV on
html file. I want load external HTML:s from that menu DIV to contents
DIV... I am trying to avoid using frames etc. with this.

If it is possible, how widely it is supported by browsers?

Have a look at http://www.bignosebird.com/sdocs/include.shtml
Dead easy and, because it's server-side, it works across all browsers.
 
L

Long

: Wÿrm wrote:
: > Is there simple way to "LOAD" external html file to some DIV?
: >
: > Basically what I wanna do is that I make menu DIV and contents DIV on
: > html file. I want load external HTML:s from that menu DIV to contents
: > DIV... I am trying to avoid using frames etc. with this.
: >
: > If it is possible, how widely it is supported by browsers?
:
: Have a look at http://www.bignosebird.com/sdocs/include.shtml
: Dead easy and, because it's server-side, it works across all browsers.
:
SSI #include will pull in the entire file content so you will have a mal-formed
final document.

Check out my post on comp.infosystems.www.authoring.html under the
subject heading: How to include an HTML doc in another HTML doc
or you can check out WebCharm at our web site.

www.edgesoft.ca/go/index.html?top=wc

--
Long On
Edgesoft Consulting Inc.
webcharmer @ www.edgesoft.ca/go/member/index.html
www.edgesoft.ca/go/index.html
www.edgesoft.ca
 
B

Beauregard T. Shagnasty

Long pounced upon this pigeonhole and pronounced:
: Wÿrm wrote:
: > Is there simple way to "LOAD" external html file to some DIV?
: >
: > Basically what I wanna do is that I make menu DIV and contents DIV on
: > html file. I want load external HTML:s from that menu DIV to contents
: > DIV... I am trying to avoid using frames etc. with this.
: >
: > If it is possible, how widely it is supported by browsers?
:
: Have a look at http://www.bignosebird.com/sdocs/include.shtml
: Dead easy and, because it's server-side, it works across all browsers.
:
SSI #include will pull in the entire file content so you will have a mal-formed
final document.

Check out my post on comp.infosystems.www.authoring.html under the
subject heading: How to include an HTML doc in another HTML doc
or you can check out WebCharm at our web site.

<snip link to expensive server modification, bordering on spam>

Fortunately, the Product Catalog seems to be missing, along with the
price.
"The product catalog is temporarily unavailable." ...

The SSI will work just fine on most all capable web servers, and is free.
 
L

Long

: Long pounced upon this pigeonhole and pronounced:
: >
: > : Wÿrm wrote:
: > : > Is there simple way to "LOAD" external html file to some DIV?
: > : >
: > : > Basically what I wanna do is that I make menu DIV and contents DIV on
: > : > html file. I want load external HTML:s from that menu DIV to contents
: > : > DIV... I am trying to avoid using frames etc. with this.
: > : >
: > : > If it is possible, how widely it is supported by browsers?
: > :
: > : Have a look at http://www.bignosebird.com/sdocs/include.shtml
: > : Dead easy and, because it's server-side, it works across all browsers.
: > :
: > SSI #include will pull in the entire file content so you will have a mal-formed
: > final document.
: >
: > Check out my post on comp.infosystems.www.authoring.html under the
: > subject heading: How to include an HTML doc in another HTML doc
: > or you can check out WebCharm at our web site.
:
: <snip link to expensive server modification, bordering on spam>
:
: Fortunately, the Product Catalog seems to be missing, along with the
: price.
: "The product catalog is temporarily unavailable." ...
:
: The SSI will work just fine on most all capable web servers, and is free.
:
So you are ok with having mulitple <HEAD>,<TILE>, and <BODY> tags
in the generated document?

If your ISP is WebCharm-enabled, would it cost you anything?

Long
 
S

Steve Pugh

Long said:
: The SSI will work just fine on most all capable web servers, and is free.
:
So you are ok with having mulitple <HEAD>,<TILE>, and <BODY> tags
in the generated document?

Why do you ask? The files included via the SSI don't have those tags
in them, just the content that needs including. So it's a non issue.
If your ISP is WebCharm-enabled, would it cost you anything?

Can you provide a list of WebCharm enabled web hosts?
I don't see why anyone would need to change their ISP, just their
hosting solution.

Steve
 
H

Hywel Jenkins

: Wÿrm wrote:
: > Is there simple way to "LOAD" external html file to some DIV?
: >
: > Basically what I wanna do is that I make menu DIV and contents DIV on
: > html file. I want load external HTML:s from that menu DIV to contents
: > DIV... I am trying to avoid using frames etc. with this.
: >
: > If it is possible, how widely it is supported by browsers?
:
: Have a look at http://www.bignosebird.com/sdocs/include.shtml
: Dead easy and, because it's server-side, it works across all browsers.
:
SSI #include will pull in the entire file content so you will have a mal-formed
final document.

How did you draw that conclusion? What if the include file simply
contains:
This is my web page

No mark-up, just plain text.
 
L

Long

: >: >
: >: The SSI will work just fine on most all capable web servers, and is free.
: >:
: >So you are ok with having mulitple <HEAD>,<TILE>, and <BODY> tags
: >in the generated document?
:
: Why do you ask? The files included via the SSI don't have those tags
: in them, just the content that needs including. So it's a non issue.
:
That was the question of the original poster. To include an HTML file.

If the include file contains some HTML mark up, how would you get a
preview without running it through the web server each time? The
@charm:html tag is specialized to include an HTML file so that you can
edit and preview the file, in-tact.

: >If your ISP is WebCharm-enabled, would it cost you anything?
:
: Can you provide a list of WebCharm enabled web hosts?
: I don't see why anyone would need to change their ISP, just their
: hosting solution.
:
The product is very new and we are working on partnering with ISPs
so that WebCharm can be made available. We are open to ideas on
the best way to do this.

Long
www.edgesoft.ca/go/index.html
 
L

Long

: In article <[email protected]>,
: (e-mail address removed) says...
: >
: > : Wÿrm wrote:
: > : > Is there simple way to "LOAD" external html file to some DIV?
: > : >
: > : > Basically what I wanna do is that I make menu DIV and contents DIV on
: > : > html file. I want load external HTML:s from that menu DIV to contents
: > : > DIV... I am trying to avoid using frames etc. with this.
: > : >
: > : > If it is possible, how widely it is supported by browsers?
: > :
: > : Have a look at http://www.bignosebird.com/sdocs/include.shtml
: > : Dead easy and, because it's server-side, it works across all browsers.
: > :
: > SSI #include will pull in the entire file content so you will have a mal-formed
: > final document.
:
: How did you draw that conclusion? What if the include file simply
: contains:
: This is my web page
:
: No mark-up, just plain text.
:
Sure, no arguments here, but that was not the question.

Long
www.edgesoft.ca/go/index.html
 
B

Beauregard T. Shagnasty

Long pounced upon this pigeonhole and pronounced:
: Long pounced upon this pigeonhole and pronounced:
: >
: > : Wÿrm wrote:
: > : > Is there simple way to "LOAD" external html file to some DIV?
: > : >
: > : > Basically what I wanna do is that I make menu DIV and contents DIV on
: > : > html file. I want load external HTML:s from that menu DIV to contents
: > : > DIV... I am trying to avoid using frames etc. with this.
: > : >
: > : > If it is possible, how widely it is supported by browsers?
: > :
: > : Have a look at http://www.bignosebird.com/sdocs/include.shtml
: > : Dead easy and, because it's server-side, it works across all browsers.
: > :
: > SSI #include will pull in the entire file content so you will have a mal-formed
: > final document.
: >
: > Check out my post on comp.infosystems.www.authoring.html under the
: > subject heading: How to include an HTML doc in another HTML doc
: > or you can check out WebCharm at our web site.
:
: <snip link to expensive server modification, bordering on spam>
:
: Fortunately, the Product Catalog seems to be missing, along with the
: price.
: "The product catalog is temporarily unavailable." ...
:
: The SSI will work just fine on most all capable web servers, and is free.
:
So you are ok with having mulitple <HEAD>,<TILE>, and <BODY> tags
in the generated document?

No, of course not. I would not be stupid enough to put <HEAD>,
<TILE> [sic], <BODY> etc in the include file.

Notice the OP said:

"what I wanna do is that I make menu DIV and contents DIV on html file."

He implies the menu HTML will be in a file, and the contents HTML will be
in a file. Common stuff. Doesn't need to be charmed at all.
If your ISP is WebCharm-enabled, would it cost you anything?

I'll never know.
 
L

Long

: Long pounced upon this pigeonhole and pronounced:
: > : > : Long pounced upon this pigeonhole and pronounced:
: > : >
: > : > : > : Wÿrm wrote:
: > : > : > Is there simple way to "LOAD" external html file to some DIV?
: > : > : >
: > : > : > Basically what I wanna do is that I make menu DIV and contents DIV on
: > : > : > html file. I want load external HTML:s from that menu DIV to contents
: > : > : > DIV... I am trying to avoid using frames etc. with this.
: > : > : >
: > : > : > If it is possible, how widely it is supported by browsers?
[snip]
: > : The SSI will work just fine on most all capable web servers, and is free.
: > :
: > So you are ok with having mulitple <HEAD>,<TILE>, and <BODY> tags
: > in the generated document?
:
: No, of course not. I would not be stupid enough to put <HEAD>,
: <TILE> [sic], <BODY> etc in the include file.
:
: Notice the OP said:
:
: "what I wanna do is that I make menu DIV and contents DIV on html file."
:
: He implies the menu HTML will be in a file, and the contents HTML will be
: in a file. Common stuff. Doesn't need to be charmed at all.
:
It is funny how we each interpret the OP differently. Perhaps he/she can
pitch in and clarify.

: > If your ISP is WebCharm-enabled, would it cost you anything?
:
: I'll never know.

I suppose not.
 
S

Steve Pugh

Long said:
: >: >
: >: The SSI will work just fine on most all capable web servers, and is free.
: >:
: >So you are ok with having mulitple <HEAD>,<TILE>, and <BODY> tags
: >in the generated document?
:
: Why do you ask? The files included via the SSI don't have those tags
: in them, just the content that needs including. So it's a non issue.
:
That was the question of the original poster. To include an HTML file.

The OP was looking for a frames replacement. Your solution is server
side and so would involve reloading the whole page, not just the
content portion.

The include file can and should contain only that HTML which is
needed. If they want to include an entire HTML file that they can not
edit (e.g. one from another server) then either some form of server
side scraping and reformatting is required, or another techonology
(<object>, <iframe> or even, heavens forbid, frames) would be used.

Can your system include files from another server altogether? Say I
wanted to include a page from Yahoo in the middle of one of my pages
(let's ignore the copyright issues for now).
If the include file contains some HTML mark up, how would you get a
preview without running it through the web server each time?

Local development server.
The
@charm:html tag is specialized to include an HTML file so that you can
edit and preview the file, in-tact.

Why would you want to preview the content of your include file out of
context of the whole page? Surely it wouldn't make any sense to just
preview a nav bar, for example, without seeing how that nav bar
interacted with the rest of the page.
: >If your ISP is WebCharm-enabled, would it cost you anything?
:
: Can you provide a list of WebCharm enabled web hosts?
: I don't see why anyone would need to change their ISP, just their
: hosting solution.
:
The product is very new and we are working on partnering with ISPs
so that WebCharm can be made available. We are open to ideas on
the best way to do this.

Not spamming newsgroups would be my first suggestion.

Steve
 
B

Beauregard T. Shagnasty

Long pounced upon this pigeonhole and pronounced:
: Long pounced upon this pigeonhole and pronounced:
: > : > : Long pounced upon this pigeonhole and pronounced:
: > : >
: > : > : > : Wÿrm wrote:
: > : > : > Is there simple way to "LOAD" external html file to some DIV?
: > : > : >
: > : > : > Basically what I wanna do is that I make menu DIV and contents DIV on
: > : > : > html file. I want load external HTML:s from that menu DIV to contents
: > : > : > DIV... I am trying to avoid using frames etc. with this.
: > : > : >
: > : > : > If it is possible, how widely it is supported by browsers?
[snip]
: > : The SSI will work just fine on most all capable web servers, and is free.
: > :
: > So you are ok with having mulitple <HEAD>,<TILE>, and <BODY> tags
: > in the generated document?
:
: No, of course not. I would not be stupid enough to put <HEAD>,
: <TILE> [sic], <BODY> etc in the include file.
:
: Notice the OP said:
:
: "what I wanna do is that I make menu DIV and contents DIV on html file."
:
: He implies the menu HTML will be in a file, and the contents HTML will be
: in a file. Common stuff. Doesn't need to be charmed at all.
:
It is funny how we each interpret the OP differently. Perhaps he/she can
pitch in and clarify.

Why would you interpret "a menu DIV and a content DIV" as needing to
include an HTML _page_ rather than the HTML _code_ of the menu (links,
buttons, whatever) and the text/graphics of the content in the content DIV
as an HTML _page_ ?

You're confusing a complete page with the HTML in an Include file, which
of course could be menu.html or menu.inc or menu.txt or menu.foo ...
 
L

Long

: >: >: >: >
: >: >: The SSI will work just fine on most all capable web servers, and is free.
: >: >:
: >: >So you are ok with having mulitple <HEAD>,<TILE>, and <BODY> tags
: >: >in the generated document?
: >:
: >: Why do you ask? The files included via the SSI don't have those tags
: >: in them, just the content that needs including. So it's a non issue.
: >:
: >That was the question of the original poster. To include an HTML file.
:
: The OP was looking for a frames replacement. Your solution is server
: side and so would involve reloading the whole page, not just the
: content portion.
:
Ok, but that was not my interpretation...

: The include file can and should contain only that HTML which is
: needed. If they want to include an entire HTML file that they can not
: edit (e.g. one from another server) then either some form of server
: side scraping and reformatting is required, or another techonology
: (<object>, <iframe> or even, heavens forbid, frames) would be used.
:
I have no objection to the intended use of #include. I am only sugesting
an alternative to include anything.htm.

: Can your system include files from another server altogether? Say I
: wanted to include a page from Yahoo in the middle of one of my pages
: (let's ignore the copyright issues for now).
:
No and for obvious reasons.

: >If the include file contains some HTML mark up, how would you get a
: >preview without running it through the web server each time?
:
: Local development server.

So do I.

:
: > The
: >@charm:html tag is specialized to include an HTML file so that you can
: >edit and preview the file, in-tact.
:
: Why would you want to preview the content of your include file out of
: context of the whole page? Surely it wouldn't make any sense to just
: preview a nav bar, for example, without seeing how that nav bar
: interacted with the rest of the page.

I just want to quickly check that the syntax is correct and to identify
any potential problems early on. If there was a problem when viewed in
context, it would be more difficult to isolate which include file contains the
culprit. But that is by choice.

: >: >If your ISP is WebCharm-enabled, would it cost you anything?
: >:
: >: Can you provide a list of WebCharm enabled web hosts?
: >: I don't see why anyone would need to change their ISP, just their
: >: hosting solution.
: >:
: >The product is very new and we are working on partnering with ISPs
: >so that WebCharm can be made available. We are open to ideas on
: >the best way to do this.
:
: Not spamming newsgroups would be my first suggestion.
:
Ok, would it be ok if I post my how-to series say once every few days?

Long
www.edgesoft.ca/go/index.html
 
B

Beauregard T. Shagnasty

Long pounced upon this pigeonhole and pronounced:
:
: Not spamming newsgroups would be my first suggestion.
:
Ok, would it be ok if I post my how-to series say once every few days?

This is a discussion group about html, not an advertising group. So is
c.i.w.a.h. If you did that, I'm sure someone would report you to your
abuse desk.
 
W

Wÿrm

Notice the OP said:
"what I wanna do is that I make menu DIV and contents DIV on html file."

He implies the menu HTML will be in a file, and the contents HTML will be
in a file. Common stuff. Doesn't need to be charmed at all.

Sorry if I have poked to some kinda hornets nest here with my question, it
was NOT my intention...

My plan is to generate html page where either I build "MENU" to some DIV
using external file, or i build inside of pages to some DIV...

basically it means I want have some menu where i can click link, and that
link loads new page to DIV, if possible.. if not, i am willing to go and
take route where whole "menu" is generated and placed on DIV and there in
menu i have different links to different html files (that link menu DIV)...

i would like to prefer that menu links would be capable of loading external
files to DIV (or to anything else in html), it would me "clearest" that way,
but i am willing to make sacrifices with this thing...
 
L

Long

: Long pounced upon this pigeonhole and pronounced:
: > :
: > : Not spamming newsgroups would be my first suggestion.
: > :
: > Ok, would it be ok if I post my how-to series say once every few days?
:
: This is a discussion group about html, not an advertising group. So is
: c.i.w.a.h. If you did that, I'm sure someone would report you to your
: abuse desk.
:
What you are saying is I should passively respond to questions relating to HTML
and not proactively contributing new ideas. What kind of attitude is that? If
everyone hold that kind of attitude, the net as a whole would be borrring....

My how-to series focus on a problem and present a possible solution.
Not all of them are the same thing and repeating. So I made a bad choice
of presenting two similar problems. But the next one should give you something
to think about. Unfortunately, I should wait a few days before posting just in case
I should offend anyone.

Long
 
A

Adrienne

Sorry if I have poked to some kinda hornets nest here with my question,
it was NOT my intention...

My plan is to generate html page where either I build "MENU" to some
DIV using external file, or i build inside of pages to some DIV...

basically it means I want have some menu where i can click link, and
that link loads new page to DIV, if possible.. if not, i am willing to
go and take route where whole "menu" is generated and placed on DIV and
there in menu i have different links to different html files (that link
menu DIV)...

i would like to prefer that menu links would be capable of loading
external files to DIV (or to anything else in html), it would me
"clearest" that way, but i am willing to make sacrifices with this
thing...

I think you might be after something like this. Create a file as a
template, then use the template for each new page.

*** template.shtml ***
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">

<html>
<head>
<title>Your Page Title</title>
<link type="text/css" rel="stylesheet" href="mystyle.css">
</head>
<body>
<div id="menu">
<!--#include file="menu.inc" -->
</div>
<div id="content">
Your content here
</div>
</body>
</html>

*** menu.inc ***
<ul>
<li><a href="index.shtml">Home</a></li>
<li><a href="contact.shtml">Contact</a></li>
</ul>

*** mystyle.css ***
#menu {float:left; width: 20%;}
#content {width: 75%;}

Play around with the styling, menu, etc.
 
B

Beauregard T. Shagnasty

Wÿrm pounced upon this pigeonhole and pronounced:
Sorry if I have poked to some kinda hornets nest here with my question, it
was NOT my intention...

Wÿrm, not your fault; no need to be sorry.
My plan is to generate html page where either I build "MENU" to some DIV
using external file, or i build inside of pages to some DIV...

basically it means I want have some menu where i can click link, and that
link loads new page to DIV, if possible.. if not, i am willing to go and
take route where whole "menu" is generated and placed on DIV and there in
menu i have different links to different html files (that link menu DIV)...

i would like to prefer that menu links would be capable of loading external
files to DIV (or to anything else in html), it would me "clearest" that way,
but i am willing to make sacrifices with this thing...

Adrienne has posted the basic layout of a template for you. Use that as a
guide to create "template.shtml".

Place all your <head> and <meta> elements in it, including the doctype.
All your menu code goes in the included file and will be the same on every
page you create with the template. When you want a new page, make a copy
of the template with the new page file name. Add a link to it in
"menu.inc". Add the content and upload the new page, and the changed
menu.inc and the menu will show on all pages.

Unless you have a quite large site, you could just place the content
between the body tags. If you do have a large site, you should consider
some sort of server-side scripting that assembles the pages on the fly.

Hope this helps.
 
B

Beauregard T. Shagnasty

Long pounced upon this pigeonhole and pronounced:
: Long pounced upon this pigeonhole and pronounced:
: > :
: > : Not spamming newsgroups would be my first suggestion.
: > :
: > Ok, would it be ok if I post my how-to series say once every few days?
:
: This is a discussion group about html, not an advertising group. So is
: c.i.w.a.h. If you did that, I'm sure someone would report you to your
: abuse desk.
:
What you are saying is I should passively respond to questions relating to HTML
and not proactively contributing new ideas.

Never said that. What do you consider the difference between passive
response to questions as opposed to proactively con.. giving a questioner
a new or better way to accomplish his/her goal?
What kind of attitude is that? If
everyone hold that kind of attitude, the net as a whole would be borrring....

It's an attitude to keep spamming out of these discussion groups, that's
all.

Wait. Proactively. "Acting in advance to deal with an expected
difficulty; anticipatory." [1] Are you saying you want to post in
*advance* of someone asking a particular question? 'Fraid that's not how
it works.
My how-to series focus on a problem and present a possible solution.

Are you referring to your Charm site or something else? Hey, if you have a
how-to (translate: tutorial?) that answers a question, by all means give a
link to the page that solves the problem. If it's free. If the solution
costs money, then don't.

Is there a tutorial? What's the link?
Not all of them are the same thing and repeating. So I made a bad choice
of presenting two similar problems. But the next one should give you something
to think about. Unfortunately, I should wait a few days before posting just in case
I should offend anyone.

Consider this: if you start a new thread advertising some new whizz-bang
technology - especially one that is not free - then you are spamming.

"Come look at my site and see how you can make life easier!" as a new post
won't work.

[1] http://dictionary.reference.com/search?q=proactively&db=*
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,015
Latest member
AmbrosePal

Latest Threads

Top