Saving Classic ASP in UTF-8 Format

R

RobertHillEDS

I have classic asp files (IIS6) that need to be saved in UTF-8 format. I
save a file with Notepad using SAVE-AS & UTF-8 format. If I reopen the file
using Notepad and bring up the save-as dialog is defaults to UTF-8, which is
good. But after the file is modified and saved using Visual Interdev the
format switches back to ANSI format, which causes some international
characters to display as little boxes in the browser. I found one comment on
the internet about making sure the Meta tag with Charset=UTF-8 must be in the
file to instruct interdev to use the UTF-8 format when saving. This seems to
work on some .asp files but not all.

Any suggestions would be appreciated.

Thank You
 
E

Evertjan.

=?Utf-8?B?Um9iZXJ0SGlsbEVEUw==?= wrote on 03 aug 2007 in
microsoft.public.inetserver.asp.general:
I have classic asp files (IIS6) that need to be saved in UTF-8 format.
I save a file with Notepad using SAVE-AS & UTF-8 format. If I reopen
the file using Notepad and bring up the save-as dialog is defaults to
UTF-8, which is good. But after the file is modified and saved using
Visual Interdev the format switches back to ANSI format, which causes
some international characters to display as little boxes in the
browser.

Any suggestions would be appreciated.

Don't use Visual Interdev, I don't.
I found one comment on the internet about making sure the
Meta tag with Charset=UTF-8 must be in the file to instruct interdev
to use the UTF-8 format when saving. This seems to work on some .asp
files but not all.

I would not know about this.
 
A

Anthony Jones

RobertHillEDS said:
I have classic asp files (IIS6) that need to be saved in UTF-8 format. I
save a file with Notepad using SAVE-AS & UTF-8 format. If I reopen the file
using Notepad and bring up the save-as dialog is defaults to UTF-8, which is
good. But after the file is modified and saved using Visual Interdev the
format switches back to ANSI format, which causes some international
characters to display as little boxes in the browser. I found one comment on
the internet about making sure the Meta tag with Charset=UTF-8 must be in the
file to instruct interdev to use the UTF-8 format when saving. This seems to
work on some .asp files but not all.

Any suggestions would be appreciated.

You should also have:-

<%@ codepage=65001 %>

at the top of your page.
 
R

RobertHillEDS

--
Robert Hill


Anthony Jones said:
You should also have:-

<%@ codepage=65001 %>

at the top of your page.
Here is a sample asp page, that always reverts back to ANSI format when
saved by visual Interdev.

<%@ Language=VBScript %>
<%@ codepage=65001 %>

<%
'language Indicator
Const SPANISH = "SPA"
Const ENGLISH = "ENG"
dim mvarLangCd

mvarLangCd = Ucase(Request.QueryString("LangCd"))
If mvarLangCd = "" Then
mvarLangCd = ENGLISH
End If
%>



<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=UTF-8">
<META NAME="GENERATOR" Content="Microsoft Visual Studio 6.0">
<LINK rel="stylesheet" type="text/css" href="../_Themes/EPayStyleSheet.css">
<TITLE><%=HTML_PAGE_TIMEOUT%></TITLE>
</HEAD>
<BODY>
<table width="558" border=0>
<tr><td>
<P class=ScreenTitle align=center>TimeOut</P>
</td></tr>
<tr height=45><td>
</td></tr>
<tr><td>
<P class=BottomInfo align=center>time out</P>
</td></tr>
</table>
</BODY>
</HTML>

Robert
 
A

Anthony Jones

RobertHillEDS said:
--
Robert Hill



Here is a sample asp page, that always reverts back to ANSI format when
saved by visual Interdev.

<%@ Language=VBScript %>
<%@ codepage=65001 %>

Try:-
 

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

Members online

Forum statistics

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

Latest Threads

Top