|
From: Ioannis V. <no...@ho...> - 2002-05-30 18:10:37
|
Honestly speaking, an engine swapping out html stuff doesn't sound
difficult. Simply you have an array of phrases to be removed (like
<HTML>) and check every word against it.
In a pseudocode C++ style:
vector<string>html;
string word;
// ...
do
{
// read from file a word
for(vector<string>::size_type i=0; i<html.size(); i++)
if(word==html[i])
{
// replace word in file with ""
}
}while(not eof);
This is my first thought. I guess we can optimise it more with binary
searching in html[] etc..
But i can't do it in ASP, or CGI etc yet. :)
Ioannis
* Ioannis Vranos
* Programming pages: http://www.noicys.cjb.net
* Alternative URL: http://run.to/noicys
> -----Original Message-----
> From: dev...@li...
> [mailto:dev...@li...] On Behalf
> Of Hongli Lai
> Sent: Thursday, May 30, 2002 6:44 PM
> To: Bob Wilson
> Cc: Dev-C++ User Mailing List
> Subject: Re: [Dev-C++] HTML vs. Plain text
>
>
> On Thu, 2002-05-30 at 15:58, Bob Wilson wrote:
> > > I have noticed that a lot of you are sending HTML mesgs
> > > to the ML. As it seems that the sourceforge.net as not
> (yet ?) implemented
> > > the "HTML remover tool" as on other MLs I know elsewhere,
> it would be fine
> > if
> > > you turn OFF the HTML email on yours computers.
> > > No need to explain why .. ;o)
> >
> > Perhaps the answer is to implement HTML or the remover tool
> on the server
> > rather than change the input. Capabilities should be
> increased rather than
> > restricted.
> >
> >
>
> If you're willing to dig into the source code, implement it,
> and send a
> patch, please go ahead and do it.
|