Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Javascript > conditionally combining multiple html files

Reply
Thread Tools

conditionally combining multiple html files

 
 
alwayswinter@gmail.com
Guest
Posts: n/a
 
      07-13-2005
I currently have a form where a user can enter results from a genetic
test. I also have a pool of summaries that would correspond to
different results that a user would enter into the form. I ideally I
would like to have the user enter their results and then have a master
summary created with the different word or HTML files on submit.
(condition 1 + condition 2 = combining/displaying corresponding HTML
files) I've gotten as far as creating the form and conditionally
launching IE, but it is the combining of the HTML files based on the
if/then statements I am having trouble with, if anyone has any
suggestions it would be very helpful? I'm using HTML, PHP, Javascript
with a little help from dreamweaver.

 
Reply With Quote
 
 
 
 
web.dev
Guest
Posts: n/a
 
      07-13-2005
Hi alwayswin,

The problem with is this, Javascript does not have a mechanism in which
it can include HTML files. What you probably want to do is use PHP
instead and use the 'require()' or the 'include()' function to bring in
HTML pages.

 
Reply With Quote
 
 
 
 
Christopher J. Hahn
Guest
Posts: n/a
 
      07-13-2005
http://www.velocityreviews.com/forums/(E-Mail Removed) wrote:
> I currently have a form where a user can enter results from a genetic
> test. I also have a pool of summaries that would correspond to
> different results that a user would enter into the form. I ideally I
> would like to have the user enter their results and then have a master
> summary created with the different word or HTML files on submit.
> (condition 1 + condition 2 = combining/displaying corresponding HTML
> files) I've gotten as far as creating the form and conditionally
> launching IE, but it is the combining of the HTML files based on the
> if/then statements I am having trouble with, if anyone has any
> suggestions it would be very helpful? I'm using HTML, PHP, Javascript
> with a little help from dreamweaver.


Could be done with JavaScript, but personally I'd recommend using PHP's
include function (or is it a keyword?). I think it'd make for a very
easy, very flexible way of implementing combinations of document
fragments. Each fragment could also include its own PHP code if you
wanted to go that way.

 
Reply With Quote
 
Randy Webb
Guest
Posts: n/a
 
      07-14-2005
web.dev wrote:

> Hi alwayswin,
>
> The problem with is this,


The main problem with this post is you don't know (or choose not to) how
to quote.

> Javascript does not have a mechanism in which it can include HTML files.


Sure it does. But whether the UA supports it or not is another question.

> What you probably want to do is use PHP instead and use the 'require()'
> or the 'include()' function to bring in HTML pages.


He would probably end up better off including fragments rather than
complete HTML pages.

--
Randy
comp.lang.javascript FAQ - http://jibbering.com/faq & newsgroup weekly
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Using different header files and selecting conditionally Ishmagel C++ 2 08-13-2009 11:27 AM
how to conditionally include html files in asp.net page ningjun.wang@lexisnexis.com ASP .Net 1 12-17-2006 08:40 AM
Conditionally disable html control? Jens Weiermann ASP .Net 2 03-08-2006 02:09 PM
Text files read multiple files into single file, and then recreate the multiple files googlinggoogler@hotmail.com Python 4 02-13-2005 05:44 PM
log4j writing to multiple logs conditionally Arvind Java 2 05-24-2004 10:31 AM



Advertisments