Jump to content

"Include" part of a document


rosmith

Recommended Posts

I am using the INCLUDE command to include HTML document B into HTML document A.  I would also like to be able to include part, but not all, of HTML document B into HTML document C.  Can anyone tell me how to include part of a document and can it be done without compromising the ability to call all of that document?  Thanks for any help.

Link to comment
Share on other sites

I'm not too sure why you need to include an HTML document into another HTML document...And no, I'm not aware of a way to just include from a certain point.  I mean, I'm pretty sure it can be done, but it would be really complicated.  Show me an example of what is in documents A, B, and C.

Link to comment
Share on other sites

The specifics involve an HTML document which contains a listing of events chronologically.  At one place in the web site, I want to show the entire list (approximately four months worth).  At another place, I want to show only a portion of the events (approximately two weeks worth).  I don't have the option of utilizing a database and specifying a date range.  I need to be able to be able to call the information from an HTML file.

Link to comment
Share on other sites

How in the world do you not have the option of using a database?  Nearly every reputable web host these days offers at least SOME MySQL support with a package that has PHP.  Doing the whole "include part of an HTML document" thing is going to be ridiculously convoluted and not guaranteed to work if something changes.

Link to comment
Share on other sites

The details of why a database option in not available to me are not relevant to my question, nor would I bore the forum with the office politics which make it so.  I'm trying to work within the limitations which I have been given.  If it's not possible to achieve simply within those limitations, good enough.  But if someone can help me, then great.

Link to comment
Share on other sites

I don't know why you can't use a database, but I don't want to be bored by office politics, this I agree :-)

 

You need to see if there is any pattern to the structure of your 'B' document, look into perl regular expression

and see if you can parse with Regular Expressions.

 

Or, if you can't use a database but can use CSV files why not put the data in a CSV file? (Or would you

call this a database too)

 

Or, put the data into an XML file and parse that where required.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.