Re: [mp2] missing Apache::Util::escape_html

2004-10-06 Thread David Wheeler
On Oct 6, 2004, at 2:48 PM, Stas Bekman wrote: Nope. I've just assumed that you already read the doc before submitting a bug report and it wasn't there. Indeed it already covers that :) D'oh! Thanks, David - To unsubscribe, e-mai

Re: [mp2] missing Apache::Util::escape_html

2004-10-06 Thread Stas Bekman
David Wheeler wrote: On Oct 5, 2004, at 5:45 PM, Stas Bekman wrote: I wasn't suggesting that you do that, just asking for your opinion, but if you want to, that's great! There are two places that need to be fixed, on in Util.pm in the modperl source, the other is in src/docs/1.0/api/Apache/Util.

Re: [mp2] missing Apache::Util::escape_html

2004-10-06 Thread David Wheeler
On Oct 5, 2004, at 5:45 PM, Stas Bekman wrote: I wasn't suggesting that you do that, just asking for your opinion, but if you want to, that's great! There are two places that need to be fixed, on in Util.pm in the modperl source, the other is in src/docs/1.0/api/Apache/Util.pod. Oh, I see it alr

Re: [mp2] missing Apache::Util::escape_html

2004-10-05 Thread Stas Bekman
David Wheeler wrote: On Oct 5, 2004, at 5:25 PM, Stas Bekman wrote: So David, I guess we will do the same for mp1 too? http://perl.apache.org/docs/1.0/api/Apache/Util.html Since when did I become the maintainer of mp1? ;-) I wasn't suggesting that you do that, just asking for your opinion, but if

Re: [mp2] missing Apache::Util::escape_html

2004-10-05 Thread David Wheeler
On Oct 5, 2004, at 5:25 PM, Stas Bekman wrote: So David, I guess we will do the same for mp1 too? http://perl.apache.org/docs/1.0/api/Apache/Util.html Since when did I become the maintainer of mp1? ;-) Yeah, I can document it, but it'd be nice to see it fixed, too. Regards, David --

Re: [mp2] missing Apache::Util::escape_html

2004-10-05 Thread Stas Bekman
David Wheeler wrote: On Oct 5, 2004, at 5:04 PM, Stas Bekman wrote: so, I'm +1 to forget all about an Apache::Util::escape_html in mp2 core. Works for me. So should I just adjust: http://perl.apache.org/docs/2.0/user/porting/ compat.html#C_Apache__Util__escape_html___ to say, use HTML::Entities

Re: [mp2] missing Apache::Util::escape_html

2004-10-05 Thread David Wheeler
On Oct 5, 2004, at 5:04 PM, Stas Bekman wrote: so, I'm +1 to forget all about an Apache::Util::escape_html in mp2 core. Works for me. So should I just adjust: http://perl.apache.org/docs/2.0/user/porting/ compat.html#C_Apache__Util__escape_html___ to say, use HTML::Entities instead? Yes, better

Re: [mp2] missing Apache::Util::escape_html

2004-10-05 Thread Philippe M. Chiasson
Stas Bekman wrote: Geoffrey Young wrote: Of course we could just say: use HTML::Entities to do the work, but I believe it's slow(er?), as it's implemented in perl... I don't think it's our job to create a C implementation. perl people have HTML::Entities, which is excellent. if they want someth

Re: [mp2] missing Apache::Util::escape_html

2004-10-05 Thread Stas Bekman
Geoffrey Young wrote: Of course we could just say: use HTML::Entities to do the work, but I believe it's slow(er?), as it's implemented in perl... I don't think it's our job to create a C implementation. perl people have HTML::Entities, which is excellent. if they want something faster they can

Re: [mp2] missing Apache::Util::escape_html

2004-10-05 Thread Geoffrey Young
> Of course we could just say: use HTML::Entities to do the work, but I > believe it's slow(er?), as it's implemented in perl... I don't think it's our job to create a C implementation. perl people have HTML::Entities, which is excellent. if they want something faster they can code it themselve

