How can ASP support multiple languages?

R

Ray at

CM said:
Hi, there:

I have some questions, I hope someone can briefly describe how ASP (not
ASP.Net) to do the following things:

1) Get real-time information from other web site such as tracking via
Fed-Ex;

Your best bet is to research with Fed Ex to see if they offer a component,
rather than trying to use xmlhttp to try to "screen scrape" their site or
something like that.
2) Real-time credit card charging via a payment gateway such as WorldPay;

Your processor should either provide you with a component to use on your
server a link to their server and transactions will take place there.

3) How to support multiple languages.

Write your pages in multiple langues. :/

Ray at work
 
C

CM

Hi, there:

I have some questions, I hope someone can briefly describe how ASP (not
ASP.Net) to do the following things:

1) Get real-time information from other web site such as tracking via
Fed-Ex;

2) Real-time credit card charging via a payment gateway such as WorldPay;

3) How to support multiple languages.

Thanks a lot!

CM
 
C

CM

Thank you very much for the quick answer!
So, for the multiple languages question, that means ASP doesn't support
multiple languages. But ASP.Net can, Am I right?
CM
 
R

Ray at

By multiple languages, you mean English and Portuguese, for example, not
vbscript and jscript, yes?

What I believe that some people do is put all their page contents in a
database, and have a table (or column, or whatever) for each language. And
to determine the language to default to, you can use
request.SErvervariables("HTTP_ACCEPT_LANGUAGE"). Maybe something like:

<%
Dim sLanguage
sLanguage = UCase(Left(Request.sErverVariables("HTTP_ACCEPT_LANGUAGE"), 2))
sSQL = "SELECT [PageContent] FROM [" & sLanguage & "] WHERE [PageID]=1"
Set oADO = Server.CreateObject("ADODB.Connection")
oADO.Open YourConnectionString
Set rsContent = oADO.Execute(sSQL)
sContent = rsContent.Fields.Item(0).Value
rsContent.Close : Set rsContent = Nothing
oADO.Close : Set oADO = Nothing


Response.Write sContent
%>

This is where you'd have a database with a table named EN and a table named
PT, and those tables would contain the content in the appropriate language.
This, of course, isn't how you'd have to structure your DB, but in theory,
this is one way to do it.

Ray at work
 
C

CM

Thanks a lot! This is just what I want to know.
CM

Ray at said:
By multiple languages, you mean English and Portuguese, for example, not
vbscript and jscript, yes?

What I believe that some people do is put all their page contents in a
database, and have a table (or column, or whatever) for each language. And
to determine the language to default to, you can use
request.SErvervariables("HTTP_ACCEPT_LANGUAGE"). Maybe something like:

<%
Dim sLanguage
sLanguage = UCase(Left(Request.sErverVariables("HTTP_ACCEPT_LANGUAGE"), 2))
sSQL = "SELECT [PageContent] FROM [" & sLanguage & "] WHERE [PageID]=1"
Set oADO = Server.CreateObject("ADODB.Connection")
oADO.Open YourConnectionString
Set rsContent = oADO.Execute(sSQL)
sContent = rsContent.Fields.Item(0).Value
rsContent.Close : Set rsContent = Nothing
oADO.Close : Set oADO = Nothing


Response.Write sContent
%>

This is where you'd have a database with a table named EN and a table named
PT, and those tables would contain the content in the appropriate language.
This, of course, isn't how you'd have to structure your DB, but in theory,
this is one way to do it.

Ray at work





CM said:
Thank you very much for the quick answer!
So, for the multiple languages question, that means ASP doesn't support
multiple languages. But ASP.Net can, Am I right?
CM
 
A

Arnold Shore

Distinguish between these languages in the user interface, or in the data
you capture and present. These are different issues.

In the latter case, I use UTF-8 as the charset, which ACCESS supports. I'm
handling Cyrillic, Arabic and Hebrew, and the CJK far-eastern languages as
well as the western ones, in an English ASP user interface. No sweat. HTH.

AS
 

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

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top