Newbie howto question.
- From: Longfellow <not@xxxxxxxxxxxx>
- Date: Tue, 26 Apr 2005 00:19:00 -0000
I'm just learning how to program, so my question is probably elementary.
Apologies where appropriate.
I've got an ASCII text file (a GEDCOM file) comprised of many records of
tagged information. I've used an application to create a webpage for
each individual record, but now I want to add further information from
each record to the related web page. Each html filename is $GEDCOM_ID
with the '.html' suffix.
So far, I can open the GEDCOM file and identify a record, and then open
the related html file. I can identify the tagged information, extract
said info and write it to the html file, closing the html file before
going to the next record.
What I'm trying to figure out is an elegant way of inserting the
information into the correct place in the html file. All I can think to
do is read each html file into a buffer, testing for the relevant line,
then replace it with the revised line, and write the buffer back out
again, overwriting the file that was read in. What easier approach am I
missing?
I'm using ANSI C and wish to avoid any non-standard usages.
I considered asking in comp.lang.c, but I get the feeling my question
isn't appropriate there. Read this NG charter, decided this was an
algorithm matter, so posted here.
All comments and replies appreciated.
Thanks,
Longfellow
.
- Follow-Ups:
- Re: Newbie howto question.
- From: rossum
- Re: Newbie howto question.
- From: Phlip
- Re: Newbie howto question.
- Prev by Date: Re: I need advise on what program to use.
- Next by Date: Re: Invoking a function through function pointer
- Previous by thread: .NET Framework Class Library | PictureBox class | how to display an image which is in memory
- Next by thread: Re: Newbie howto question.
- Index(es):
Relevant Pages
|