I have a URL with unicode characters in it
http://www.argaam.com/Common/Handlers/DownloadAttachment.aspx?referer=/portal&fileName=اعمار. -الربع الثاني_633857794599657020.pdf&folder=\CompanyFinancialResults\
this is working fine in FireFox and Chrome and Safari but when the request if sent from IE the server sends me to an Error page.
OK i got the request the server recieves and its like this
IE
GET /Common/Handlers/DownloadAttachment.aspx?referer=/portal&fileName=?????.%20-?????%20??????_633857794599657020.pdf&folder=\CompanyFinancialResults\ HTTP/1.1
FireFox
GET /Common/Handlers/DownloadAttachment.aspx?referer=/portal&fileName=%D8%A7%D8%B9%D9%85%D8%A7%D8%B1.%20-%D8%A7%D9%84%D8%B1%D8%A8%D8%B9%20%D8%A7%D9%84%D8%AB%D8%A7%D9%86%D9%8A_633857794599657020.pdf&folder=\CompanyFinancialResults\ HTTP/1.1
So for some reason IE is not encoding the multibyte characters properly !!
Anyone has any idea why?
Your link should be URLEncoded when placed in the HTML, rather than relying on the browser to try to encode the URL for you. (IE's behavior for which varies depending on the client's OS/language, etc).
It looks like the URL has multi-byte characters in it, I havent expereinced this, so not sure if thats part of the issue? Also the URL looks like it has a filename, it could be that filenames with those characters cannot exist or the file does not exist?
Try making the registry changes documented on this page at Microsoft:
Internet Explorer May Not Connect to Web Sites with Multibyte Character Set Link or URL
To work around this behavior, you must add a registry value. Add a DWORD registry value named MBCSServername with a data value of 0 to the following registry key:
HKEY_CURRENT_USER\Software\Policies\Microsoft\Windows\CurrentVersion\Internet Settings
Related
CSS files not rendered in IE 9 and 10 but works good in compatibility mode.
I am the following error get "SEC7113: CSS was ignored due to mime type mismatch" in IE 10 .
wherein i don't get a content-type in my response header!
Further this is on my local.
Any suggestions could be appreciated.
It has an answer, summary would be:
As due to MIME type mismatch css was ignored in IE 9 and 10. The MIME type can be correct by utility called File TypesMan It is freeware created by NirSoft. It turned out that the MIME type of .css had been changed to text/plain, preventing IE from rendering my styles. using FileTypesMan to change it back to text/css fixed the problem.
Download FileTypesMan from the NirSoft site. Use the links near the bottom of the page to select the correct version for your operating system (there are different versions for 32-bit, 64-bit, and Windows 98/ME).
Unzip the files to a local folder, and double-click FileTypesMan.exe.
When FileTypesMan has finished listing all file types, scroll down in the top pane to find .css.
Double-click to edit the settings.
Change the value to text/css in the MIME Type field in the dialog box that opens.
Click OK. Job done.
IE 10 should now behave itself (well, at least as far as rendering style sheets is concerned).
Not my work: Its not my own search, you can see this here: https://stackoverflow.com/a/18791928/1762944
I hope this fixed you!
I was wondering that you are not writing type="text/css" but you said, that you are! So I found this the next helpfull article! It has the same issue as yours. SEC7113: CSS was ignored due to mime type mismatch
I just did a simple Google search for the issue, and this was the first result! You should have searched for the issue.
Please ensure that the CSS file gets delivery with the correct "Content-Type" from the server. It must be "text/css". Use the developer console to determine the current type.
Potentially you need to adjust/create the MIME type mapping (e.g. for httpd).
hth
Try to specify the attribute type="text/css" in your tag. Place your style tag in <head> section.
I was having similar problem with an embedded micro-controller (not a lot of control over the server changing content type). Not sure if this applies but I found going into Settings->Compatibility View Settings and adding the IP (site) address the CSS was accepted and the page rendered properly.
I have an issue with IE, when sending a querystring with special characters in it as for instance with the "Ø" (name=bjørn) in asp.net will be somehow encoded into "name=bj%ufffdrn", "ø" gets translated into "%ufff"
I would like to know, how to decode this into the right charaters.
This only happens with IE not with FF, Ch or opera.
Any ideas?
Thanks!
Firstly, you shouldn't be using htmlspecialchars to encode a URL. In PHP use urlencode (see http://uk3.php.net/manual/en/function.urlencode.php). Then ASP.NET should decode the URL parameters for you.
I am trying to allow the user to download an excel file, by using
Response.Redirect(
"http://localhost/myapp/download_folder/example excel file_july.xls")
in page load of an ASP.net page
but on the client side i a m getting the following screen in firefox 3.5
You can observe that the file name and file type are shown as empty fields. The ok and cancel buttons are not doing anything.
This happens only in firefox 3.5, it is working in firefox later versions and other browsers.
I tried clearing the Response with Response.Clear(), using Response.BinaryWrite with the file byte array and even tried to open the file with the javascript by calling window.open(url).
you are doing it the wrong way.
just as an example, look at what is done in the question body here:
How to download file and reload
in your case you should probably use an overload of Response.Write.
the point is that you should set some Response headers to tell the browser file name, file length and content type at least.
On our site, I use the category (in Russian) in the querystring.
E.g.: http://www.odinklik.ru/kategoriya.aspx?cat=люди
If you paste this link in IE8, it is translated to cat=???? and it does not work
If I paste it in FireFox, it works.
It gets even more weird: the same URL is reachable from the homepage, and if I click the same URL in IE8 from the homepage it works fine (unless I click open in a new tab, that it is back to ????).
I am using ASP.NET 3.5(C#)
Did you try to do encoding on first page and decode from Cyrillic to Unicode and back?
Little bit a headache but surly will work.
You should URL-encode the category name before adding it to the querystring, rather than relying on the browser to do that for you.
The method HttpServerUtility.UrlEncode should be able to handle this encoding for you.
HttpServerUtility.UrlEncode should give you the link http://www.odinklik.ru/kategoriya.aspx?cat=%D0%BB%D1%8E%D0%B4%D0%B8, which should give you the correct result.
(Note that %D0%BB corresponds to л, %D1%8E to ю, %D0%B4 to д and %D0%B8 to и. As the Unicode values for Cyrillic characters are over U+ff, you will require two URL-encoding bytes for each character.)
I'm still having problems with loading the style sheet for these pages. Works fine in Safari but ff and IE, no joy:
http://www.mainstayprojects.com/teardrop.html andb
www.mainstayprojects.com
Although i am more clear as to what's causing this problem, thanks the the answers to my previous posting (stackoverflow.com/questions/3273655/css-file-not-loading), I am at a loss to how to fix the issue. I have re-saved many times with different doctypes and content type meta tag as well as saving the file as a charset=utf-8 file but have not been able make any headway!
Really need some help.
Your server is still claiming the HTML document is ISO-8859-1 (although the document itself looks like UTF-8).
Meanwhile the stylesheet appears to be UTF-8, the server fails to state what encoding it is, and the first line of the stylesheet claims that it is UTF-16.
Pick an encoding
Configure your editor to use it
Configure your server to specify it
If you put any information about the encoding at the document level — get it right!