Re: [mp2] missing Apache::Util::escape_html

2004-10-05 Thread Stas Bekman
Philippe M. Chiasson wrote: [...] Alternatively we could just borrow ap_escape_html and rewrite it to not use the pool, but Perl's memory allocator. Or just use ap_escape_html but create/destroy a temporary pool for it to use ? -1, you will need to copy the string twice to move it into the Perl

Re: [mp2] missing Apache::Util::escape_html

2004-10-05 Thread David Wheeler
On Oct 5, 2004, at 4:28 PM, Stas Bekman wrote: Let's see first how do we resolve that for mod_perl 2. And once we do, remind us of this issue. Of course for mp1 you could use HTML::Entities, couldn't you? I do. Regards, David - T

Re: [mp2] missing Apache::Util::escape_html

2004-10-05 Thread David Wheeler
On Oct 5, 2004, at 4:25 PM, Stas Bekman wrote: So there is no CPAN lib that does that in C? Not that I know of. But keeping track of the flag should be dead simple. See the Encode sources. No, let me share them with you: SV * _utf8_on(sv) SV *sv CODE: { if (SvPOK(sv)) { SV *rsv =

Re: [mp2] missing Apache::Util::escape_html

2004-10-05 Thread Philippe M. Chiasson
Stas Bekman wrote: David Wheeler wrote: On Oct 5, 2004, at 3:37 PM, Stas Bekman wrote: Of course we could just say: use HTML::Entities to do the work, but I believe it's slow(er?), as it's implemented in perl... It is slower, but it's also more correct, in that it doesn't turn of the utf8 flag

Re: [mp2] missing Apache::Util::escape_html

2004-10-05 Thread Stas Bekman
David Wheeler wrote: On Oct 5, 2004, at 4:15 PM, Philippe M. Chiasson wrote: How about resolving the issue by porting the my_escape_html() from mp1 to mp2 ? Any chance we could get this issue resolved while we're at it? http://www.mail-archive.com/dev%40perl.apache.org/msg08065.html Let's see fi

Re: [mp2] missing Apache::Util::escape_html

2004-10-05 Thread Stas Bekman
David Wheeler wrote: On Oct 5, 2004, at 3:37 PM, Stas Bekman wrote: Of course we could just say: use HTML::Entities to do the work, but I believe it's slow(er?), as it's implemented in perl... It is slower, but it's also more correct, in that it doesn't turn of the utf8 flag of the strings passe

Re: [mp2] missing Apache::Util::escape_html

2004-10-05 Thread David Wheeler
On Oct 5, 2004, at 4:15 PM, Philippe M. Chiasson wrote: How about resolving the issue by porting the my_escape_html() from mp1 to mp2 ? Any chance we could get this issue resolved while we're at it? http://www.mail-archive.com/dev%40perl.apache.org/msg08065.html Regards, David ---

Re: [mp2] missing Apache::Util::escape_html

2004-10-05 Thread Stas Bekman
Philippe M. Chiasson wrote: [...] though todo/features_missing suggests: * escape_html() - consider jeff baker's more robust implementation of my_escape_html(), which should probably be made in apache-2.0 itself (is there apache api? or just drop it) Anybody has an idea what code is being men

Re: [mp2] missing Apache::Util::escape_html

2004-10-05 Thread David Wheeler
On Oct 5, 2004, at 3:37 PM, Stas Bekman wrote: Of course we could just say: use HTML::Entities to do the work, but I believe it's slow(er?), as it's implemented in perl... It is slower, but it's also more correct, in that it doesn't turn of the utf8 flag of the strings passed to it. Regards, Dav

Re: [mp2] missing Apache::Util::escape_html

2004-10-05 Thread Philippe M. Chiasson
Stas Bekman wrote: Marcus has just reminded me that Apache::Util::escape_html fell of our radars: http://perl.apache.org/docs/2.0/user/porting/compat.html#C_Apache__Util__escape_html___ As the above URL suggests, Messiah is coming really soon now, or in other words, we were waiting for ap_escape_