Re: URL filter and URL encoding problem
- From: "flyingco" <zhouyou3000@xxxxxxxxx>
- Date: 30 Nov 2006 03:02:58 -0800
Ivan Brugiolo :
Thank you very much! It is very kind of you!
I have resolved it in accord to what you have said!
"Ivan Brugiolo [MSFT] 写道:
"
Your URL below is UTF-8 encoded and then URL-encoded.
Your translation assumes it's only URL-encoded.
--
--
This posting is provided "AS IS" with no warranties, and confers no rights.
Use of any included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm
"flyingco" <zhouyou3000@xxxxxxxxx> wrote in message
news:1164797476.405380.275120@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
1)I have done many tests with UrlEscape(), and I found that UrlEscape
will not encode chinese char.
2)I also found that there are various of URL encoding functions,but
when I use them to encode
"ÖÐÎÄÒ³Ãæ".htm,it will be encoded to "%D6%D0%CE%C4%D2%B3%C3%E6.htm"
,not "%E4%B8%AD%E6%96%87%E9%A1%B5%E9%9D%A2.htm".but What my tdi driver
intercepted was "%E4%B8%AD%E6%96%87%E9%A1%B5%E9%9D%A2.htm".
So far , I have yet not foud the resolution. who can give me some
advice? It had afflicted me for quite a few days.
"flyingco дµÀ£º
"
thanks ,I am try it with your ways
"Max Paklin дµÀ£º
"
UrlEscape/UrlUnescape should do it.
-- Max Paklin.
"Tim Roberts" <timr@xxxxxxxxx> wrote in message
news:9a0cm2156891u1agcpnmrfr22dnak2da6c@xxxxxxxxxx
"flyingco" <zhouyou3000@xxxxxxxxx> wrote:
URL filter and URL encoding problem
I am developing a tdi driver to filter a url.but if the url contains
chinese char,the url will be encoded.
For example :
url:http://194.0.0.84/????????.htm
when my tdi driver intercept the packet, I find that "????????.htm"
has been encoded to "%E4%B8%AD%E6%96%87%E9%A1%B5%E9%9D%A2.htm"
when I decode it with utf8 ,the content still is not decoded;
Right, because that string is not UTF8-encoded. It is URL-encoded.
After
you expand the % strings, THEN you will have a UTF8 string.
I am not aware of any Win32 APIs to decode URLs, so you may have to do
it
by hand.
--
Tim Roberts, timr@xxxxxxxxx
Providenza & Boekelheide, Inc.
.
- References:
- Re: URL filter and URL encoding problem
- From: flyingco
- Re: URL filter and URL encoding problem
- From: Ivan Brugiolo [MSFT]
- Re: URL filter and URL encoding problem
- Prev by Date: RE: Virtual USB bus driver for windows problem
- Next by Date: RE: Virtual USB bus driver for windows problem
- Previous by thread: Re: URL filter and URL encoding problem
- Next by thread: Re: how can I filter some URL by TDI?
- Index(es):
Relevant Pages
|