Enhancing the Gateway (Help Needed)

  • Thread starter James Edward Gray II
  • Start date
J

James Edward Gray II

Do you think *anyone* would ever attempt to read a post which would
show
its html source as plain text (that will happen if you force the
content-type of a html mail to text/plain)? I guess you should either
drop those or try to strip the html tags.

You make a good point. I was hoping the formatting would be minimal,
but who knows.

I just checked and the gateway's server has lynx on it. Can we strip
with that?

Maybe we should just drop these. Again, I can't find any recent
messages like this.

James Edward Gray II
 
T

Thomas Adam

I just checked and the gateway's server has lynx on it. Can we strip
with that?

Ewww, no. This is ugly at best.
Maybe we should just drop these. Again, I can't find any recent
messages like this.

Just drop them. It's the easiest solution.

-- Thomas Adam
 
B

Bill Kelly

From: "James Edward Gray II said:
You make a good point. I was hoping the formatting would be minimal,
but who knows.

I just checked and the gateway's server has lynx on it. Can we strip
with that?

Or maybe parse it with Hpricot, then ask the document to yield
just the text nodes? Hpricot is reportedly good at even parsing
malformed HTML. (Not sure whether or not entities will be converted
when retrieving the text nodes, though... whether you'll still see
& or get the representitive "&" character, for example.)

Maybe we should just drop these. Again, I can't find any recent
messages like this.

Yeah, I didn't notice any text/html at all in your sample data (?)

One thing I did notice, is that when you (James) have forwarded
ruby quiz submissions to the list they were encoded like:

Content-Transfer-Encoding: 7bit
Content-Type: application/octet-stream;
x-unix-mode=0666;
name=time_window.rb
Content-Disposition: attachment;
filename=time_window.rb

It would be nice to preserve those; but I have no idea whether it
makes sense to just pretend ALL "application/octet-stream" is just
"text/plain". :)


Regards,

Bill
 
J

James Edward Gray II

Yeah, I didn't notice any text/html at all in your sample data (?)

Right.

This seems to be the majority opinion, so I'll try this.
One thing I did notice, is that when you (James) have forwarded
ruby quiz submissions to the list they were encoded like:

Content-Transfer-Encoding: 7bit
Content-Type: application/octet-stream;
x-unix-mode=0666;
name=time_window.rb
Content-Disposition: attachment;
filename=time_window.rb

It would be nice to preserve those; but I have no idea whether it
makes sense to just pretend ALL "application/octet-stream" is just
"text/plain". :)

Well, if it's some problem with me that's good news, because I can be
fixed. ;)

Was the overall type of the email application/octet-stream? I would
assume it was multipart/mixed and you are just showing the attachment
portion here. Our host does allow us to send multipart/mixed. Was
the message in question gated?

James Edward Gray II
 
B

Bill Kelly

From: "James Edward Gray II said:
Well, if it's some problem with me that's good news, because I can be
fixed. ;)

Was the overall type of the email application/octet-stream? I would
assume it was multipart/mixed and you are just showing the attachment
portion here. Our host does allow us to send multipart/mixed. Was
the message in question gated?

Ah. LOL. Not only was it indeed gated to Usenet, it apparently was
NOT preserved in the ruby-talk archive. (But it did appear on the
mailing list.)

Yeah, it was multipart/mixed.
http://groups.google.com/group/comp.lang.ruby/msg/ad72badfe1ad61fa?dmode=source


Sorry for the noise,

Bill
 

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

Similar Threads


Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,007
Latest member
obedient dusk

Latest Threads

Top